疯狂XML学习笔记(9)-------------Schema内置类型

XML Schema内置类型:

Schema内置类型说明


Table 2. Simple Types Built In to XML Schema
Simple Type Examples (delimited by commas) Notes
string Confirm this is electric
normalizedString Confirm this is electric see (3)
token Confirm this is electric see (4)
base64Binary GpM7
hexBinary 0FB7
integer ...-1, 0, 1, ... see (2)
positiveInteger 1, 2, ... see (2)
negativeInteger ... -2, -1 see (2)
nonNegativeInteger 0, 1, 2, ... see (2)
nonPositiveInteger ... -2, -1, 0 see (2)
long -9223372036854775808, ... -1, 0, 1, ... 9223372036854775807 see (2)
unsignedLong 0, 1, ... 18446744073709551615 see (2)
int -2147483648, ... -1, 0, 1, ... 2147483647 see (2)
unsignedInt 0, 1, ...4294967295 see (2)
short -32768, ... -1, 0, 1, ... 32767 see (2)
unsignedShort 0, 1, ... 65535 see (2)
byte -128, ...-1, 0, 1, ... 127 see (2)
unsignedByte 0, 1, ... 255 see (2)
decimal -1.23, 0, 123.4, 1000.00 see (2)
float -INF, -1E4, -0, 0, 12.78E-2, 12, INF, NaN equivalent to single-precision 32-bit floating point, NaN is "not a number", see (2)
double -INF, -1E4, -0, 0, 12.78E-2, 12, INF, NaN equivalent to double-precision 64-bit floating point, see (2)
boolean true, false, 1, 0
duration P1Y2M3DT10H30M12.3S 1 year, 2 months, 3 days, 10 hours, 30 minutes, and 12.3 seconds
dateTime 1999-05-31T13:20:00.000-05:00 May 31st 1999 at 1.20pm Eastern Standard Time which is 5 hours behind Co-Ordinated Universal Time, see (2)
date 1999-05-31 see (2)
time 13:20:00.000, 13:20:00.000-05:00 see (2)
gYear 1999 1999, see (2) (5)
gYearMonth 1999-02 the month of February 1999, regardless of the number of days, see (2) (5)
gMonth --05 May, see (2) (5)
gMonthDay --05-31 every May 31st, see (2) (5)
gDay ---31 the 31st day, see (2) (5)
Name shipTo XML 1.0 Name type
QName po:USAddress XML Namespace QName
NCName USAddress XML Namespace NCName, i.e. a QName without the prefix and colon
anyURI http://www.php.cn/,http://www.php.cn/
language en-GB, en-US, fr valid values for xml:lang as defined in XML 1.0
ID XML 1.0 ID attribute type, see (1)
IDREF XML 1.0 IDREF attribute type, see (1)
IDREFS XML 1.0 IDREFS attribute type, see (1)
ENTITY XML 1.0 ENTITY attribute type, see (1)
ENTITIES XML 1.0 ENTITIES attribute type, see (1)
NOTATION XML 1.0 NOTATION attribute type, see (1)
NMTOKEN US,Brésil XML 1.0 NMTOKEN attribute type, see (1)
NMTOKENS US UK,Brésil Canada Mexique XML 1.0 NMTOKENS attribute type, i.e. a whitespace separated list of NMTOKEN's, see (1)

Notes:

(1) To retain compatibility between XML Schema and XML 1.0 DTDs, the simple types ID, IDREF, IDREFS, ENTITY, ENTITIES, NOTATION, NMTOKEN, NMTOKENS should only be used in attributes.

(2) A value of this type can be represented by more than one lexical format, e.g. 100 and 1.0E2 are both valid float formats representing "one hundred". However, rules have been established for this type that define a canonical lexical format, seeXML Schema Part 2.

(3) Newline, tab and carriage-return characters in a normalizedString type are converted to space characters before schema processing.

(4) As normalizedString, and adjacent space characters are collapsed to a single space character, and leading and trailing spaces are removed.

(5) The "g" prefix signals time periods in the Gregorian calendar.

以上就是疯狂XML学习笔记(9)-------------Schema内置类型的内容,更多相关内容请关注编程之家(www.php.cn)!


版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐


php输出xml格式字符串
J2ME Mobile 3D入门教程系列文章之一
XML轻松学习手册
XML入门的常见问题(一)
XML入门的常见问题(三)
XML轻松学习手册(2)XML概念
xml文件介绍及使用
xml编程(一)-xml语法
XML文件结构和基本语法
第2章 包装类
XML入门的常见问题(二)
Java对象的强、软、弱和虚引用
JS解析XML文件和XML字符串详解
java中枚举的详细使用介绍
了解Xml格式
XML入门的常见问题(四)
深入SQLite多线程的使用总结详解
PlayFramework完整实现一个APP(一)
XML和YAML的使用方法
XML轻松学习总节篇