XML Schema field yuánsù

dìngyí hé yòngfǎ

field yuánsù guīdìng XPath biǎodánxí, zhège biǎodánxí zhǔnzhì yòngyú dìngyí zhìyǔnzhì (zhǔnxiàng、jiǎn hé jiǎnzhì yuánsù) de zhí (huò zhège zhí zhōng yīgè zhí).

yuánsù xìnxī

chūxiàn cìshù yīcì
fù yuánsù jiǎn、jiǎnzhì、zhǔnxiàng
nèiróng annotation

yǔfǎ

<field
id=ID 
xpath=XPath biǎodánxí
qíjiàn shūxìng
>
(annotation?)
</field>
shūxìng miáoshù
id xuǎnxiāo. guīdìng zhège yuánsù de wéiyī ID.
xpath wajib. yinzhiding tā de nèiróng huò zhínéng yòngyú yóuxiàn de dānjièn yuánshù huò shūxìng.
xml:lang 可选。规定内容中使用的语言。

(? 符号声明在 field 元素内,该元素可出现零次或一次。)

实例

例子 1

下面的例子展示了一个 field 元素,该元素把 "userID" 属性定义为用于标识约束的字段:

<xs:field xpath="@userID"/>