易截截图软件、单文件、免安装、纯绿色、仅160KB

XML Schema帮助文档3

XML Schema attributeGroup 元素
定义和用法
attributeGroup 元素用于对属性声明进行组合,这样这些声明就能够以组合的形式合并到复杂类型中。
元素信息
出现次数
无限制
父元素
attributeGroup、complexType、schema、restriction (simpleContent)、extension (simpleContent)、restriction (complexContent)、extension (complexContent)
内容
annotation、attribute、attributeGroup、anyAttribute
语法
<attributeGroup
id=ID
name=NCName
ref=QName
any attributes
>
(annotation?),((attribute|attributeGroup)*,anyAttribute?))
</attributeGroup>
(? 符号声明在 attributeGroup 元素中,元素可出现零次或一次,* 符号声明元素可出现零次或多次。)
属性
描述
id
可选。规定该元素的唯一的 ID。
name
可选。规定属性组的名称。name 和 ref 属性不能同时出现。
ref
可选。规定对指定的属性组的引用。name 和 ref 属性不能同时出现。
any attributes
可选。规定带有 non-schema 命名空间的任何其他属性。
实例
<xs:attributeGroup name="personattr">
  <xs:attribute name="attr1" type="string"/>
  <xs:attribute name="attr2" type="integer"/>
</xs:attributeGroup>
<xs:complexType name="person">
  <xs:attributeGroup ref="personattr"/>
</xs:complexType>
上面的例子定义了一个名为 "personattr" 的属性组,在名为 "person" 的复杂类型中使用。
XML Schema choice 元素
定义和用法
XML Schema 的 choice 元素仅允许包含在 <choice> 声明中的元素之一出现在包含元素中。
元素信息
出现次数
在 group 和 complexType 元素中为一次;其他为无限制。
父元素
group、choice、sequence、complexType、restriction (simpleContent)、extension (simpleContent)、restriction (complexContent)、extension (complexContent)
内容
annotation、any、choice、element、group、sequence
语法
<choice
id=ID
maxOccu


相关文档:

XML的读写

      XML是一种可扩展置标语言,又称可扩展的编辑语言。XML文档的定义格式有两种:DTD和Schema格式,由于Schema是xml本身的,所以应用的非常普遍。xml的作用是文件的读写,所以在web开发中也得到了广泛应用,作为一种配置文件,充分发挥了它读写的功能。XML的解析方式有四种:DOM,SAX,JDOM,DOM4J。 ......

VC解析XML 使用CMarkup类解析XML

(一) 先讲一下XML中的物殊字符,手动填写时注意一下。
字符                   字符实体
&                     ......

(4).读取XML文件

//读取XML文件
//1、LoadfromFile装入XML文件
//2、指定路径,激活读取
//3、从内存流读取
//4、从网络上直接获取
//1、LoadfromFile装入XML文件
procedure TForm1.Button1Click(Sender: TObject);
begin
XMLDocument1.LoadfromFile('c:\temp\test.xml');
// XMLDocument1.Active := True;
Memo1.Lines := X ......

xml操作

     protected void Button1_Click(object sender, EventArgs e)
        {
            //为response(star)节点 和  Cabins(f) cabin节点分别添加个
      &nbs ......

XML Schema帮助文档2

XML Schema annotation 元素
定义和用法
annotation 元素是一个顶层元素,规定 schema 的注释。
注释:可以包含 appinfo 元素(由应用程序使用的信息)和 documentation 元素(由用户读取或使用的注释或文本)。
元素信息
项目
说明
出现次数
在父元素中一次。 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号