XSD 中复杂类型的选择 [英] Choice of complex types in an XSD

查看:30
本文介绍了XSD 中复杂类型的选择的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在 XML 模式中,复杂类型可以包含其他复杂类型的选择吗?我找不到任何相关信息.

In an XML schema can a complex type contain a choice of other complex types? I couldn't find any information about that.

推荐答案

是的,参见 第 3.4.2 节complexType 确实可以包含一个 choice 元素.

Yes, see section 3.4.2 of the XML Schema reference; a complexType can indeed contain a choice element.

同样,一个 choice 元素可以包含一个或多个 complexType 元素(参见 第 3.8.2 节).

Similarly, a choice element can contain one or more complexType elements (see section 3.8.2).

这篇关于XSD 中复杂类型的选择的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆