跳转到主要内容

单击提交则表示您同意developerWorks 的条款和条件。 查看条款和条件.

当您初次登录到 developerWorks 时,将会为您创建一份概要信息。您在 developerWorks 概要信息中选择公开的信息将公开显示给其他人,但您可以随时修改这些信息的显示状态。您的姓名(除非选择隐藏)和昵称将和您在 developerWorks 发布的内容一同显示。

所有提交的信息确保安全。

  • 关闭 [x]

当您初次登录到 developerWorks 时,将会为您创建一份概要信息,您需要指定一个昵称。您的昵称将和您在 developerWorks 发布的内容显示在一起。

昵称长度在 3 至 31 个字符之间。 您的昵称在 developerWorks 社区中必须是唯一的,并且出于隐私保护的原因,不能是您的电子邮件地址。

单击提交则表示您同意developerWorks 的条款和条件。 查看条款和条件.

所有提交的信息确保安全。

  • 关闭 [x]

The basics of using XML Schema to define elements

Get started using XML Schema instead of DTDs for defining the structure of XML documents

返回正文

Table 2: Predefined simple types for values

<table border="1" cellspacing="1" cellpadding="5" class="code-sample" width="80%"><tr><td>
<b>Simple type</td>
<td><b>Example or explanation</b></td>
</tr>
<tr>
<td>
<code>string</code>
</td>
<td>
"this is a string"
</td>
</tr>
<tr>
<td>
<code>boolean</code>
</td>
<td>
true, false
</td>
</tr>
<tr>
<td>
<code>float</code>
</td>
<td>single-precision floating point</td>
</tr>
<tr>
<td>
<code>double</code>
</td>
<td>double precision 64-bit floating point</td>
</tr>
<tr>
<td>
<code>decimal</code>
</td>
<td>
123.45
</td>
</tr>
<tr>
<td>
<code>integer</code>
</td>
<td>
-12345; 0; 12345
</td>
</tr>
<tr>
<td>
<code>non-positive-integer</code>
</td>
<td>
-12345; 0
</td>
</tr>
<tr>
<td>
<code>negative-integer</code>
</td>
<td>
-12345
</td>
</tr>
<tr>
<td>
<code>long</code>
</td>
<td>
1234567890123
</td>
</tr>
<tr>
<td>
<code>int</code>
</td>
<td>
123456789
</td>
</tr>
<tr>
<td>
<code>short</code>
</td>
<td>
12345
</td>
</tr>
<tr>
<td>
<code>byte</code>
</td>
<td>
123
</td>
</tr>
<tr>
<td>
<code>non-negative-integer</code>
</td>
<td>
0; 123456
</td>
</tr>
<tr>
<td>
<code>unsigned-long</code>
</td>
<td>
123456789012345
</td>
</tr>
<tr>
<td>
<code>unsigned-int</code>
</td>
<td>
1234567801
</td>
</tr>
<tr>
<td>
<code>unsigned-short</code>
</td>
<td>
12345
</td>
</tr>
<tr>
<td>
<code>unsigned-byte</code>
</td>
<td>
123
</td>
</tr>
<tr>
<td>
<code>positive-integer</code>
</td>
<td>
123456
</td>
</tr>
<tr>
<td>
<code>date</code>
</td>
<td>
2000-02-16
</td>
</tr>
<tr>
<td>
<code>time</code>
</td>
<td>
15:55:00.000
</td>
</tr>
<tr>
<td>
<code>timeInstant</code>
</td>
<td>
2000-12-31T05:55:00.000&nbsp;
(5:55 am, Coordinated Universal Time)</td>
</tr>
<tr>
<td>
<code>timeDuration</code>
</td>
<td>
P5Y1M4D10H20M1.2S
(5 years; 1 month;
<br>4 days; 20 minutes; 1.2 seconds)</td>
</tr>
<tr>
<td>
<code>recurringInstant</code>
</td>
<td>
--02-16T5:55:00
(February 16th every year at 5:55 am.
<br>Coordinated Universal Time)</td>
</tr>
<tr>
<td>
<code>binary</code>
</td>
<td>bit pattern</td>
</tr>
<tr>
<td>
<code>uri-reference</code>
</td>
<td>standard URL</td>
</tr>
<tr>
<td>
<code>ID*</code>
</td>
<td>XML 1.0 Compatibility</td>
</tr>
<tr>
<td>
<code>IDREF*</code>
</td>
<td>XML 1.0 Compatibility</td>
</tr>
<tr>
<td>
<code>ENTITY*</code>
</td>
<td>XML 1.0 Compatibility</td>
</tr>
<tr>
<td>
<code>NOTATION*</code>
</td>
<td>XML 1.0 Compatibility</td>
</tr>
<tr>
<td>
<code>language</code>
</td>
<td>en-US (see xml:lang in XML 1.0)</td>
</tr>
<tr>
<td>
<code>IDREFS*</code>
</td>
<td>XML 1.0 Compatibility</td>
</tr>
<tr>
<td>
<code>ENTITIES*</code>
</td>
<td>XML 1.0 Compatibility</td>
</tr>
<tr>
<td>
<code>NMTOKEN*</code>
</td>
<td>XML 1.0 Compatibility</td>
</tr>
<tr>
<td>
<code>NMTOKENS*</code>
</td>
<td>XML 1.0 Compatibility</td>
</tr>
<tr>
<td>
<code>Name</code>
</td>
<td>
&nbsp;see XML 1.0
</td>
</tr>
<tr>
<td>
<code>QName</code>
</td>
<td>
(Prefix ':')? NCName = LocalPart (e.g.; po:Address)
</td>
</tr>
<tr>
<td>
<code>NCName</code>
</td>
<td>
(letter | '_') (NCNameChar)*
<p>*Use only in attributes to ensure compatibility with XML 1.0 DTD.</td></p>
</code></pre></td></tr></table>
	

返回正文