home *** CD-ROM | disk | FTP | other *** search
/ Internet Magazine 2003 October / INTERNET108.ISO / pc / software / windows / building / xmlspy / xmlspyentcomplete5.exe / Data1.cab / _7BABDFFC107D4D15B679EA4FF815CBEC < prev    next >
Encoding:
Extensible Markup Language  |  2002-10-01  |  361.8 KB  |  11,036 lines

  1. <?xml version='1.0'?>
  2. <?xml-stylesheet type='text/xsl' href='xmlschema.xsl'?>
  3. <!DOCTYPE spec PUBLIC
  4.     "-//W3C//DTD Specification V2.2//EN"
  5.     "http://www.w3.org/XML/1998/06/xmlspec-v22.dtd" [
  6.  <!ENTITY cellback '#d0d9fa'>
  7.  
  8.  <!ENTITY xmlspec "http://www.w3.org/TR/2000/WD-xml-2e-20000814">
  9.  <!ENTITY xmlnsspec "http://www.w3.org/TR/1999/REC-xml-names-19990114/">
  10.  <!ENTITY xsdl "http://www.w3.org/TR/2001/REC-xmlschema-1-20010502/">
  11.  <!ENTITY xlink "http://www.w3.org/TR/2000/PR-xlink-20001220/">
  12.  <!ENTITY charmod 'http://www.w3.org/TR/2001/WD-charmod-20010126/'>
  13.  <!ENTITY html4 'http://www.w3.org/TR/1999/REC-html401-19991224/'>
  14.  
  15.  <!ENTITY schemaWG "<loc href='http://www.w3.org/XML/Activity#schema-wg'>W3C XML Schema Working Group</loc>">
  16.  
  17.  <!ENTITY year "2001">
  18.  <!ENTITY mm "05">
  19.  <!ENTITY MM "May">
  20.  <!ENTITY dd "02">
  21.  
  22.  <!ENTITY schema-language "XML Schema definition language">
  23.  
  24.  <!ENTITY thisversion "http://www.w3.org/TR/2001/">
  25.  <!ENTITY order "£">
  26.  <!ENTITY le "≤"> <!-- less than or equal to, U+2264 ISOtech -->
  27.  <!ENTITY ne "≠"> <!-- not equal to, U+2260 ISOtech -->
  28.  <!ENTITY infin "∞"> <!-- infinity, U+221E ISOtech -->
  29.  <!ENTITY times "×"> <!-- multiplication, U+00D7 -->
  30.  <!ENTITY sect   "§">
  31.  <!ENTITY eacute "é">
  32.  
  33. <!-- we'll see if anyone has a sense of humor -->
  34. <!-- note: I tried to do this with conditional sections,
  35.      but XT seems to get confused and reports a syntax error -->
  36. <!ENTITY % sense-of-humor "INCLUDE">
  37. <!ENTITY % no-sense-of-humor "IGNORE">
  38. <!--
  39. <![%sense-of-humor[
  40.  <!ENTITY long "Homer">
  41.  <!ENTITY int "Sideshow-Bob">
  42.  <!ENTITY short "Bart">
  43.  <!ENTITY byte "Troy-McClure">
  44.  <!ENTITY unsignedLong "Apu-Nahasapeemapetilon">
  45.  <!ENTITY unsignedInt "Chief-Wiggums">
  46.  <!ENTITY unsignedShort "Mr-Burns">
  47.  <!ENTITY unsignedByte "Krusty-the-Clown">
  48. -->
  49. <!--
  50.  ]]>
  51. <![%no-sense-of-humor[
  52. -->
  53.  <!ENTITY long "long">
  54.  <!ENTITY int "int">
  55.  <!ENTITY short "short">
  56.  <!ENTITY byte "byte">
  57.  <!ENTITY unsignedLong "unsignedLong">
  58.  <!ENTITY unsignedInt "unsignedInt">
  59.  <!ENTITY unsignedShort "unsignedShort">
  60.  <!ENTITY unsignedByte "unsignedByte">
  61. <!--
  62.  ]]> 
  63. -->
  64.  
  65.  <!ATTLIST eg text CDATA #IMPLIED> <!-- experimental pointer to out-of-line
  66.                                         example text -->
  67.  
  68.    <!ELEMENT propdef ANY> <!-- best we can do without editing xml-spec -->
  69.    <!ATTLIST propdef id ID #REQUIRED
  70.                      name CDATA #REQUIRED>
  71.    <!ELEMENT propref EMPTY>
  72.    <!ATTLIST propref ref IDREF #REQUIRED>
  73.    <!ELEMENT xpropref (#PCDATA)>
  74.    <!ATTLIST xpropref href CDATA #IMPLIED>
  75.    <!ELEMENT compdef (proplist)>
  76.    <!ATTLIST compdef name CDATA #REQUIRED
  77.                      ref IDREF #REQUIRED>
  78.    
  79.    <!ELEMENT compref EMPTY>
  80.    <!ATTLIST compref ref IDREF #REQUIRED>
  81.  
  82.    <!ELEMENT proplist (propdef*)>
  83.    <!ELEMENT reprdef (reprelt*,reprcomp*)>
  84.    <!ATTLIST reprdef eltname NMTOKENS #REQUIRED
  85.                      local NMTOKEN #IMPLIED>
  86.    <!ELEMENT reprelt EMPTY>
  87.    <!ATTLIST reprelt eltname NMTOKENS #REQUIRED
  88.                      type NMTOKEN #IMPLIED>
  89.    <!ELEMENT reprcomp (reprdep?,propmap*)>
  90.    <!ATTLIST reprcomp ref IDREF #REQUIRED
  91.                       abstract CDATA #REQUIRED>
  92.    <!ELEMENT reprdep ANY> <!-- best we can do without editing xml-spec -->
  93.     <!ELEMENT propmap ANY> <!-- best we can do without editing xml-spec -->
  94.    <!ATTLIST propmap name IDREF #REQUIRED>
  95.    <!ELEMENT eltref EMPTY>
  96.    <!ATTLIST eltref ref NMTOKEN #REQUIRED>
  97.    <!ELEMENT stale ANY>
  98.    <!ELEMENT dtref EMPTY>
  99.    <!ATTLIST dtref ref NMTOKEN #REQUIRED>   
  100.    <!ELEMENT baseref EMPTY>
  101.    <!ELEMENT itemTyperef EMPTY>
  102.    <!ELEMENT fundamental-facets EMPTY>
  103.    <!ATTLIST graphic map IDREF #IMPLIED>
  104.    <!ELEMENT imagemap EMPTY>
  105.    <!ATTLIST imagemap source CDATA #REQUIRED
  106.                       id     ID    #REQUIRED>
  107.    
  108.    <!ENTITY v-value "<xtermref href='&xsdl;#key-vv'>actual value</xtermref>">
  109.  
  110.    <!ELEMENT strong (#PCDATA)>
  111.    <!ENTITY % local.emph.class '|strong'>
  112.    <!ELEMENT pt (#PCDATA)>
  113.    <!ENTITY % local.term.class '|pt'><!-- ht: for pre-terminal -->
  114.    <!ENTITY % local.tech.class '|pt'><!-- ht: for pre-terminal -->
  115.    <!ENTITY % local.p.class "|stale|facets|subtypes|
  116.            inverse-facets|open-issues|revisions|
  117.            fundamental-facets|applicable-facets|type-hierarchy">
  118.    <!ENTITY % local.termdef.class "|propdef">
  119.    <!ENTITY % local.ref.class "|propref|xpropref|eltref|compref|dtref|
  120.            baseref|itemTyperef">
  121.    <!ENTITY % local.illus.class "|compdef|reprdef|proplist|imagemap">
  122.    
  123.    <!ENTITY i-attribute "  <xpropref href='http://www.w3.org/TR/xml-infoset/#infoitem.attribute'>attribute</xpropref>">
  124.    <!ENTITY i-children " <xpropref href='http://www.w3.org/TR/xml-infoset/#infoitem.element'>children</xpropref>">
  125.    <!ENTITY i-child " <xpropref href='http://www.w3.org/TR/xml-infoset/#infoitem.element'>child</xpropref>">
  126.    <!ENTITY i-attributes " <xpropref href='http://www.w3.org/TR/xml-infoset/#infoitem.element'>attributes</xpropref>">
  127.    <!ENTITY i-attrChildren " <xpropref href='http://www.w3.org/TR/xml-infoset/#infoitem.attribute'>children</xpropref>">
  128.    <!ENTITY i-value " <xpropref href='http://www.w3.org/TR/xml-infoset/#infoitem.attribute'>value</xpropref>">
  129.    <!ENTITY i-ccode " <xpropref href='http://www.w3.org/TR/xml-infoset/#infoitem.character'>character code</xpropref>">
  130.    
  131.     <!ELEMENT applicable-facets EMPTY>
  132.     <!ELEMENT facets EMPTY>
  133.     <!ELEMENT subtypes EMPTY>
  134.     <!ELEMENT inverse-facets EMPTY>
  135.     <!ATTLIST inverse-facets
  136.         name CDATA #REQUIRED>
  137.     <!ELEMENT open-issues EMPTY>
  138.     <!ELEMENT revisions EMPTY>
  139.     
  140.     <!ATTLIST table
  141.         align CDATA #IMPLIED
  142.         bgcolor CDATA #IMPLIED
  143.                 class CDATA #IMPLIED>
  144.     
  145.     <!ELEMENT type-hierarchy EMPTY>
  146.     <!ELEMENT font (#PCDATA)>
  147.     <!ATTLIST font
  148.         size NMTOKEN #IMPLIED>
  149.  
  150.     <!ATTLIST spec
  151.         xml:lang NMTOKEN #IMPLIED>
  152.         <!ATTLIST td style CDATA #IMPLIED>
  153.         <!ATTLIST th style CDATA #IMPLIED>
  154.    <!ATTLIST spec schemaProper CDATA #FIXED "http://www.w3.org/2001/XMLSchema.xsd"
  155.            schemaDump CDATA #FIXED "http://www.w3.org/2001/05/XMLSchema.xsd,dmp"
  156.            schemaExample CDATA #FIXED "http://www.w3.org/2001/05/example.xsd,dmp"
  157.            datatypeDoc CDATA #FIXED "http://www.w3.org/TR/2001/REC-xmlschema-2-20010502/datatypes.xml"
  158.            docStatus CDATA #FIXED "REC">
  159.     ]>
  160. <spec xml:lang='en'>
  161. <header>
  162. <title>XML Schema Part 2: Datatypes</title>
  163.  
  164. <version></version>
  165.     <w3c-designation>datatypes-20010502</w3c-designation>
  166.     <w3c-doctype>W3C Recommendation</w3c-doctype>
  167. <pubdate><day>ⅆ</day><month>&MM;</month><year>&year;</year></pubdate>
  168. <notice role="publoc">
  169. <p>
  170. (in <loc href="http://www.w3.org/TR/2001/REC-xmlschema-2-20010502/datatypes.xml">XML</loc> and
  171. <loc href="http://www.w3.org/TR/2001/REC-xmlschema-2-20010502/datatypes.html">HTML</loc>,    with a
  172. <loc href="http://www.w3.org/2001/XMLSchema.xsd">schema</loc> and
  173. <loc href="http://www.w3.org/2001/XMLSchema.dtd">DTD</loc> including datatype definitions,
  174. as well as a <loc href="http://www.w3.org/2001/XMLSchema-datatypes.xsd">schema</loc>
  175. for built-in datatypes only, in a separate namespace.)
  176. </p>
  177. </notice>
  178. <publoc>
  179. <loc href="http://www.w3.org/TR/2001/REC-xmlschema-2-20010502/">http://www.w3.org/TR/2001/REC-xmlschema-2-20010502/</loc>
  180. </publoc>
  181. <prevlocs>
  182.     <loc href="http://www.w3.org/TR/2001/PR-xmlschema-2-20010330/">
  183.         http://www.w3.org/TR/2001/PR-xmlschema-2-20010330/
  184.     </loc>
  185. </prevlocs>
  186. <latestloc>
  187.     <loc href="http://www.w3.org/TR/xmlschema-2/">
  188.         http://www.w3.org/TR/xmlschema-2/
  189.     </loc>
  190. </latestloc>
  191. <authlist>
  192. <author>
  193. <name>Paul V. Biron</name>
  194. <affiliation>Kaiser Permanente, for Health Level Seven</affiliation>
  195. <email href="mailto:Paul.V.Biron@kp.org">Paul.V.Biron@kp.org</email>
  196. </author>
  197. <author>
  198. <name>Ashok Malhotra</name>
  199. <affiliation>Microsoft, formerly of IBM</affiliation>
  200. <email href="mailto:ashokma@microsoft.com">ashokma@microsoft.com</email>
  201. </author>
  202. </authlist>
  203.     <status>
  204. <p><emph>This section describes the status of this document at the
  205. time of its publication. Other documents may supersede this
  206. document. The latest status of this document series is maintained at
  207. the W3C.</emph></p>
  208.  
  209. <p>This document has been reviewed by W3C Members and other interested
  210. parties and has been endorsed by the Director as a W3C
  211. Recommendation. It is a stable document and may be used as reference
  212. material or cited as a normative reference from another
  213. document. W3C's role in making the Recommendation is to draw attention
  214. to the specification and to promote its widespread deployment. This
  215. enhances the functionality and interoperability of the Web.</p>
  216.  
  217.      <p>This document has been produced by the <loc
  218. href="http://www.w3.org/XML/Schema">W3C XML Schema Working Group</loc>
  219. as part of the W3C <loc href="http://www.w3.org/XML/">XML
  220. Activity</loc>.  The goals of the XML Schema language are discussed in
  221. the <loc href="http://www.w3.org/TR/NOTE-xml-schema-req">XML Schema
  222. Requirements</loc> document.  The authors of this document are the XML
  223. Schema WG members. Different parts of this specification have
  224. different editors.</p>
  225. <p>
  226. This version of this document incorporates some editorial changes
  227. from earlier versions. 
  228. </p>
  229. <p>
  230. Please report errors in this document to <loc
  231. href="mailto:www-xml-schema-comments@w3.org"
  232. >www-xml-schema-comments@w3.org</loc> (<loc
  233. href="http://lists.w3.org/Archives/Public/www-xml-schema-comments/"
  234. >archive</loc>). The list of known errors in this specification is
  235. available at <loc href="http://www.w3.org/2001/05/xmlschema-errata"
  236. >http://www.w3.org/2001/05/xmlschema-errata</loc>.
  237. </p>
  238. <p>The English version of this specification is the only normative
  239. version. Information about translations of this document is available
  240. at <loc href="http://www.w3.org/2001/05/xmlschema-translations"
  241. >http://www.w3.org/2001/05/xmlschema-translations</loc>.</p>
  242.       <p>A list of current W3C Recommendations and other technical documents can be found at
  243.         <loc href="http://www.w3.org/TR/">http://www.w3.org/TR/</loc>.</p>
  244. </status>
  245. <abstract>
  246. <p>
  247. <emph>XML Schema: Datatypes</emph> is part 2 of the specification of the XML    
  248. Schema language. It defines facilities for defining datatypes to be used
  249. in XML Schemas as well as other XML specifications.  
  250. The datatype language, which is itself represented in
  251. XML 1.0, provides a superset of the capabilities found in XML 1.0
  252. document type definitions (DTDs) for specifying datatypes on elements
  253. and attributes.
  254. </p>
  255. </abstract>
  256. <langusage>
  257. <language id="EN">English</language>
  258. </langusage>
  259. <revisiondesc>
  260. <slist>
  261. <!--
  262.      commenting these out means only that they won't show up in the
  263.      stylesheet generated "Revisions from previous draft" appendix
  264.   -->
  265. <!-- Changes before Sept public draft commented out...
  266. <sitem>
  267. 19990521: PVB: corrected definition of length and maxLengths facet for strings to
  268. be in terms of <emph>characters</emph> not <emph>bytes</emph>
  269. </sitem>
  270. <sitem>
  271. 19990521: PVB: removed issue "other-date-representations".  We don't
  272. want other separators, left mention of aggregate reps for dates as
  273. an ednote.
  274. </sitem>
  275. <sitem>
  276. 19990521: PVB: fixed "holidays" example, "-0101" ==> "==0101"
  277. (where == in the correction should be two hyphens, but that would
  278. not allow us to comment out this sitem)
  279. </sitem>
  280. <sitem>
  281. 19990521: PVB: fixed "common date" example, lexicalRepresenation ==> lexicalRepresentation
  282. </sitem>
  283. <sitem>
  284. 19990521: PVB: added note that -YY-MM-DD style dates are deprecated
  285. </sitem>
  286. <sitem>
  287. 19990521: PVB: added termdef element around definition of subtype
  288. </sitem>
  289. <sitem>
  290. 19990521: PVB: removed "whose basetype is a built-in" from definition of
  291. "user-generated" datatype
  292. </sitem>
  293. <sitem>
  294. 19990521: PVB: clarified that the length facet for binary datatype is
  295. length in bytes
  296. </sitem>
  297. <sitem>
  298. 19990521: PVB: fixed weird spacing problems introduced by ArborText
  299. </sitem>
  300. <sitem>
  301. 19990521: PVB: fixed references to non-terminals in productions
  302. </sitem>
  303. <sitem>
  304. 19990524: AM: changed "boolean" to have a single lexical representation.
  305. </sitem>
  306. <sitem>
  307. 19990524: AM: added issue: "should we add a facet to restrict a binary
  308. datatype to a user-defined format such as audio, image, etc."
  309. </sitem>
  310. <sitem>
  311. 19990524: AM: corrected reference to SQL standard.
  312. </sitem>
  313. <sitem>
  314. 19990524: AM: corrected definition of length and maximum length
  315. facets to be a positive integer.
  316. </sitem>
  317. <sitem>
  318. 19990524: AM: corrected default format for integer, decimal and real.
  319. </sitem>
  320. <sitem>
  321. 19990524: AM: rewrote issue definition-overiding.
  322. </sitem>
  323. <sitem>
  324. 19990524: AM: edited Conformance section to add example of lexical
  325. errors and fix reference to above issue.
  326. </sitem>
  327. <sitem>
  328. 19990601: PVB: changed date formats in examples of Section 1 to be conformant
  329. with the date datatype
  330. </sitem>
  331. <sitem>
  332. 19990601: PVB: added a "for compatibility" terminology entry
  333. </sitem>
  334. <sitem>
  335. 19990601: PVB: added a Name datatype and redefined the XML 1.0 attribute types
  336. in terms of it
  337. </sitem>
  338. <sitem>
  339. 19990601: PVB: remove "for attributes only" restriction on XML 1.0  attribute types.
  340. Added a "for compatibility" clause for attribute values.
  341. </sitem>
  342. <sitem>
  343. 19990601: PVB: added language datatype
  344. </sitem>
  345. <sitem>
  346. 19990602: PVB: added uuid datatype
  347. </sitem>
  348. <sitem>
  349. 19990602: PVB: added NCName datatype
  350. </sitem>
  351. <sitem>
  352. 19990604: AM: changed date and time formats to allow only ISO 8601
  353. extended format. Impacted sections on the date, time datatypes,
  354. section 4, Appendix C.
  355. </sitem>
  356. <sitem>
  357. 19990604: AM: added ednote to string datatype saying we need to harmonize
  358. with I18N character model.
  359. </sitem>
  360. <sitem>
  361. 19990604: PVB: added "Revisions from previous draft" appendix
  362. </sitem>
  363. <sitem>
  364. 19990604: PVB: moved "built-in generated" datatype definitions into the
  365. schema for datatype definitions (instead of it being in its own appendix).
  366. </sitem>
  367. <sitem>
  368. 19990604: PVB: upadted the schema for datatype definitions to point to
  369. the correct (per xmlschema-1) DTD and schema
  370. </sitem>
  371. <sitem>
  372. 19990623: AM: added paragraph to conformance section which begins
  373. to be more precise about how conforming processors should behave
  374. </sitem>
  375. <sitem>
  376. 19990623: AM: removed confusing statement from conformance section
  377. which said that " checking for lexical conformance is all that is
  378. expected of an XML processor."
  379. </sitem>
  380. <sitem>
  381. 19990623: PVB: removed section on "Characterizing Operations" and
  382. all references to it (or its content) in the rest of the draft.
  383. </sitem>
  384. <sitem>
  385. 19990623: PVB: removed uuid datatype
  386. </sitem>
  387. <sitem>
  388. 19990623: PVB: made NMTOKEN a primitive datatype and Name a
  389. subtype of NMTOKEN.
  390. </sitem>
  391. <sitem>
  392. 19990623: PVB: corrected the basetypes of following XML-related
  393. generated datatypes: IDREFS (from ID to IDREF), ENTITY (from ID to Name),
  394. ENTITIES (from ID to ENTITY), NMTOKENS (from Name to NMTOKEN).
  395. </sitem>
  396. <sitem>
  397. 19990623: PVB: changed name of section "User-Generated Datatypes" to
  398. the more correct "Defining Generated Datatypes".  Also added some
  399. explanatory text to the beginning of that section which explains
  400. that the abstract syntax there is used both for defining built-in
  401. and user-generated datatypes.
  402. </sitem>
  403. <sitem>
  404. 19990623: PVB: added explanations of abstract and concrete
  405. syntax (mostly borrowed from the structural draft) to section
  406. "Defining Generated Datatypes".
  407. </sitem>
  408. <sitem>
  409. 19990623: PVB: separated references into those that are normative
  410. and those that are non-normative
  411. </sitem>
  412. <sitem>
  413. 19990623: PVB: added a pointer to the draft revision of ISO 8601
  414. in its bib entry
  415. </sitem>
  416. <sitem>
  417. 19990623: PVB: added "no-consensus" issues to those all sections
  418. except "Type System" and "Built-in datatypes" stating that no WG
  419. consensus has been reached on the section (the exclusions above
  420. are because those sections which granted consensus status at the
  421. Ann Arbor f2f)
  422. </sitem>
  423. <sitem>
  424. 19990623: PVB: cleaned up productions for numeric literals
  425. </sitem>
  426. <sitem>
  427. 19990624: PVB: excluded subsections 1.1 and 1.2 from the "no-consusus"
  428. issue for section 1
  429. </sitem>
  430. <sitem>
  431. 19990630: PVB: removed number datatype, made real into a built-in
  432. primitive, changed the basetype of decimal to real and the basetype
  433. of integer to decimal.  Also added NaN, INF and -INF to the lexical
  434. space of all numeric types.
  435. </sitem>
  436. <sitem>
  437. 19990630: PVB: added 2 new subtypes of integer: nonPositiveInteger
  438. and nonNegativeInteger, each of which has 1 subtype: negativeInteger
  439. and positiveInteger, respectively.  Added generated datatype definitions
  440. for these to the schema for datatypes.
  441. </sitem>
  442. <sitem>
  443. 19990630: PVB: fixed typos in definition of IDREF and IDREFS
  444. (was "the lexical space of ID is .." now "the lexical space of IDREF is ...")
  445. </sitem>
  446. <sitem>
  447. 19990630: PVB: added issue(nonNegativeInteger-literals)
  448. </sitem>
  449. <sitem>
  450. 19990630: PVB: added links to known subtypes in all datatype
  451. descriptions
  452. </sitem>
  453. <sitem>
  454. 19990630: PVB: changed "no-consensus" issues to "no-consensus"
  455. ednotes
  456. </sitem>
  457. <sitem>
  458. 19990630: PVB: changed "no-consensus" ednote for section 1 to
  459. exclude subsection 1.3, as voted on during the telcon today
  460. </sitem>
  461. <sitem>
  462. 19990630: PVB: corrected several interal cross-references: from termref's
  463. to specref's
  464. </sitem>
  465. <sitem>
  466. 19990630: PVB: added all previous drafts (internal as well as public WDs)
  467. to the "Previous Versions" section.  In future public WDs only those
  468. "previous versions" which were public WDs will display
  469. </sitem>
  470. <sitem>
  471. 19990630: PVB: changed "collection" to "set" in definition of "value space"
  472. (thought this had been changed long ago, sorry)
  473. </sitem>
  474. <sitem>
  475. 19990708: PVB: removed section 1.5 "Organization", per WG vote on telcon
  476. </sitem>
  477. <sitem>
  478. 19990708: PVB: removed "no-consensus" ednote from section 1
  479. </sitem>
  480. <sitem>
  481. 19990709: PVB: added (stub) subsections on "Precision", "Scale" and "Encoding" to
  482. section 2.4.2 "Constraining Facets".  All facets mentioned in all datatype
  483. definitions in section 3 should be listed in 2.4.2. (this is not intended to address
  484. the standing issue <xspecref href='http://www.w3.org/XML/Group/xmlschema-current/issues.html#constraining-facet-definitions'>
  485. constraining-facet-definitions</xspecref>, but was needed for the next revision item)
  486. </sitem>
  487. <sitem>
  488. 19990709: PVB: added "Datatypes and Facets" appendix which consists of
  489. several tables which attempt to show which facets apply to which datatypes
  490. </sitem>
  491. <sitem>
  492. 19990713: PVB: fixed bug in schema for datatypes regarding modelGroup vs.
  493. elementType Refs in unordered modelGroup
  494. as per
  495. <loc href='http://lists.w3.org/Archives/Public/www-xml-schema-comments/1999AprJun/0088.html'>
  496. http://lists.w3.org/Archives/Public/www-xml-schema-comments/1999AprJun/0088.html</loc>
  497. </sitem>
  498. <sitem>
  499. 19990726: AM: Changed example of user-generated datatype from
  500. heightInInches to i4.
  501. </sitem>
  502. <sitem>
  503. 19990726: AM: Rewrote "Exact and Approximate".
  504. </sitem>
  505. <sitem>
  506. 19990812: PVB: Removed all mention of picture constraints as lexical-representations
  507. for strings
  508. </sitem>
  509. <sitem>
  510. 19990819: AM: Amended Ed. Note on a URL for the datatypes namespace
  511. referring to Dan Connolly's note "make up your own".
  512. </sitem>
  513. <sitem>
  514. 19990819: AM: Removed issue on NULLS, 2 occurrences.
  515. </sitem>
  516. <sitem>
  517. 19990819: AM: Changed Ed. Note on "Better Ref Mechs" associated with
  518. IDREFS to "issue"..
  519. </sitem>
  520. <sitem>
  521. 19990819: AM: Removed issue on measurement units as WG decided to
  522. defer to version 2.
  523. </sitem>
  524. <sitem>
  525. 19990919: HT: modifed abstract syntax to better reflect intent?
  526. </sitem>
  527. <sitem>
  528. 19990923: HT: modified schema for schemas to conform to the concrete
  529. syntax in the latest Structures draft
  530. </sitem>
  531. <sitem>
  532. 19990923: PVB: added minAbsoluteValue and maxAbsoluteValue facets to
  533. real, their intent is to allow generation of subtypes of real whose
  534. value spaces correspond to comment float-point representations.
  535. Added examples to section 4 to show how to generate IEEE 32-bit, etc.
  536. </sitem>
  537. <sitem>
  538. 19990923: PVB: replaced dateTime, date, time and timePeriod with all
  539. new date/time related types: timeInstant, recurringInstant,
  540. date and time.  Additionally, limited the lexical representations of each
  541. of the new types to a single form (w/ the exception of still allowing both
  542. left truncation and reduced [i.e., right truncated] representations).
  543. Changed all examples which used date/time to use the new lexical representation
  544. </sitem>
  545. <sitem>
  546. 19990923: PVB: modified the abstract syntax, schema for datatypes and DTD
  547. for datatypes to bring them in line with above changes.
  548. </sitem>
  549. <sitem>
  550. 19990924: HST: link housekeeping before publication</sitem>
  551. <sitem>
  552. 19991020: AM: Rewrote "NOTATION".
  553. </sitem>
  554. <sitem>
  555. 19991020: AM: Made NMTOKEN a subtype of string.
  556. </sitem>
  557. <sitem>
  558. 19991020: AM: Changed lex reps for all date and time datatypes to ISO
  559. extended format i.e. with separators.
  560. </sitem>
  561. <sitem>
  562. 19991020: AM: Removed issue on non-Gregorian dates.
  563. </sitem>
  564. <sitem>
  565. 19991020: AM: Renamed "lexical representation" facet for string to "pattern".
  566. </sitem>
  567.  <sitem>
  568. 19991026: AM: Added appendix discussing ISO 8601 formats.  Removed note
  569. asking for such explanation.
  570. </sitem>
  571. <sitem>
  572. 1999-10-26: PVB: fixed errors in datatypes.xsd and datatypes.dtd as pointed
  573. out by <loc href='http://lists.w3.org/Archives/Public/www-xml-schema-comments/1999JulSep/0050.html'>
  574. Curt Arnold</loc>
  575. </sitem>
  576. <sitem>
  577. 1999-10-26: PVB: added period to the facets production
  578. </sitem>
  579. <sitem>
  580. 1999-10-26: PVB: added a note on the basetype to the definition of
  581. datatype NMTOKEN
  582. </sitem>
  583. <sitem>
  584. 1999-10-26: PVB: removed NaN, INF and -INF from the lexical space
  585. of integer and decimal
  586. </sitem>
  587. <sitem>
  588. 1999-11-08: PVB: removed real datatype and all references to it
  589. </sitem>
  590. <sitem>
  591. 1999-11-08: PVB: added inital definitions for float and double datatypes.
  592. This initial definition is not intended to be complete, we need a more
  593. complete description of the round-to-nearest behavior of mapping literals
  594. into the value space (i.e., a more readable description of "best approximation"
  595. from the Clinger paper in the non-normative references section).
  596. </sitem>
  597. <sitem>
  598. 1999-11-08: PVB: corrected typos in the definitions of datatypes generated
  599. from integer to corrected identify the generated type
  600. </sitem>
  601. <sitem>
  602. 1999-11-08: PVB: added specref elements to all mentions of constraining facets
  603. </sitem>
  604. <sitem>
  605. 1999-11-08: PVB: added term elements to all mentions of a datatype name in
  606. the definition of that datatype
  607. </sitem>
  608. <sitem>
  609. 1999-11-12: PVB: changed lexical space of timeInstant to be more consistent
  610. with ISO 8601, nYnMnDTnHnMnS (minus the 'P' designator).
  611. </sitem>
  612. <sitem>
  613. 1999-11-12: PVB fixed productions for decimalLiteral to allow forms such as
  614. -.12 and -23.
  615. </sitem>
  616. <sitem>
  617. 19991122: AM: Added some more explanation to timeInstant format.  Fixed
  618. Appendix D to reflect changes.
  619. </sitem>
  620. <sitem>
  621. 19991122: AM: Added "uncountable infinite and exact" value space to 2.4.1.3
  622. </sitem>
  623. <sitem>
  624. 19991122: AM: Removed issue "Better Reference Mechanisms".
  625. </sitem>
  626. <sitem>
  627. 19991122: AM: Added "collation sequence for strings is Unicode characater number".
  628. </sitem>
  629. <sitem>
  630. 19991122: AM: Added min/max facets to date/time datatypes.
  631. </sitem>
  632. <sitem>
  633. 19991122: AM: Removed issues on URI and binary datatypes.
  634. </sitem>
  635. <sitem>
  636. 19991122: AM: Added value space validation to conformance section.
  637. </sitem>
  638. <sitem>
  639. 19991122: AM: Added values space definitions to date/time datatypes.
  640. </sitem>
  641. <sitem>
  642. 1999-12-08: pvb: Added QName datatype
  643. </sitem>
  644. <sitem>
  645. 1999-12-08: pvb: changed language to be a subtype of string
  646. </sitem>
  647. <sitem>
  648. 1999-12-10: pvb: many small editorial changes for consistency
  649. </sitem>
  650. <sitem>
  651. 1999-12-10: pvb: Added pattern facet to all date/time types (should
  652. have been there all along)
  653. </sitem>
  654. <sitem>
  655. 1999-12-10: pvb: Added full list of facets and subtypes to each type
  656. definition
  657. </sitem>
  658. <sitem>
  659. 1999-12-10: pvb: replaced regex appendix with a brief summary of proposed
  660. Unicode support, complete proposal coming shortly
  661. </sitem>
  662. <sitem>
  663. 1999-12-10: pvb: moved some references from normative to non-normative
  664. </sitem>
  665. <sitem>
  666. 1999-12-10: pvb: changed concrete syntax for datatype defns to more closely
  667. match the structures draft: in particular, to allow annotations on the
  668. datatype element and all facet elements.
  669. </sitem>
  670. <sitem>
  671. 1999-12-15: pvb: added normaitive reference to RTC 2045 for def of base64
  672. </sitem>
  673. <sitem>
  674. 1999-12-15: pvb: many more small editorial changes, for consistency in
  675. style and presentation
  676. </sitem>
  677. <sitem>
  678. 1999-12-15: pvb: corrected small errors in table in appendix C.1, Fundamental
  679. facets
  680. </sitem>
  681. <sitem>
  682. 1999-12-15: pvb: filled out list of datatypes for each facet in appendix C.2,
  683. Constraining facets
  684. </sitem>
  685. <sitem>
  686. 1999-12-15: expanded abstract
  687. </sitem>
  688. <sitem>
  689. 1999-12-15: pvb: updated description of lexical space for float/double to
  690. include literals for +- inf, +- 0, nan.
  691. </sitem>
  692. <sitem>
  693. 1999-12-16: pvb: modified defns of ID, IDREF, IDREFS, ENTITY, ENTITIES
  694. and NOTATION to match NCName instead of Name as required by the Namespaces
  695. in XML spec
  696. </sitem>
  697. <sitem>
  698. 1999-12-16: pvb: fully specified value space for decimal
  699. </sitem>
  700. <sitem>
  701. 2000-02-08: pvb: spell check
  702. </sitem>
  703. <sitem>
  704. 2000-02-08: pvb: added COS's for interaction between min/max-X facets
  705. </sitem>
  706. <sitem>
  707. 2000-02-08: pvb: changed datatype of length, min/maxLength facets from
  708. positiveInteger to nonNegativeInteger
  709. </sitem>
  710. <sitem>
  711. 2000-02-08: pvb: corrected typo in date-lexical-representaion, where a
  712. "specific century" was noted as YY (changed to CC)
  713. </sitem>
  714. <sitem>
  715. 2000-02-08: pvb: changed defn of atomic from being "intrinsically indivisible"
  716. to "regarded as indivisible by this specification"
  717. </sitem>
  718. <sitem>
  719. 2000-02-08: pvb: clarified defn of facet, wrt value spaces and not "concepts
  720. or objects"
  721. </sitem>
  722. <sitem>
  723. 2000-02-08: pvb: merged "terminology" sections from both part 1 and part 2
  724. </sitem>
  725. <sitem>
  726. 2000-02-08: pvb: fixed datatype of scale facet (from pos-int to non-neg-int)
  727. </sitem>
  728. <sitem>
  729. 2000-02-08: pvb: added "priority feedback note" for bigNums
  730. </sitem>
  731. <sitem>
  732. 2000-02-09: pvb: fixed circular defn of decimal, as suggested 
  733. by DC
  734. -->
  735. <!--
  736. <loc href='http://lists.w3.org/Archives/Member/w3c-xml-schema-ig/2000Jan/0365.html'>
  737. http://lists.w3.org/Archives/Member/w3c-xml-schema-ig/2000Jan/0365.html</loc>
  738. -->
  739. <!--
  740. </sitem>
  741. <sitem>
  742. 2000-02-09: pvb: added 1 and 0 to lexical space of boolean
  743. </sitem>
  744. <sitem>
  745. 2000-02-09: pvb: added subsections to section 4...this may get undone when I
  746. dump the abstract syntax, we'll see
  747. </sitem>
  748. <sitem>
  749. 2000-02-10: pvb: added pattern facet to all datatypes
  750. </sitem>
  751. <sitem>
  752. 2000-02-10: pvb: updated several incorrect values in the constraining
  753. facets "table" in Appendix C2.
  754. </sitem>
  755. <sitem>
  756. 2000-02-10: pvb: changed examples to use <documentation> instead
  757. of <info> as the child of <annotation>
  758. </sitem>
  759. <sitem>
  760. 2000-02-10: pvb: added the correct built-in datatypes namespace to
  761. section 3.1 (closes the datatypes portion of issue 78)
  762. </sitem>
  763. <sitem>
  764. 2000-02-10: pvb: changed examples to use <simpleType> instead of
  765. <datatype>, equivalent changes to the DTD and schema will come shortly
  766. closes the datatypes portion of issue 157)
  767. </sitem>
  768. <sitem>
  769. 2000-02-10 : pvb: renamed uri datatype to uriReference; clarified the
  770. defn wrt RFC 2396; included specific mention of absolute vs. relative
  771. uriReferences; still need to be specific about the lexical representation
  772. (closes some parts of issue 212)
  773. </sitem>
  774. <sitem>
  775. 2000-02-15: pvb: added SVC to binary, which says one must give a value for
  776. the encoding facet (i.e., a hack to get around the problem that we don't
  777. have the concept of "required" facets) [part of the resolution to issue 81]
  778. </sitem>
  779. <sitem>
  780. 2000-02-15: pvb: moved ID to a primitive type (since it has validation requirements
  781. above and beyond those provided for subtypes of string).  Also added a Note: to it
  782. making explicit the fact that the value space is scoped to an instance document
  783. (unlike the value space of types such as integer).  Also fixed a bug in the
  784. definition, which referred to Name instead of NCName
  785. [part of the resolution to issue 81]
  786. </sitem>
  787. <sitem>
  788. 2000-02-15: pvb: moved IDREF to a primitive type (since it has validation
  789. requirements above and beyond those provided for subtypes of string).
  790. Added an issue about whether this could be generated from ID.
  791. Also added a Note: to it making explicit the fact that the value space is scoped
  792. to an instance document (unlike the value space of types such as integer).
  793. [part of the resolution to issue 81]
  794. </sitem>
  795. <sitem>
  796. 2000-02-15: pvb: moved IDREFS to a primitive type (since it has validation
  797. requirements above and beyond those provided for subtypes of string)....this is
  798. just a temporary home and it will become generated as list of IDREF when I get
  799. the list stuff implemented
  800. [part of the resolution to issue 81]
  801. </sitem>
  802. <sitem>
  803. 2000-02-15: pvb: moved ENTITY to a primitive type (since it has validation
  804. requirements above and beyond those provided for subtypes of string).
  805. Also added a Note: to it making explicit the fact that the value space is scoped
  806. to an instance document (unlike the value space of types such as integer).
  807. Also added a SVC that entity values must match a declared unparsed entity name.
  808. [part of the resolution to issue 81]
  809. </sitem>
  810. <sitem>
  811. 2000-02-15: pvb: moved ENTITIES to a primitive type (since it has validation
  812. requirements above and beyond those provided for subtypes of string)....this is
  813. just a temporary home and it will become generated as list of ENTITY when I get
  814. the list stuff implemented
  815. [part of the resolution to issue 81]
  816. </sitem>
  817. <sitem>
  818. 2000-02-15: pvb: moved NOTATION to a primitive type (since it has validation
  819. requirements above and beyond those provided for subtypes of string).
  820. Also added a Note: to it making explicit the fact that the value space is scoped
  821. to an instance document (unlike the value space of types such as integer).
  822. Also added a SVC that notation values must match a declared notation name.
  823. [part of the resolution to issue 81]
  824. </sitem>
  825. <sitem>
  826. 2000-02-15: pvb: updated table in appendix C1, to note that all datatypes
  827. are exact
  828. </sitem>
  829. <sitem>
  830. 2000-02-16: pvb: added i4, i8, u4, u8, etc. subtypes of integer, using
  831. editor's discretion in their naming as instructed at the berkeley f2f...changed the
  832. first example in section 4 "Defining Generated Datatypes" to use the Sku
  833. datatype from Part 0, instead of i4 since we now have i4 built-in
  834. </sitem>
  835. <sitem>
  836. 2000-02-16: pvb: removed issue: definition-overriding from the draft
  837. </sitem>
  838. <sitem>
  839. 2000-02-17: pvb: removed the exact vs. approximate distinction entirely
  840. (since all our types turned out to be exact)
  841. </sitem>
  842. <sitem>
  843. 2000-02-17: pvb: removed all mention of aggregate datatypes.  Changed
  844. the "atomic vs. aggregate" dichotomy to be: atomic vs. list.
  845. [part of resolution to issue 112]
  846. </sitem>
  847. <sitem>
  848. 2000-02-17: pvb: clarified defns of value space and lexical space.  In
  849. particular, moved the notion of a literal denoting a value from the defn
  850. to LS to VS and noted that a literal is a character information item from
  851. the info set.
  852. </sitem>
  853. <sitem>
  854. 2000-02-17: pvb: changed terminology of "generated" to "derived", to be
  855. in alignment with the structures spec
  856. [part of resolution to issue 204]
  857. </sitem>
  858. <sitem>
  859. 2000-02-17: pvb: removed definition of term subtype, changed all prose of the
  860. form "for subtypes of X" to "for datatypes derived from X"
  861. [part of resolution to issue 204]
  862. </sitem>
  863. <sitem>
  864. 2000-02-17: pvb: removed a para from Conformance section which mentioned
  865. processor option of turning off validation of certain facets
  866. </sitem>
  867. <sitem>
  868. 2000-02-17: pvb: removed note that order-relations are not defined
  869. </sitem>
  870. <sitem>
  871. 2000-02-17: pvb: made IDREFS, ENTITIES and NMTOKENS derived by list from
  872. IDREF, ENTITY and NMTOKENS respectively.
  873. [part of resolution of issue 81]
  874. </sitem>
  875. <sitem>
  876. 2000-02-17: pvb: clarified what the values {hex,base64} mean for the
  877. encoding facet
  878. </sitem>
  879. <sitem>
  880. 2000-02-17: pvb: added pointers from the 4 mechanisms to create a value space
  881. to the places in the spec where those mechanisms are described
  882. </sitem>
  883. <sitem>
  884. 2000-02-17: pvb: all built-in generated types are now defined in the
  885. schema for datatypes
  886. </sitem>
  887. <sitem>
  888. 2000-02-21: pvb: clarified list datatypes, wrt use of component type
  889. which allows whitespace in its literals and wrt facets applicable for
  890. deriving subtypes of a list type
  891. </sitem>
  892. <sitem>
  893. 2000-02-23: pvb: change defn of binary and meaning of length facet
  894. for binary to be measured in octets, since both lexical encodings
  895. are only defined for octet multiples.
  896. </sitem>
  897. <sitem>
  898. 2000-02-23: pvb: incorporated prose description of regex language
  899. (thanx to Matt Timmermans!!!!)
  900. </sitem>
  901. <sitem>
  902. 2000-02-23: pvb: added appinfo's to built-in definitions in the
  903. schema for datatypes, which are used to generate the list of
  904. constraining facets for each built-in datatype in the html version
  905. of the spec
  906. </sitem>
  907. <sitem>
  908. 2000-02-23: pvb: replaced abstract syntax with 2 new sections for
  909. "schema components" and "xml representation" constructs, still needs
  910. a lot of editorial work tho
  911. </sitem>
  912. <sitem>
  913. 2000-02-23: pvb: list of derived types for each built-in type
  914. is now auto-generated from the builtins.xsd
  915. </sitem>
  916. <sitem>
  917. 2000-02-23: pvb: appendix C.2 (list of datatypes to which each
  918. facet applies) is now auto-generated form the builtins.xsd
  919. </sitem>
  920. <sitem>
  921. 2000-02-24: pvb: put equality back in as a fundamental facet,
  922. to help with the vote on today's telcon regarding key, unique
  923. and keyref value matching.
  924. </sitem>
  925. <sitem>
  926. 2000-02-24: pvb: added 'datatype valid' validation constraint
  927. </sitem>
  928. <sitem>
  929. 2000-02-24: pvb: added stub for 'facet valid' validation constraint
  930. </sitem>
  931. <sitem>
  932. 2000-03-01: pvb: fixed inconsistency in specification of length related
  933. facets for binary type: all are now specified in octets
  934. </sitem>
  935. <sitem>
  936. 2000-03-02: pvb: removed paragraph from section describing the ordered
  937. facet/property which talked about the possibility of multiple order
  938. relations on a value-space
  939. </sitem>
  940. <sitem>
  941. 2000-03-02: pvb: table in appendix C.1 is now auto-generated from
  942. appinfo supplied info w/i the schema for built-ins (builtins.xsd)
  943. </sitem>
  944. <sitem>
  945. 2000-03-03: pvb: changed non-norm reference to SQL to be the
  946. actual ISO bibref
  947. </sitem>
  948. <sitem>
  949. 2000-03-04: pvb: fixed bug in defn of regex, to allow for the
  950. empty regex
  951. </sitem>
  952. <sitem>
  953. 2000-03-08: am: changed date and time datatypes completely (yet again).
  954. </sitem>
  955. <sitem>
  956. 2000-03-10: pvb: added separate appendix for schema for built-in types
  957. </sitem>
  958. <sitem>
  959. 2000-03-10: pvb: changed example for precision facet (old one didn't
  960. apply)
  961. </sitem>
  962. <sitem>
  963. 2000-03-10: pvb: change case on facets and type names to be Pascal-like:
  964. effected facets minlength and maxlength; and datatypes uri-reference,
  965. non-positive-integer, non-negative-integer, negitive-integer,
  966. positive-integer, unsigned-long, unsigned-int, unsigned-short,
  967. unsigned-byte.
  968. </sitem>
  969. <sitem>
  970. 2000-03-10: pvb: fixed example for enumeration facet (to use
  971. recurringDate instead of date for its basetype.
  972. </sitem>
  973. <sitem>
  974. 2000-03-14: am: updated date/time types (yet again): changed
  975. recurringInstant into recurringDuration, made timeInstant
  976. derived from recurringDuration instead of primitive, added timePeriod,
  977. month, year, century, recurringDate, and recurringDay
  978. </sitem>
  979. <sitem>
  980. 2000-03-14: am: modified description of lists of atomic types
  981. that allow whitespace in their literals so that it is clearer
  982. </sitem>
  983. <sitem>
  984. 2000-03-15: pvb: added text (written by Mark Reinhold) to float &
  985. double describing the "best approximation" required for mapping
  986. from lexical to value space
  987. </sitem>
  988. <sitem>
  989. 2000-03-15: pvb: cleaned up description of lexical reps for numeric
  990. types
  991. </sitem>
  992. <sitem>
  993. 2000-03-15: pvb: added some explanatory text to the beginning of
  994. sections 4 and 5
  995. </sitem>
  996. <sitem>
  997. 2000-03-15: pvb: made it clear (in section 4.1) that a datatype's
  998. facets consist of the facets directly specified in the defn as well
  999. as the set inherited from its basetype
  1000. </sitem>
  1001. <sitem>
  1002. 2000-03-15: pvb: cleaned up datatype-valid "validity constribution".
  1003. </sitem>
  1004. <sitem>
  1005. 2000-03-15: pvb: added facet-valid "validity contributions" for each
  1006. facet in section 4 (some just stubs at this point)
  1007. </sitem>
  1008. <sitem>
  1009. 2000-03-15: pvb: moved bibl for clinger1990 from non-normative to
  1010. normative, since we are now requiring his "best approximation" for
  1011. float/double
  1012. </sitem>
  1013. <sitem>
  1014. 2000-03-16: am: Changed section 2.5.1.2 List Datatypes
  1015. </sitem>
  1016. <sitem>
  1017. 2000-03-16: am: Changed section 5.1.2 List Datatype
  1018. </sitem>
  1019. <sitem>
  1020. 2000-03-16: am: Changed section 5.2.1 Length example
  1021. </sitem>
  1022. <sitem>
  1023. 2000-03-16: am: Fixed sections 5.1.13 and 5.2.14
  1024. </sitem>
  1025. <sitem>
  1026. 2000-03-16: am: Changed section on lex rep for
  1027. unsignedLong, unsignedInt, unsignedShort and unsignedByte to remove
  1028. optional sign (after all, they are "unsigned").  Also fixed examples. 
  1029. </sitem>
  1030. <sitem>
  1031. 2000-03-16: am: Changed lex rep section for timePeriod.
  1032. </sitem>
  1033. <sitem>
  1034. 2000-03-16: am: Changed section on timePeriod.
  1035. </sitem>
  1036. <sitem>
  1037. 2000-03-16: am: Removed 2 ednotes from date section.
  1038. </sitem>
  1039. <sitem>
  1040. 2000-03-16: am: Removed ednote from month.  Fixed description.
  1041. </sitem>
  1042. <sitem>
  1043. 2000-03-16: am: Removed ednote from year.  Fixed description.
  1044. </sitem>
  1045. <sitem>
  1046. 2000-03-16: am: Removed ednote from century.  Fixed description.
  1047. </sitem>
  1048. <sitem>
  1049. 2000-03-16: am: Removed ednotes from recurringDate.  Fixed description.
  1050. </sitem>
  1051. <sitem>
  1052. 2000-03-16: am: Removed ednotes from recurringDay. 
  1053. </sitem>
  1054. <sitem>
  1055. 2000-03-16: am: Added wording to 4.2.4 and 4.2.5
  1056. </sitem>
  1057. <sitem>
  1058. 2000-03-16: am: Removed ednotes from section 4 sections on min/max
  1059. inclusive/exclusive.  dates and times compare chronologically.
  1060. </sitem>
  1061. <sitem>
  1062. 2000-03-16: pvb: fixed several problems with the regex appx:
  1063. a) a branch is 0 or more (not 1 or more) (empty regex matches the empty
  1064. string);
  1065. b) added numeric quantifiers ({n,m}, etc.);
  1066. c) fixed bug if meaning of S*;
  1067. d) added { and } to list of metacharacters and "single character escapes";
  1068. e) noted that a "normal character" can be represented as a character
  1069. reference;
  1070. f) added syntax for identifying blocks (e.g., \p{IsBasicLatin})
  1071. </sitem>
  1072. <sitem>
  1073. 2000-03-16: pvb: make QName into a primitive, with value space the
  1074. set of tuples {namespace name, localPart}.  Semantically, this is how it
  1075. should be defined, but it kind of breaks our type system: QName is now
  1076. clearly not an atomic type (it is an aggregate defined in terms of two
  1077. other existing types), which means that it shouldn't be primitive and
  1078. should be derived, but we don't have type generators...oh, well.
  1079. </sitem>
  1080. <sitem>
  1081. 2000-03-16: pvb: uriReference lexical space now specified as strings
  1082. matching the URI-reference production from RFC 2396...still need to
  1083. generate a regex corresponding to that production
  1084. </sitem>
  1085. <sitem>
  1086. 2000-03-17: pvb: moved all COS constraints into the appropriate
  1087. subsection of section 4 "datatype components"
  1088. </sitem>
  1089. <sitem>
  1090. 2000-03-17: pvb: clarified statement in enumeration facet that it
  1091. imposes no order on the value space constructed
  1092. </sitem>
  1093. <sitem>
  1094. 2000-03-17: pvb: clarified precision/scale to be a maximum number
  1095. of digits
  1096. </sitem>
  1097. <sitem>
  1098. 2000-03-17: pvb: completed most of the facet-valid
  1099. "validity contributions" which began as just stubs, still a few more
  1100. to go
  1101. </sitem>
  1102. <sitem>
  1103. 2000-03-17: pvb: explicitly defined the notion of an order relation
  1104. (which was mentioned, but not defined)
  1105. </sitem>
  1106. <sitem>
  1107. 2000-03-17: pvb: corrected defn of string to state that the
  1108. order relation (and not the ordered property) as unicode code point
  1109. </sitem>
  1110. <sitem>
  1111. 2000-03-17: pvb: clarified length, minLength and maxLength facets;
  1112. namely, that string is measured in code points (rather than the ambiguous
  1113. "character"), that binary is measured in octets of the binary data 
  1114. (not the lexical/encoded data), and specified meaning of these facets
  1115. for lists (only length was specified before)
  1116. </sitem>
  1117. <sitem>
  1118. 2000-03-17: pvb: added defns for "constraint on schema", "schema
  1119. representation constraint" and "validation contribution" (largely stolen
  1120. from structures) to terminology section
  1121. </sitem>
  1122. <sitem>
  1123. 2000-03-17: pvb: replaced Conformance section with a subset of the
  1124. equivalent section from structures
  1125. </sitem>
  1126. <sitem>
  1127. 2000-03-17: pvb: added schema representation constraints for
  1128. multiple patterns and enumerations
  1129. </sitem>
  1130. <sitem>
  1131. 2000-03-17: pvb: explicitly defined order relations for
  1132. float, double, timeDuration and recurringDuration
  1133. </sitem>
  1134. <sitem>
  1135. 2000-04-03: pvb: corrected NOTE on ENTITY datatype to say 'defined in a DTD'
  1136. rather than a schema
  1137. </sitem>
  1138. <sitem>
  1139. 2000-04-03: pvb: fixed presentation of table in "Constraint on Schemas: applicable facets"
  1140. </sitem>
  1141. <sitem>
  1142. 2000-04-03: pvb: replaced empty validity contributions on encoding, duration and
  1143. period facet components with NOTEs that they don't participate in validation
  1144. </sitem>
  1145. <sitem>
  1146. 2000-04-03: pvb: removed "open issues" appendix
  1147. </sitem>
  1148. <sitem>
  1149. 2000-04-03: pvb: removed all terms in the "terminology" section which weren't used...also
  1150. made all *uses* of the remaining terms into links to their definitions
  1151. </sitem>
  1152. <sitem>
  1153. 2000-04-03: pvb: styled constraints on schema, etc. in tables, with the table header color
  1154. coded to indicate the type of constraint
  1155. </sitem>
  1156. <sitem>
  1157. 2000-04-03: pvb: modified section on Equality, to note that equality is defined (to be
  1158. not equal) across value spaces not related via restriction.
  1159. </sitem>
  1160. <sitem>
  1161. 2000-04-03: pvb: incorporated new {schema,dtd} for datatypes
  1162. </sitem>
  1163. <sitem>
  1164. 2000-04-04: pvb: replaced ednotes in 5.1.2 with some simple expository text, probably will
  1165. need to be expanded on before CR
  1166. </sitem>
  1167. <sitem>
  1168. 2000-04-04: pvb: rewrote description of truncated forms of timeDuration, so that
  1169. it was more explicit about what is allowed
  1170. </sitem>
  1171. <sitem>
  1172. 2000-07-12: pvb: removed note from DTD/Schema for datatypes included in
  1173. Appendices A&B which says they aren't normative but that they ones
  1174. included in Appednices A&B are:-)
  1175. </sitem>
  1176. <sitem>
  1177. 2000-07-12: pvb: added \| as a single character escape in the regex language
  1178. </sitem>
  1179. <sitem>
  1180. 2000-07-12: pvb: changed all wording of the form "X is derived from Y by
  1181. fixing the value of facet Z to a" to be "X is derived from Y by
  1182. setting the value of facet Z to a", to avoid confusion (since we can't [yet]
  1183. "fix" a facet value).
  1184. </sitem>
  1185. <sitem>
  1186. 2000-07-13: pvb: updated the status of this document section for internal
  1187. point release
  1188. </sitem>
  1189. <sitem>
  1190. 2000-07-13: pvb: added note to section on order relations, to the effect that
  1191. just because this spec doesn't say that a type is ordered doesn't mean that
  1192. down-stream apps can't specify some order relation.
  1193. </sitem>
  1194. <sitem>
  1195. 2000-07-13: pvb: modified stylesheet to make "priority feedback" issues
  1196. more prevalent
  1197. </sitem>
  1198. <sitem>
  1199. 200007-13: pvb: modified markup around PFI for decimal to take advantage of
  1200. the new stylesheet template for PFIs
  1201. </sitem>
  1202. <sitem>
  1203. 2000-07-13: pvb: removed the order relation from string, and hence, the
  1204. min/max facets
  1205. </sitem>
  1206. <sitem>
  1207. 2000-07-13: pvb: turned the <note> in decimal about wanting feedback
  1208. about arbitrary precision into an <ednote role='pf'>, which displays
  1209. specially with new stylesheet
  1210. </sitem>
  1211. <sitem>
  1212. 2000-07-14: pvb: fixed the stylesheet so that it put a space between
  1213. the links "built-in" and "derived" in the auto-generated "Derived types"
  1214. subsection of each type definition.
  1215. </sitem>
  1216. <sitem>
  1217. 2000-07-14: pvb: created a schema for has-facet and has-property used
  1218. in the appinfo of type definitions in the schema for datatypes
  1219. </sitem>
  1220. <sitem>
  1221. 2000-07-14: pvb: modified stylesheet to generate the spec from the
  1222. modified has-facet and has-property appinfo items
  1223. </sitem>
  1224. <sitem>
  1225. 2000-07-15 and 2000-07-16: pvb: my allergies had me in bed all day and
  1226. couldn't get anything done
  1227. </sitem>
  1228. <sitem>
  1229. 2000-07-17: pvb: almost fixed the bugs introduced by the stylesheet
  1230. modifications for has-facet and has-property.  Appendix C still contains
  1231. a few type names duplicated under some facets...I'll get that later.
  1232. </sitem>
  1233. <sitem>
  1234. 2000-07-18: AM: Fixed typos caught by Susan Lesch in her note to schema-comments of May 12.
  1235. </sitem>
  1236. <sitem>
  1237. 2000-07-18: AM: Changed line in date formats to say year 0 not allowed.
  1238. </sitem>
  1239. <sitem>
  1240. 2000-07-18: AM: Changed value space for decimal.
  1241. </sitem>
  1242. <sitem>
  1243. 2000-07-18: AM: Changed text for recurringDuration.
  1244. </sitem>
  1245. <sitem>
  1246. 2000-07-18: AM: Fixed typos in "time".
  1247. </sitem>
  1248. <sitem>
  1249. 2000-07-18: pvb: changed has-facet and has-property to hasFacet and hasProperty
  1250. </sitem>
  1251. <sitem>
  1252. 2000-07-18: pvb: changed definition of decimal again, to give separate defs
  1253. of value space without any facet being valued, with only precision and
  1254. with only scale.  This is intended to clarify what is and is not meant by
  1255. precision and scale.  Also fixed long standing typo in the equation for
  1256. the value space of decimal: i x 10^n corrected to i x 10^-n.
  1257. </sitem>
  1258. <sitem>
  1259. 2000-08-07: pvb: finally found error in stylesheet which was causing XT to
  1260. have a stackOverflow, preventing the release of this version.
  1261. </sitem>
  1262. <sitem>
  1263. 2000-08-15: pvb: added a fixed property to each facet component
  1264. </sitem>
  1265. <sitem>
  1266. 2000-08-15: pvb: removed redundant "if"s in many of the Validation Contributions
  1267. in section 4
  1268. </sitem>
  1269. <sitem>
  1270. 2000-08-15: pvb: removed mention of string from the Validation Contributions
  1271. of the order-related facets (min/max inc/exc) in section 4.  This should have been
  1272. done in a previous draft when string became unordered.
  1273. </sitem>
  1274. <sitem>
  1275. 2000-08-16: pvb: added fixed property to each facet component; added fixed
  1276. attribute to each facet element.  Possible problems with the XML repr for
  1277. pattern and enumeration still to be worked out.
  1278. </sitem>
  1279. <sitem>
  1280. 2000-08-21: pvb: fixed schema dump file, so that stylesheet correctly formats
  1281. the value attribute of all facets as being required.
  1282. </sitem>
  1283. <sitem>
  1284. 2000-08-21: pvb: fixed stylesheet so that "hex | base64" in the XML Rep for
  1285. encoding no longer formated as "| hex | base64"...this also fixed a long standing
  1286. bug in the stylesheet such surrounding properly formating of <choice> in content
  1287. models
  1288. </sitem>
  1289. <sitem>
  1290. 2000-08-22: pvb: added union types
  1291. </sitem>
  1292. <sitem>
  1293. 2000-08-23: pvb: changed defn syntax to conform to union proposal, including
  1294. changes to stylesheet to get autogenerated text from datatypes.xsd to format
  1295. correctly
  1296. </sitem>
  1297. <sitem>
  1298. 2000-08-24: pvb: cleaned up a few sections so that they are consistent with
  1299. the (now) 3 forms of derivation (where there used to be only 2)
  1300. </sitem>
  1301. <sitem>
  1302. 2000-08-24: pvb: marked app B (DTD) as non-normative
  1303. </sitem>
  1304. <sitem>
  1305. 2000-08-30: AM: added definition of canonical form as 2.4.
  1306. </sitem>
  1307. <sitem>
  1308. 2000-08-30: AM: added canonical forms for all built-in datatypes.
  1309. </sitem>
  1310. <sitem>
  1311. 2000-08-30: AM: changed lex space for boolean to {true, false}.
  1312. </sitem>
  1313. <sitem>
  1314. 2000-08-31: AM: removed fixed property from pattern and enumeration
  1315. pending resolution of how to handle these two cases.
  1316. </sitem>
  1317. <sitem>
  1318. 2000-08-31: AM: fixed syntax for examples.  Added "fixed" for 2 examples.
  1319. </sitem>
  1320. <sitem>
  1321. 2000-08-31: AM: removed pattern facet from binary.
  1322. </sitem>
  1323. <sitem>
  1324. 2000-08-31: AM: changed value space for timeDuration.  Some bug fixes to
  1325. Appendix D.  
  1326. </sitem>
  1327.  
  1328. PR commented out ended here
  1329.  
  1330. <sitem>
  1331. 2000-09-28: PVB: fixed syntax errors in example schemas for "Derivation by Union"
  1332. and "enumeration" facet.
  1333. </sitem>
  1334. <sitem>
  1335. 2000-09-28: PVB: fixed typos in content models of restriction, list and union
  1336. in section "XML Representation of Datatype Definitions".  Still need to fix stylesheet
  1337. to correctly generate "List of QName" for the type of the memberTypes attribute
  1338. on union.
  1339. </sitem>
  1340. <sitem>
  1341. 2000-09-28: PVB: fixed typo in section on equality, where "restriction" was left
  1342. out of the final sentence, beginning "By definition".
  1343. </sitem>
  1344. <sitem>
  1345. 2000-09-28: PVB: added appropriate definitions for a list's "itemType" and
  1346. a union's "memberTypes".
  1347. </sitem>
  1348. <sitem>
  1349. 2000-09-28: PVB: folded old Constraint on Schemas: length and maxLength into
  1350. the existing Constraint on Schemas: length and minLength
  1351. </sitem>
  1352. <sitem>
  1353. 2000-09-28: PVB: fixed many typos as reported by Wayne Carr in post on
  1354. 2000-09-17.
  1355. </sitem>
  1356. <sitem>
  1357. 2000-09-29: PVB: fixed NOTATION datatype, by requiring at least one enumeration
  1358. facet and further requiring that all enumeration facets name a declared notation.
  1359. Folded the old "NOTATION declared" constraint into a new COS: "enumeration required
  1360. for NOTATION"
  1361. </sitem>
  1362. <sitem>
  1363. 2000-09-29: PVB: changed SVC "encoding required" to a COS.
  1364. </sitem>
  1365. <sitem>
  1366. 2000-09-29: PVB: implemented WG decision in LC-7: minimum number of
  1367. decimal digits for precision.
  1368. </sitem>
  1369. <sitem>
  1370. 2000-09-29: PVB: started removing inconsistencies introduced by the presence
  1371. of list and union as derivation methods: i.e., it is no longer the case that
  1372. all derived types have a base type, it is only those types derived by
  1373. restriction that do (lists have itemType's, while unions have memberTypes).
  1374. Still have much more to clean up in this regard tho, including rework in
  1375. sections 4.1 and 5.1.
  1376. </sitem>
  1377. <sitem>
  1378. 2000-09-29: PVB: updated the schema and datatypes namespaces to be consistent
  1379. with the Hawthorne votes
  1380. </sitem>
  1381. <sitem>
  1382. 2000-10-02: AM: fixed value space for recurring duration.
  1383. </sitem>
  1384. <sitem>
  1385. 2000-10-02: AM: added info about timeDuration to Appendix D.
  1386. </sitem>
  1387. <sitem>
  1388. 2000-10-02: AM: rewrote order property for timeDuration and recurringDuration.
  1389. </sitem>
  1390. <sitem>
  1391. 2000-10-02: AM: added canonical lexical forms for list and union.
  1392. </sitem>
  1393. <sitem>
  1394. 2000-10-04: PVB: minor editorial fix in prose describing recurringDuration
  1395. and timeDuration
  1396. </sitem>
  1397. <sitem>
  1398. 2000-10-04: PVB: fixed lexical space of NOTATION to be the set of names of
  1399. declared NOTATIONs and added the fact that NOTATION is derived from QName.
  1400. </sitem>
  1401. <sitem>
  1402. 2000-10-05: PVB: added S{n} to the regex language, which should have been
  1403. there all the time (equiv to S{n,n})
  1404. </sitem>
  1405. <sitem>
  1406. 2000-10-06: PVB: added whiteSpace facet, component def and XML Rep for it.
  1407. </sitem>
  1408. <sitem>
  1409. 2000-10-06: PVB: changed the initial wording of CVC Datatype Valid to
  1410. say that "a string is..." instead of "a sequence of char info items is...".
  1411. Makes the spec more generally applicable.
  1412. </sitem>
  1413. <sitem>
  1414. 2000-10-06: PVB: flushed out schema components and XML representation/
  1415. property mapping, to encorporate derivation by restriction, list
  1416. and union
  1417. </sitem>
  1418. <sitem>
  1419. 2000-10-06: PVB: sync'd the acknowledgement sections with Part 1
  1420. </sitem>
  1421. <sitem>
  1422. 2000-10-06: PVB: flushed out the schema for datatypes, such that all
  1423. datatype definitions have an id attribute, all  elements involved in 
  1424. datatype definitions also now have an id attribute.  Each
  1425. built-in datatype definition has a documentation annotation that
  1426. points to the section of the spec where that datatype is described;
  1427. each element used for facets also has a documentation annotation
  1428. that points to the section of the spec where that facet is defined.
  1429. </sitem>
  1430. <sitem>
  1431. 2000-10-11: PVB: fixed bug in SVC that said that union/@memberTypes and
  1432. union/child::simpleType were mutually exclusive...the corrected constraint
  1433. is simply that at least one of them must be valued.
  1434. </sitem>
  1435. <sitem>
  1436. 2000-10-11: PVB: fixed the broken link on the XML Rep for union, to point
  1437. to the Datatype Definition component (there is no union component).
  1438. </sitem>
  1439. <sitem>
  1440. 2000-10-16: PVB: clarified property mapping for memberTypes property
  1441. in the XML Rep of the Union Element Information Item for Datatype Definitions.
  1442. </sitem>
  1443. <sitem>
  1444. 2000-10-16: PVB: fixed typo on the XML Rep of the Union Element Information Item
  1445. that incorrectly referred to a "union" schema component.
  1446. </sitem>
  1447. <sitem>
  1448. 2000-10-16: PVB: fixed many broken links
  1449. </sitem>
  1450. <sitem>
  1451. 2000-10-16: PVB: added xml:lang='en' to all documentation elements in
  1452. the schema for datatypes
  1453. </sitem>
  1454. <sitem>
  1455. 2000-10-18: PVB: fixed typo in century which said that 20 was the lexical
  1456. for the 19th century...it is now 19 is the literal for 20th century
  1457. </sitem>
  1458. <sitem>
  1459. 2000-10-18: PVB: fixed copy-paste typos in specification of min/maxLength
  1460. facet, which said just "length" in several places
  1461. </sitem>
  1462. <sitem>
  1463. 2000-10-18: PVB: removed mention of character info items in the definition
  1464. of lexical space (and literal)
  1465. </sitem>
  1466. <sitem>
  1467. 2000-10-18: PVB: cleared up ambiguous (many) uses of the word "may" that were
  1468. not used in the sense of the term "may" in the Terminology section...made sure
  1469. that all correct uses of "may" were linked to the definition
  1470. </sitem>
  1471. <sitem>
  1472. 2000-10-18: PVB: definition of match aligned with XML 1.0 2e
  1473. </sitem>
  1474. <sitem>
  1475. 2000-10-18: PVB: changed string length-related facets to be measured in
  1476. terms of XML 1.0 characters instead of code points
  1477. </sitem>
  1478. <sitem>
  1479. 2000-10-18: PVB: added note to string length-related facets stating that
  1480. length may not be what some users perceive as the "string length"
  1481. </sitem>
  1482. <sitem>
  1483. 2000-10-18: PVB: changed example in description of hex encoding to something
  1484. more "binary"
  1485. </sitem>
  1486. <sitem>
  1487. 2000-10-18: PVB: clarified value space of string in terms of XML 1.0 characters.
  1488. </sitem>
  1489. <sitem>
  1490. 2000-10-18: PVB: fixed (thought this was already done, but I guess not) Appdx
  1491. D to note that hours range form 0-23, minutes from 0-59 and seconds from 0-59 or
  1492. 0-60 in the case of leap seconds.
  1493. </sitem>
  1494. <sitem>
  1495. 2000-10-18: PVB: definition of language now references the "Language Identifiers"
  1496. section in XML 1.02e instead of the LanguageID production (which is gone in 2e).
  1497. </sitem>
  1498. <sitem>
  1499. 2000-10-18: PVB: added a PFR requesting advice on whether future versions should
  1500. allow embedded white space in regex's.
  1501. </sitem>
  1502. <sitem>
  1503. 2000-10-18: PVB: removed Cs property from regex language and added note stating
  1504. why it is the only property not allowed
  1505. </sitem>
  1506. <sitem>
  1507. 2000-10-18: PVB: fixed typo in character range expansion of \w escape in
  1508. the regex language
  1509. </sitem>
  1510. <sitem>
  1511. 2000-10-18: PVB: now sites XML 1.0 2e and Unicode 3 normatively, and ISO 10646
  1512. and Unicode 2 non-normatively.
  1513. </sitem>
  1514. <sitem>
  1515. 2000-10-18: PVB: added note stating that conforming processors are only required
  1516. to support the Unicode char props and block names in the regex language are are
  1517. current at the time this spec goes to Rec, but that implementors are encouraged
  1518. to provide access to future revisions to Unicode.
  1519. </sitem>
  1520. <sitem>
  1521. 2000-10-18: PVB: added note about possible future support for "Level 2" in
  1522. regex's
  1523. </sitem>
  1524. <sitem>
  1525. 2000-10-18: PVB: changed body-temp example from fahrenheit to celsius
  1526. </sitem>
  1527. <sitem>
  1528. 2000-10-18: PVB: added xml:lang='en' to all documentation annotations in
  1529. the schema for datatypes
  1530. </sitem>
  1531. <sitem>
  1532. 2000-10-19: PVB: added note to the effect that recurringDuration won't meet
  1533. the needs of all calendaring/scheduling applications
  1534. </sitem>
  1535. <sitem>
  1536. 2000-10-19: PVB: added PFR to recurringDuration asking for interop feedback
  1537. not just between schema processors but with other date/time systems
  1538. </sitem>
  1539. <sitem>
  1540. 2000-10-19: PVB: added PFR regarding order-relation on timeDuration
  1541. </sitem>
  1542. <sitem>
  1543. 2000-10-19: PVB: added note on uriReference about hex encoding and
  1544. possible "out-of-sync" problems with XMl 1.0, XPointer and CharMod.
  1545. </sitem>
  1546. <sitem>
  1547. 2000-10-19: PVB: removed ednote on pattern for binary
  1548. </sitem>
  1549. <sitem>
  1550. 2000-11-21: AM: added sentence on float and double special values.
  1551. </sitem>
  1552. <sitem>
  1553. 2000-11-22: AM: fixed minor bugs in lexical and canonical representations of the date/time datatypes.
  1554. </sitem>
  1555. <sitem>
  1556. 2000-11-27: AM: removed century and recurringDuration.  Made timeInstant,
  1557. timePeriod, recurringDate, recurringDay primitive.
  1558. </sitem>
  1559. <sitem>
  1560. 2000-11-27: AM: renamed CDATA to normalizedString.
  1561. </sitem>
  1562. <sitem>
  1563. 2000-11-28: AM: made timeInstant and timePeriod primitive datatypes.
  1564. Also, recurringDate and recurringDay.
  1565. </sitem>
  1566. <sitem>
  1567. 2000-11-28: AM: added new sections on order relations for timeDuration and
  1568. timeInstant.  Added Appendix E on addition of timeInstant and durations.
  1569. </sitem>
  1570. <sitem>
  1571. 2000-11-28: AM: changed canonical representation for decimal.
  1572. </sitem>
  1573. <sitem>
  1574. 2000-11-28: AM: made all date/time datatypes primitive types.
  1575. </sitem>
  1576. <sitem>
  1577. 2000-11-28: AM: changed recurringDate to gMonthDay, recurringDay to day and month to yearMonth.
  1578. </sitem>
  1579. <sitem>
  1580. 2000-12-21: AM: fixed NMTOKENS, ENTITIES, IDREFS to have minLength = 1.
  1581. </sitem>
  1582. <sitem>
  1583. 2000-12-21: AM: changed introductory section on order facet to discuss partial order..
  1584. </sitem>
  1585. <sitem>
  1586. 2001-01-22: am: added 1 and 0 to lexical space of boolean.  Created placeholder
  1587. section for canonical representtaion for boolean.
  1588. </sitem>
  1589. <sitem>
  1590. 2001-01-22: am: Changed section on facet comparison for timeDuration.  
  1591. </sitem>
  1592. <sitem>
  1593. 2001-01-22: am: Changed name timeDuration to duration and timeInstant to dateTime.  
  1594. </sitem>
  1595. <sitem>
  1596. 2001-01-22: am: Removed binary.  Replaced with hexBinary and base64Binary.
  1597. Removed encoding facet.  
  1598. </sitem>
  1599. <sitem>
  1600. 2001-02-16: PVB: A whole host of changes that I haven't documented yet.
  1601. </sitem>
  1602. <sitem>
  1603. 2001-03-01: PVB: changed the name of uriReference to anyURI as a result
  1604. of vote at boston f2f descision
  1605. </sitem>
  1606. <sitem>
  1607. 2001-03-08: PVB: moved references to unicode and ISO 10646 to the non-normative
  1608. section, since we get their content through the normative ref to XML 1.02e.
  1609. </sitem>
  1610. <sitem>
  1611. 2001-03-08: PVB: correctly updated reference to the Jan 2001 CharMod draft
  1612. </sitem>
  1613. <sitem>
  1614. 2001-03-08: PVB: removed all Priority Feedback Requests
  1615. </sitem>
  1616. <sitem>
  1617. 2001-03-11: PVB: changed am's affiliation
  1618. </sitem>
  1619. <sitem>
  1620. 2001-03-11: PVB: added the ability to make a simpleType final, thus
  1621. blocking any further derivation
  1622. </sitem>
  1623. <sitem>
  1624. 2001-03-11: PVB: added the text that has always been in the schema for
  1625. datatypes regarding the unique IDs for datatypes, facets, and datatype/facet
  1626. pairs to the beginning of section 3.
  1627. </sitem>
  1628. <sitem>
  1629. 2001-03-11: PVB: added language intended to clarify the why the built-in
  1630. types are defined in both the schema NS and in the built-in NS
  1631. </sitem>
  1632. <sitem>
  1633. 2001-03-11: PVB: added {true,false} as the canonical rep for boolean
  1634. </sitem>
  1635. <sitem>
  1636. 2001-03-11: PVB: added definition for derivation by restriction, which
  1637. makes it clear that a restriction must result in subseted value space
  1638. </sitem>
  1639. <sitem>
  1640. 2001-03-11: PVB: added a SRC which rules out multiple occurances of
  1641. facets, other than pattern and enumeration
  1642. </sitem>
  1643. <sitem>
  1644. 2001-03-11: PVB: removed fixed attribute from pattern and enumeration facets
  1645. </sitem>
  1646. <sitem>
  1647. 2001-03-11: PVB: added note that spaces are discouraged in anyURI
  1648. </sitem>
  1649. <sitem>
  1650. 2001-03-11: PVB: added note clarifying that a namespace decl must be
  1651. in scope for the lexical-to-value space mapping
  1652. </sitem>
  1653. <sitem>
  1654. 2001-03-11: PVB: added "related by union" to the clause that equality
  1655. clause that says that values from unrelated types are not equal.
  1656. </sitem>
  1657. <sitem>
  1658. 2001-03-11: PVB: fixed definition(s) of bounded, such that the bound
  1659. does not necessarily have to be in the value space (to account for
  1660. min/maxExclusive) and modified the definitions of min/maxExclusive to
  1661. reference the new definitions
  1662. </sitem>
  1663. <sitem>
  1664. 2001-03-12: PVB: fixed typo ("although [not=>no] value space...") in
  1665. definition of cardinality
  1666. </sitem>
  1667. <sitem>
  1668. 2001-03-13: PVB: changed name of decimal to number; precision to totalDigits
  1669. and scale to fractionDigits
  1670. </sitem>
  1671. <sitem>
  1672. 2001-03-14: pvb: removed references to Unicode and 10646 (but kept
  1673. normative ref to the Unicode DB)
  1674. </sitem>
  1675. <sitem>
  1676. 2001-03-14: pvb: changed names of day, month, year, monthDay and yearMonth
  1677. to gDay, gMonth, gYear, gMonthDay and gYearMonth; also added health warnings
  1678. that conversion to other calendar systems may not result in simple values
  1679. </sitem>
  1680. <sitem>
  1681. 2001-03-14: pvb: added a note about how to get AND behavior with
  1682. patterns
  1683. </sitem>
  1684. <sitem>
  1685. 2001-03-14: pvb: updated description of value/lexical space of anyURI,
  1686. including note that scheme-specific syntax checking is not part of
  1687. type validity.  Also added note that spaces are discouraged, and added
  1688. anyURI to the discussion in the section on lists of types with spaces.
  1689. </sitem>
  1690. <sitem>
  1691. 2001-03-14: pvb: added health warning to string, stating that it isn't
  1692. always appropriate for text
  1693. </sitem>
  1694. <sitem>
  1695. 2001-03-14: pvb: made NOTATION primitive, made the value space all QNames,
  1696. and removed the constraint that the enumeration given must be that of
  1697. the name of a notation declared in the schema.
  1698. </sitem>
  1699. <sitem>
  1700. 2001-03-14: pvb: added note that AM used to work for IBM and that his
  1701. participation until now was supported by IBM
  1702. </sitem>
  1703. <sitem>
  1704. 2001-03-14: pvb: removed Cs from the legal properties in the regex BNF
  1705. (it was already absent from the table of properties)
  1706. </sitem>
  1707. <sitem>
  1708. 2001-03-14: pvb: removed surrogate blocks from the BlockNames table in
  1709. the regex appendix
  1710. </sitem>
  1711. <sitem>
  1712. 2001-03-15: pvb: fixed one remaining problem in the defns for bounds
  1713. introduced on 2001-03-11.
  1714. </sitem>
  1715. <sitem>
  1716. 2001-03-15: pvb: changed all occurances of "namespace URI" to "namespace name"
  1717. to be consistent with the latest Infoset draft
  1718. </sitem>
  1719. <sitem>
  1720. 2001-03-15: pvb: renamed datatype definition component as simple type definition
  1721. component; changed itemType and memberTypes properties to "item type" and "member types"
  1722. </sitem>
  1723. <sitem>
  1724. 2001-03-15: pvb: added components for all fundamental facets; moved the
  1725. prose that specified how they get their values from the simple type definition
  1726. component to each individual component.
  1727. </sitem>
  1728. <sitem>
  1729. 2001-03-15: pvb: changed wording in property mapping of annoations to be
  1730. the same as that in structures
  1731. </sitem>
  1732. <sitem>
  1733. 2001-03-15: pvb: changed final from a boolean to {restirction, list, union}
  1734. </sitem>
  1735. <sitem>
  1736. 2001-03-15: pvb: changed pattern-valid and datatype-valid constraints
  1737. to check pattern against the lexical-space
  1738. </sitem>
  1739. <sitem>
  1740. 2001-03-15: pvb: added "F restriction valid" COS's that rule out all
  1741. forms of invalid restriction for each facet F
  1742. </sitem>
  1743. <sitem>
  1744. 2001-03-15: pvb: cleaned up equality, and partial and total orders
  1745. </sitem>
  1746. <sitem>
  1747. 2001-03-30: pvb: changed name of number back to decimal
  1748. </sitem>
  1749.  End of commented out section -->
  1750. <sitem>
  1751. 2001-04-03: pvb: added 0-9 to IsBlock production (to cover Latin1-Suppliment)
  1752. </sitem>
  1753. <sitem>
  1754. 2001-04-03: pvb: fixed typos in \w (word char) multi-char escape:
  1755. \p{S} -> \p{Z} and "control" -> "other"
  1756. </sitem>
  1757. <sitem>
  1758. 2001-04-03: pvb: modified the pattern facet on language in the schema
  1759. for datatypes to restrict sub-tags to no more than 8 chars, and changed
  1760. the xsd:documentation to discuss section 2.12 of XML 1.02e and RFC 1766
  1761. instead of "production 33 of XML 1.0".
  1762. </sitem>
  1763. <sitem>
  1764. 2001-04-03: pvb: fixed the order relation on duration from x <= y iff s+x <= s+y
  1765. </sitem>
  1766. <sitem>
  1767. 2001-04-03: pvb: fixed incorrect values in duration partial order table (from
  1768. <= and >= to <>.
  1769. </sitem>
  1770. <sitem>
  1771. 2001-04-03: pvb: clarified a misleading statement in the lexical representation
  1772. for durations regarding the omitition of "lower order items".
  1773. </sitem>
  1774. <sitem>
  1775. 2001-04-03: pvb: clarified COS "maxInclusive-maxExclusive" and "minInclusive and minExclusive"
  1776. to note that the prohibitions are within a single derivation step
  1777. </sitem>
  1778. <sitem>
  1779. 2001-04-03: pvb: {typ,think}os in definition of restriction: missing "when" added
  1780. and "one or more facet" changed to "zero or more"
  1781. </sitem>
  1782. <sitem>
  1783. 2001-04-03: pvb: added gYearMonth and gDay to the list of types for which
  1784. appendix E applies
  1785. </sitem>
  1786. <sitem>
  1787. 2001-04-03: pvb: fixed incorrect comparisons in dateTime order relation algorithm
  1788. (from <= to < and >= to >.
  1789. </sitem>
  1790. <sitem>
  1791. 2001-04-03: pvb: in COS "maxExclusive-valid-restriction", fixed 2nd clause:
  1792. {value} >= maxInclusive(parent) -> {value} > maxInclusive(parent)
  1793. </sitem>
  1794. <sitem>
  1795. 2001-04-03: pvb: in COS "minExclusive-valid-restriction", fixed 1st clause:
  1796. {value} > minExclusive(parent) -> {value} < minExclusive(parent)
  1797. </sitem>
  1798. <sitem>
  1799. 2001-04-04: pvb: in COS "minExclusive-valid-restriction", fixed 3rd clause:
  1800. {value} <= minInclusive(parent) -> {value} < minInclusive(parent)
  1801. </sitem>
  1802. <sitem>
  1803. 2001-04-04: pvb: in COS "length-valid-restriction", fixed:
  1804. {value} > length(parent) -> {value} != length(parent)
  1805. </sitem>
  1806. <sitem>
  1807. 2001-04-04: pvb: changed antisymmetry to asymmetry in description of
  1808. properties of partial orders: a R b and b R a ==> a = b -> a R b ==> not(b R a)
  1809. </sitem>
  1810. <sitem>
  1811. 2001-04-04: pvb: fixed how cardinality gets valued for atomic types...if
  1812. base is finite, then restriction is finite; else, added length, maxLength,
  1813. totalDigits and fractionDigits to the list of facets which guarantee finite.
  1814. </sitem>
  1815. <sitem>
  1816. 2001-04-10: pvb: fixed typo in schema def of ENTITIES;
  1817. <xs:minLength value="1" id="ENTITES.minLength"/> went to
  1818. <xs:minLength value="1" id="ENTITIES.minLength"/>
  1819. </sitem>
  1820. <sitem>
  1821. 2001-04-12: pvb: added canonical form for hexBinary
  1822. </sitem>
  1823. <sitem>
  1824. 2001-04-23: pvb: completed first pass at "refactoring": bringing all
  1825. there is to know about any concept (e.g., a facet) into the same section,
  1826. instead of having it spread all over the spec...thus, making this spec
  1827. closer in organization to part 1.
  1828. </sitem>
  1829. <sitem>
  1830. 2001-04-23: pvb: brought the stylesheet for parts 1 and 2 into alignment,
  1831. so that both parts can use the same stylesheet.
  1832. </sitem>
  1833. <sitem>
  1834. 2001-04-24: pvb: fixed several occurances of <xspecref> which should have
  1835. been <xnt> (e.g., Name and NCName)
  1836. </sitem>
  1837. <sitem>
  1838. 2001-04-24: pvb: fixed order in which derived types are listed in section 3
  1839. </sitem>
  1840. <sitem>
  1841. 2001-04-25: pvb: removed dichot vs. tricot ednote
  1842. </sitem>
  1843. <sitem>
  1844. 2001-04-25: pvb: clarified that optional + sign is not allowed in mantisa or
  1845. exponent of canon rep for float/double
  1846. </sitem>
  1847. <sitem>
  1848. 2001-04-25: pvb: clarified that both hh:mm are required for time zones
  1849. </sitem>
  1850. <sitem>
  1851. 2001-04-25: pvb: fixed bug in dateTime normalization example
  1852. </sitem>
  1853. <sitem>
  1854. 2001-04-25: pvb: fixed bug in indeterminate dateTime compare example
  1855. </sitem>
  1856. <sitem>
  1857. 2001-04-25: pvb: updated reference to unicode char db 3.1, as well as 
  1858. the table of block names and general category values accordingly
  1859. </sitem>
  1860. <sitem>
  1861. 2001-04-26: pvb: rewrote enumeration valid constraint to be less confusing
  1862. </sitem>
  1863. <sitem>
  1864. 2001-04-26: pvb: corrected description of how cardinality gets valued to
  1865. account for date types
  1866. </sitem>
  1867. <sitem>
  1868. 2001-04-26: pvb: corrected signs of timezones in clauses C and D of dateTime
  1869. comparison algorithm
  1870. </sitem>
  1871. <sitem>
  1872. 2001-04-26: pvb: added note to ENTITY specifying value space is scoped, like the
  1873. one in ENTITIES
  1874. </sitem>
  1875. <sitem>
  1876. 2001-04-26: pvb: clarified that only the seconds part of durations may specify
  1877. fractions
  1878. </sitem>
  1879. <sitem>
  1880. 2001-04-26: pvb: corrected incorrect namespace name in section 3
  1881. </sitem>
  1882. <sitem>
  1883. 2001-04-26: pvb: added "...(and other relevant portions of section 4)..." to
  1884. the part of conformance that references the XML Rep of simple type defns.
  1885. </sitem>
  1886. <sitem>
  1887. 2001-04-26: pvb: moved equal to section 4
  1888. </sitem>
  1889. <sitem>
  1890. 2001-04-26: pvb: added fact that canonical rep for midnight is 00:00:00 to
  1891. time
  1892. </sitem>
  1893. <sitem>
  1894. 2001-04-26: pvb: added note to ordered and bounded that when inheriting value
  1895. from basetype, the value for primitive types is in appx C.
  1896. </sitem>
  1897. <sitem>
  1898. 2001-04-26: pvb: removed {pos,neg}CharGroupND productions from regex and
  1899. redefined the charClassSub production as :== ( posCharGroup | negCharGroup) '-' charClassExpr
  1900. (and moved a few other productions around as a result)
  1901. </sitem>
  1902. </slist>
  1903. </revisiondesc>
  1904. </header>
  1905. <body>
  1906. <div1 id="Intro">
  1907. <head>Introduction</head>
  1908. <div2 id="purpose">
  1909. <head>Purpose</head>
  1910. <p>
  1911. The <bibref ref="XML"/> specification defines limited
  1912. facilities for applying datatypes to document content in that documents
  1913. may contain or refer to DTDs that assign types to elements and attributes.
  1914. However, document authors, including authors of traditional
  1915. <emph>documents</emph> and those transporting <emph>data</emph> in XML,
  1916. often require a higher degree of type checking to ensure robustness in
  1917. document understanding and data interchange.
  1918. </p>
  1919. <p>
  1920. The table below offers two typical examples of XML instances
  1921. in which datatypes are implicit: the instance on the left
  1922. represents a billing invoice, the instance on the
  1923. right a memo or perhaps an email message in XML.
  1924. </p>
  1925. <table class="dtdemo" border="1">
  1926. <thead>
  1927. <tr>
  1928. <th>Data oriented</th>
  1929. <th>Document oriented</th>
  1930. </tr>
  1931. </thead>
  1932. <tbody>
  1933. <tr>
  1934. <td>
  1935. <eg><![CDATA[<invoice>
  1936.   <orderDate>1999-01-21</orderDate>
  1937.   <shipDate>1999-01-25</shipDate>
  1938.   <billingAddress>
  1939.    <name>Ashok Malhotra</name>
  1940.    <street>123 Microsoft Ave.</street>
  1941.    <city>Hawthorne</city>
  1942.    <state>NY</state>
  1943.    <zip>10532-0000</zip>
  1944.   </billingAddress>
  1945.   <voice>555-1234</voice>
  1946.   <fax>555-4321</fax>
  1947. </invoice>]]></eg>
  1948. </td>
  1949. <td>
  1950. <eg><![CDATA[<memo importance='high'
  1951.       date='1999-03-23'>
  1952.   <from>Paul V. Biron</from>
  1953.   <to>Ashok Malhotra</to>
  1954.   <subject>Latest draft</subject>
  1955.   <body>
  1956.     We need to discuss the latest
  1957.     draft <emph>immediately</emph>.
  1958.     Either email me at <email>
  1959.     mailto:paul.v.biron@kp.org</email>
  1960.     or call <phone>555-9876</phone>
  1961.   </body>
  1962. </memo>]]></eg>
  1963. </td>
  1964. </tr>
  1965. </tbody>
  1966. </table>
  1967. <p>
  1968. The invoice contains several dates and telephone numbers, the postal
  1969. abbreviation for a state
  1970. (which comes from an enumerated list of sanctioned values), and a ZIP code
  1971. (which takes a definable regular form).  The memo contains many
  1972. of the same types of information: a date, telephone number, email address
  1973. and an "importance" value (from an enumerated
  1974. list, such as "low", "medium" or "high").  Applications which process
  1975. invoices and memos need to raise exceptions if something that was
  1976. supposed to be a date or telephone number does not conform to the rules
  1977. for valid dates or telephone numbers.
  1978. </p>
  1979. <p>
  1980. In both cases, validity constraints exist on the content of the
  1981. instances that are not expressible in XML DTDs.  The limited datatyping
  1982. facilities in XML have prevented validating XML processors from supplying
  1983. the rigorous type checking required in these situations.  The result
  1984. has been that individual applications writers have had to implement type
  1985. checking in an ad hoc manner.  This specification addresses
  1986. the need of both document authors and applications writers for a robust,
  1987. extensible datatype system for XML which could be incorporated into
  1988. XML processors.  As discussed below, these datatypes could be used in other
  1989. XML-related standards as well.
  1990. </p>
  1991. </div2>
  1992. <div2 id="requirements">
  1993. <head>Requirements</head>
  1994. <p>
  1995. The <bibref ref="schema-requirements"/> document spells out
  1996. concrete requirements to be fulfilled by this specification,
  1997. which state that the XML Schema Language must:
  1998. </p>
  1999. <olist>
  2000. <item>
  2001. <p>
  2002. provide for primitive data typing, including byte, date,
  2003. integer, sequence, SQL and Java primitive datatypes, etc.;
  2004. </p>
  2005. </item>
  2006. <item>
  2007. <p>
  2008. define a type system that is adequate for import/export
  2009. from database systems (e.g., relational, object, OLAP);
  2010. </p>
  2011. </item>
  2012. <item>
  2013. <p>
  2014. distinguish requirements relating to lexical data representation
  2015. vs. those governing an underlying information set;
  2016. </p>
  2017. </item>
  2018. <item>
  2019. <p>
  2020. allow creation of user-defined datatypes, such as
  2021. datatypes that are derived from existing datatypes and which
  2022. may constrain certain of its properties (e.g., range,
  2023. precision, length, format).
  2024. </p>
  2025. </item>
  2026. </olist>
  2027. </div2>
  2028. <div2 id="scope">
  2029. <head>Scope</head>
  2030. <p>
  2031. This portion of the XML Schema Language discusses datatypes that can be
  2032. used in an XML Schema.  These datatypes can be specified for element
  2033. content that would be specified as
  2034. <xspecref href="&xmlspec;#dt-chardata">#PCDATA</xspecref> and attribute
  2035. values of <xspecref href="&xmlspec;#sec-attribute-types">various
  2036. types </xspecref> in a DTD.  It is the intention of this specification
  2037. that it be usable outside of the context of XML Schemas for a wide range
  2038. of other XML-related activities such as <bibref ref="XSL"/> and
  2039. <bibref ref="RDFSchema"/>.
  2040. </p>
  2041. </div2>
  2042. <div2 id="terminology">
  2043. <head>Terminology</head>
  2044. <p>
  2045. The terminology used to describe XML Schema Datatypes is defined in the
  2046. body of this specification. The terms defined in the following list are
  2047. used in building those definitions and in describing the actions of a
  2048. datatype processor:
  2049. </p>
  2050. <glist>
  2051. <gitem>
  2052. <label>
  2053. <termdef id="dt-compatibility" term="for compatibility">
  2054. for compatibility</termdef>
  2055. </label>
  2056. <def>
  2057. <p>
  2058. A feature of this specification included solely to ensure that schemas
  2059. which use this feature remain compatible with <bibref ref="XML"/>
  2060. </p>
  2061. </def>
  2062. </gitem>
  2063. <gitem>
  2064. <label>
  2065. <termdef id="dt-may" term="may"><term>may</term></termdef>
  2066. </label>
  2067. <def>
  2068. <p>
  2069. Conforming documents and processors are permitted to but need
  2070. not behave as described.
  2071. </p>
  2072. </def>
  2073. </gitem>
  2074. <gitem>
  2075. <label>
  2076. <termdef id="dt-match" term="match"><term>match</term></termdef>
  2077. </label>
  2078. <def>
  2079. <p>
  2080. (Of strings or names:) Two strings or names being compared must be
  2081. identical. Characters with multiple possible representations in ISO/IEC 10646 (e.g.
  2082. characters with both precomposed and base+diacritic forms) match only if they have
  2083. the same representation in both strings. No case folding is performed. (Of strings and
  2084. rules in the grammar:) A string matches a grammatical production if it belongs to the
  2085. language generated by that production. 
  2086. </p>
  2087. </def>
  2088. </gitem>
  2089. <gitem>
  2090. <label>
  2091.  <termdef id="dt-must" term="must"><term>must</term></termdef>
  2092. </label>
  2093. <def>
  2094. <p>
  2095. Conforming documents and processors are required to behave as
  2096. described; otherwise they are in <termref def="dt-error">error</termref>.
  2097. </p>
  2098. </def>
  2099. </gitem>
  2100. <gitem>
  2101. <label>
  2102. <termdef id="dt-error" term="error"><term>error</term></termdef>
  2103. </label>
  2104. <def>
  2105. <p>
  2106. A violation of the rules of this specification; results are undefined.
  2107. Conforming software <termref def="dt-may"/> detect and report an
  2108. <term>error</term> and <termref def="dt-may"/> recover from it.
  2109. </p>
  2110. </def>
  2111. </gitem>
  2112. </glist>
  2113. </div2>
  2114.  
  2115. <div2 id="constraints-and-contributions">
  2116. <head>Constraints and Contributions</head>
  2117. <p>
  2118. This specification provides three different kinds of normative
  2119. statements about schema components, their representations in XML and
  2120. their contribution to the schema-validation of information items:
  2121. </p>
  2122. <glist>
  2123. <gitem>
  2124. <label>
  2125. <termdef id="dt-cos" term="Constraint on Schemas">
  2126. <term>Constraint on Schemas</term>
  2127. </termdef>
  2128. </label>
  2129. <def>
  2130. <p>
  2131. Constraints on the schema components themselves, i.e. conditions
  2132. components <termref def="dt-must"/> satisfy to be components at all.
  2133. Largely to be found in <specref ref="datatype-components"/>.
  2134. </p>
  2135. </def>
  2136. </gitem>
  2137. <gitem>
  2138. <label>
  2139. <termdef id="dt-src" term="Schema Representation Constraint">
  2140. <term>Schema Representation Constraint</term>
  2141. </termdef>
  2142. </label>
  2143. <def>
  2144. <p>
  2145. Constraints on the representation of schema components in XML.  Some but
  2146. not all of these are expressed in <specref ref="schema"/> and
  2147. <specref ref="dtd-for-datatypeDefs"/>.
  2148. </p>
  2149. </def>
  2150. </gitem>
  2151. <gitem>
  2152. <label>
  2153. <termdef id="dt-cvc" term="Validation Rule">
  2154. <term>Validation Rule</term>
  2155. </termdef>
  2156. </label>
  2157. <def>
  2158. <p>
  2159. Constraints expressed by schema components which information
  2160. items <termref def="dt-must"/> satisfy to be schema-valid.  Largely
  2161. to be found in <specref ref="datatype-components"/>.
  2162. </p>
  2163. </def>
  2164. </gitem>
  2165. </glist>
  2166. </div2>
  2167. </div1>
  2168. <div1 id="typesystem">
  2169. <head>Type System</head>
  2170. <p>
  2171. This section describes the conceptual framework behind the type system
  2172. defined in this specification.  The framework has been influenced by the
  2173. <bibref ref="ISO11404"/> standard on language-independent datatypes as
  2174. well as the datatypes for <bibref ref="SQL"/> and for programming
  2175. languages such as Java.
  2176. </p>
  2177. <p>
  2178. The datatypes discussed in this specification are computer
  2179. representations of well known abstract concepts such as
  2180. <emph>integer</emph> and <emph>date</emph>. It is not the place of this
  2181. specification to define these abstract concepts; many other publications
  2182. provide excellent definitions.
  2183. </p>
  2184. <div2 id="datatype">
  2185. <head>Datatype</head>
  2186. <p>
  2187. <termdef id="dt-datatype" term="datatype">In this specification,
  2188. a <term>datatype</term> is a 3-tuple, consisting of
  2189. a) a set of distinct values, called its <termref def="dt-value-space"/>,
  2190. b) a set of lexical representations, called its
  2191. <termref def="dt-lexical-space"/>, and c) a set of <termref def="dt-facet"/>s
  2192. that characterize properties of the <termref def="dt-value-space"/>,
  2193. individual values or lexical items.
  2194. </termdef>
  2195. </p>
  2196. </div2>
  2197. <div2 id="value-space">
  2198. <head>Value space</head>
  2199. <p>
  2200. <termdef id="dt-value-space" term="value space">A <term>value
  2201. space</term> is the set of values for a given datatype.
  2202. Each value in the <term>value space</term> of a datatype is denoted by
  2203. one or more literals in its <termref def="dt-lexical-space"/>.
  2204. </termdef>
  2205. </p>
  2206. <p>
  2207. The <termref def="dt-value-space"/> of a given datatype can
  2208. be defined in one of the following ways:
  2209. <ulist>
  2210. <item>
  2211. <p>
  2212. defined axiomatically from fundamental notions (intensional definition)
  2213. [see <termref def="dt-primitive"/>]
  2214. </p>
  2215. </item>
  2216. <item>
  2217. <p>
  2218. enumerated outright (extensional definition)
  2219. [see <termref def="dt-enumeration"/>]
  2220. </p>
  2221. </item>
  2222. <item>
  2223. <p>
  2224. defined by restricting the <termref def="dt-value-space"/> of
  2225. an already defined datatype to a particular subset with a given set
  2226. of properties [see <termref def="dt-derived"/>]
  2227. </p>
  2228. </item>
  2229. <item>
  2230. <p>
  2231. defined as a combination of values from one or more already defined
  2232. <termref def="dt-value-space"/>(s) by a specific construction procedure
  2233. [see <termref def="dt-list"/> and <termref def="dt-union"/>]
  2234. </p>
  2235. </item>
  2236. </ulist>
  2237. </p>
  2238. <p>
  2239. <termref def="dt-value-space"/>s have certain properties.  For example,
  2240. they always have the property of <termref def="dt-cardinality"/>,
  2241. some definition of <emph>equality</emph>
  2242. and might be <termref def="dt-ordered"/>, by which individual
  2243. values within the <termref def="dt-value-space"/> can be compared to
  2244. one another.  The properties of <termref def="dt-value-space"/>s that
  2245. are recognized by this specification are defined in
  2246. <specref ref="fundamental-facets"/>.
  2247. </p>
  2248. </div2>
  2249. <div2 id="lexical-space">
  2250. <head>Lexical space</head>
  2251. <p>
  2252. In addition to its <termref def="dt-value-space"/>, each datatype also
  2253. has a lexical space.
  2254. </p>
  2255. <p>
  2256. <termdef term="lexical space" id="dt-lexical-space">A
  2257. <term>lexical space</term> is the set of valid <emph>literals</emph>
  2258. for a datatype.
  2259. </termdef>
  2260. </p>
  2261. <p>
  2262. For example, "100" and "1.0E2" are two different literals from the
  2263. <termref def="dt-lexical-space"/> of <dtref ref="float"/> which both
  2264. denote the same value. The type system defined in this specification
  2265. provides a mechanism for schema designers to control the set of values
  2266. and the corresponding set of acceptable literals of those values for
  2267. a datatype.
  2268. </p>
  2269. <note>
  2270. <p>
  2271. The literals in the <termref def="dt-lexical-space"/>s defined in this specification
  2272. have the following characteristics:
  2273. </p>
  2274. <glist>
  2275. <gitem>
  2276. <label>
  2277. Interoperability:
  2278. </label>
  2279. <def>
  2280. <p>
  2281. The number of literals for each value has been kept small; for many
  2282. datatypes there is a one-to-one mapping between literals and values.
  2283. This makes it easy to exchange the values between different systems.
  2284. In many cases, conversion from locale-dependent representations will
  2285. be required on both the originator and the recipient side, both for
  2286. computer processing and for interaction with humans.
  2287. </p>
  2288. </def>
  2289. </gitem>
  2290. <gitem>
  2291. <label>
  2292. Basic readability:
  2293. </label>
  2294. <def>
  2295. <p>
  2296. Textual, rather than binary, literals are used.
  2297. This makes hand editing, debugging, and similar activities possible.
  2298. </p>
  2299. </def>
  2300. </gitem>
  2301. <gitem>
  2302. <label>
  2303. Ease of parsing and serializing:
  2304. </label>
  2305. <def>
  2306. <p>
  2307. Where possible, literals correspond to those found in common
  2308. programming languages and libraries.
  2309. </p>
  2310. </def>
  2311. </gitem>
  2312. </glist>
  2313. </note>
  2314. <div3 id="canonical-lexical-representation">
  2315. <head>Canonical Lexical Representation</head>
  2316. <p>
  2317. While the datatypes defined in this specification have, for the most part, 
  2318. a single lexical representation i.e. each value in the datatype's
  2319. <termref def="dt-value-space"/> is denoted by a single literal in its
  2320. <termref def="dt-lexical-space"/>, this is not always the case.  The
  2321. example in the previous section showed two literals for the datatype
  2322. <dtref ref="float"/> which denote the same value.  Similarly, there
  2323. <termref def="dt-may"/> be
  2324. several literals for one of the date or time datatypes that denote the
  2325. same value using different timezone indicators.
  2326. </p>
  2327. <p>
  2328. <termdef term="canonical lexical representation" id="dt-canonical-representation">A <term>canonical lexical representation</term>
  2329. is a set of literals from among the valid set of literals
  2330. for a datatype such that there is a one-to-one mapping between literals
  2331. in the <term>canonical lexical representation</term> and
  2332. values in the <termref def="dt-value-space"/>.
  2333. </termdef>
  2334. </p>
  2335. </div3>
  2336. </div2>
  2337. <div2 id="facets">
  2338. <head>Facets</head>
  2339. <p>
  2340. <termdef id="dt-facet" term="facet">A <term>facet</term> is a single
  2341. defining aspect of a <termref def="dt-value-space"/>.  Generally
  2342. speaking, each facet characterizes a <termref def="dt-value-space"/>
  2343. along independent axes or dimensions.</termdef>
  2344. </p>
  2345. <p>
  2346. The facets of a datatype serve to distinguish those aspects of
  2347. one datatype which <emph>differ</emph> from other datatypes.
  2348. Rather than being defined solely in terms of a prose description
  2349. the datatypes in this specification are defined in terms of
  2350. the <emph>synthesis</emph> of facet values which together determine the
  2351. <termref def="dt-value-space"/> and properties of the datatype.
  2352. </p>
  2353. <p>
  2354. Facets are of two types: <emph>fundamental</emph> facets that define
  2355. the datatype and <emph>non-fundamental</emph> or <emph>constraining
  2356. </emph> facets that constrain the permitted values of a datatype.
  2357. </p>
  2358. <div3 id="fundamental-facets">
  2359. <head>Fundamental facets</head>
  2360. <p>
  2361. <termdef id="dt-fundamental-facet" term="fundamental facet">
  2362. A <term>fundamental facet</term> is an abstract property which
  2363. serves to semantically characterize the values in a
  2364. <termref def="dt-value-space"/>.
  2365. </termdef>
  2366. </p>
  2367. <p>
  2368. All <term>fundamental facets</term> are fully described in
  2369. <specref ref='rf-fund-facets'/>.
  2370. </p>
  2371. </div3>
  2372.  
  2373. <div3 id="non-fundamental">
  2374. <head>Constraining or Non-fundamental facets</head>
  2375. <p>
  2376. <termdef id="dt-constraining-facet" term="constraining facet">A
  2377. <term>constraining facet</term> is an optional property that can be
  2378. applied to a datatype to constrain its <termref def="dt-value-space"/>.
  2379. </termdef>
  2380. </p>
  2381. <p>
  2382. Constraining the <termref def="dt-value-space"/> consequently constrains
  2383. the <termref def="dt-lexical-space"/>.  Adding
  2384. <termref def="dt-constraining-facet"/>s to a <termref def="dt-basetype"/>
  2385. is described in <specref ref="derivation-by-restriction"/>.
  2386. </p>
  2387. <p>
  2388. All <term>constraining facets</term> are fully described in
  2389. <specref ref='rf-facets'/>.
  2390. </p>
  2391.  
  2392. </div3>
  2393. </div2>
  2394.  
  2395. <div2 id="datatype-dichotomies">
  2396. <head>Datatype dichotomies</head>
  2397. <p>
  2398. It is useful to categorize the datatypes defined in this specification
  2399. along various dimensions, forming a set of characterization dichotomies.
  2400. </p>
  2401. <div3 id="atomic-vs-list">
  2402. <head>Atomic vs. list vs. union datatypes</head>
  2403. <p>
  2404. The first distinction to be made is that between
  2405. <termref def="dt-atomic"/>, <termref def="dt-list"/> and <termref def="dt-union"/>
  2406. datatypes.
  2407. </p>
  2408. <ulist>
  2409. <item>
  2410. <p>
  2411. <termdef id="dt-atomic" term="atomic"><term>Atomic</term> datatypes
  2412. are those having values which are regarded by this specification as
  2413. being indivisible.
  2414. </termdef>
  2415. </p>
  2416. </item>
  2417. <item>
  2418. <p>
  2419. <termdef id="dt-list" term="list"><term>List</term>
  2420. datatypes are those having values each of which consists of a
  2421. finite-length (possibly empty) sequence of values of an
  2422. <termref def="dt-atomic"/> datatype.
  2423. </termdef>
  2424. </p>
  2425. </item>
  2426. <item>
  2427. <p>
  2428. <termdef id="dt-union" term="union"><term>Union</term>
  2429. datatypes are those whose <termref def="dt-value-space"/>s and
  2430. <termref def="dt-lexical-space"/>s are the union of
  2431. the <termref def="dt-value-space"/>s and
  2432. <termref def="dt-lexical-space"/>s of one or more other datatypes.
  2433. </termdef>
  2434. </p>
  2435. </item>
  2436. </ulist>
  2437. <p>
  2438. For example, a single token which <termref def="dt-match"/>es
  2439. <xspecref href="&xmlspec;#NT-Nmtoken">Nmtoken</xspecref> from
  2440. <bibref ref="XML"/> could be the value of an <termref def="dt-atomic"/>
  2441. datatype (<dtref ref="NMTOKEN"/>); while a sequence of such tokens
  2442. could be the value of a <termref def="dt-list"/> datatype
  2443. (<dtref ref="NMTOKENS"/>).
  2444. </p>
  2445. <div4 id="atomic">
  2446. <head>Atomic datatypes</head>
  2447. <p>
  2448. <termref def="dt-atomic"/> datatypes can be either
  2449. <termref def="dt-primitive"/> or <termref def="dt-derived"/>.  The
  2450. <termref def="dt-value-space"/> of an <termref def="dt-atomic"/> datatype
  2451. is a set of "atomic" values, which for the purposes of this specification,
  2452. are not further decomposable.  The <termref def="dt-lexical-space"/> of
  2453. an <termref def="dt-atomic"/> datatype is a set of <emph>literals</emph>
  2454. whose internal structure is specific to the datatype in question.
  2455. </p>
  2456. </div4>
  2457. <div4 id="list-datatypes">
  2458. <head>List datatypes</head>
  2459. <!-- question: are lists ordered? answer should be NO...the sequence
  2460. within a single value is ordered, but the value space is a list type
  2461. is not ordered
  2462. -->
  2463. <p>
  2464. Several type systems (such as the one described in
  2465. <bibref ref="ISO11404"/>) treat <termref def="dt-list"/> datatypes as
  2466. special cases of the more general notions of aggregate or collection
  2467. datatypes.
  2468. </p>
  2469. <p>
  2470. <termref def="dt-list"/> datatypes are always <termref def="dt-derived"/>.
  2471. The <termref def="dt-value-space"/> of a <termref def="dt-list"/>
  2472. datatype is a set of finite-length sequences of <termref def="dt-atomic"/>
  2473. values. The <termref def="dt-lexical-space"/> of a
  2474. <termref def="dt-list"/> datatype is a set of literals whose internal
  2475. structure is a white space separated sequence of literals of the
  2476. <termref def="dt-atomic"/> datatype of the items in the
  2477. <termref def="dt-list"/>
  2478. (where whitespace <termref def="dt-match"/>es
  2479. <xspecref href="&xmlspec;#NT-S">S</xspecref> in <bibref ref="XML"/>).
  2480. </p>
  2481. <p>
  2482. <termdef id="dt-itemType" term="itemType">
  2483. The <termref def="dt-atomic"/> datatype that participates in the
  2484. definition of a <termref def="dt-list"/> datatype is known as the
  2485. <term>itemType</term> of that <termref def="dt-list"/> datatype.
  2486. </termdef>
  2487. </p>
  2488. <note role="example">
  2489. <eg><![CDATA[
  2490. <simpleType name='sizes'>
  2491.   <list itemType='decimal'/>
  2492. </simpleType>
  2493. ]]></eg>
  2494. <eg><![CDATA[
  2495. <cerealSizes xsi:type='sizes'> 8 10.5 12 </cerealSizes>
  2496. ]]></eg>
  2497. </note>
  2498. <p>
  2499. A <termref def="dt-list"/> datatype can be <termref def="dt-derived"/>
  2500. from an <termref def="dt-atomic"/> datatype whose
  2501. <termref def="dt-lexical-space"/> allows whitespace (such as <dtref ref='string'/>
  2502. or <dtref ref='anyURI'/>). In such a case, regardless of the input, list items
  2503. will be separated at whitespace boundaries.
  2504. </p>
  2505.  
  2506. <note role="example">
  2507. <eg><![CDATA[
  2508. <simpleType name='listOfString'>
  2509.   <list itemType='string'/>
  2510. </simpleType>
  2511. ]]></eg>
  2512. <eg>
  2513. <someElement xsi:type='listOfString'>
  2514. this is not list item 1
  2515. this is not list item 2
  2516. this is not list item 3
  2517. </someElement>
  2518. </eg>
  2519. <p>
  2520. In the above example, the value of the <emph>someElement</emph> element
  2521. is not a <termref def="dt-list"/> of <termref def="dt-length"/> 3;
  2522. rather, it is a <termref def="dt-list"/> of <termref def="dt-length"/>
  2523. 18.
  2524. </p>
  2525. </note>
  2526. <!--
  2527.      somehow need to get the <has-facets> concept for abstract lists
  2528.      into builtin.xsd, so that the following can be auto-generated
  2529.   -->
  2530. <p>
  2531. When a datatype is <termref def="dt-derived"/> from a
  2532. <termref def="dt-list"/> datatype, the following
  2533. <termref def="dt-constraining-facet"/>s apply:
  2534. </p>
  2535. <ulist>
  2536. <item><p><termref def="dt-length"/></p></item>
  2537. <item><p><termref def="dt-maxLength"/></p></item>
  2538. <item><p><termref def="dt-minLength"/></p></item>
  2539. <item><p><termref def="dt-enumeration"/></p></item>
  2540. <item><p><termref def="dt-pattern"/></p></item>
  2541. <item><p><termref def="dt-whiteSpace"/></p></item>
  2542. </ulist>
  2543. <p>
  2544. For each of <termref def='dt-length'/>, <termref def='dt-maxLength'/>
  2545. and <termref def='dt-minLength'/>, the <emph>unit of length</emph> is
  2546. measured in number of list items.  The value of <termref def='dt-whiteSpace'/>
  2547. is fixed to the value <emph>collapse</emph>.
  2548. </p>
  2549. <p>
  2550. The <dtref ref="canonical-lexical-representation"/> for the
  2551. <termref def="dt-list"/> datatype is defined as the lexical form in which
  2552. each item in the <termref def="dt-list"/> has the canonical lexical
  2553. representation of its  <termref def="dt-itemType"/>.
  2554. </p>
  2555. </div4>
  2556. <div4 id="union-datatypes">
  2557. <head>Union datatypes</head>
  2558. <p>
  2559. The <termref def="dt-value-space"/> and <termref def="dt-lexical-space"/>
  2560. of a <termref def="dt-union"/> datatype are the union of the
  2561. <termref def="dt-value-space"/>s and <termref def="dt-lexical-space"/>s of
  2562. its <termref def="dt-memberTypes"/>.
  2563. <termref def="dt-union"/> datatypes are always <termref def="dt-derived"/>.
  2564. Currently, there are no <termref def="dt-built-in"/> <termref def="dt-union"/>
  2565. datatypes.
  2566. </p>
  2567. <note role="example">
  2568. <p>
  2569. A prototypical example of a <termref def="dt-union"/> type is the
  2570. <xspecref href="&xsdl;#p-max_occurs">maxOccurs attribute</xspecref> on the
  2571. <xspecref href="&xsdl;#element-element">element element</xspecref>
  2572. in XML Schema itself: it is a union of nonNegativeInteger
  2573. and an enumeration with the single member, the string "unbounded", as shown below.
  2574. </p>
  2575. <eg><![CDATA[
  2576.   <attributeGroup name="occurs">
  2577.     <attribute name="minOccurs" type="nonNegativeInteger"
  2578.         default="1"/>
  2579.     <attribute name="maxOccurs">
  2580.       <simpleType>
  2581.         <union>
  2582.           <simpleType>
  2583.             <restriction base='nonNegativeInteger'/>
  2584.           </simpleType>
  2585.           <simpleType>
  2586.             <restriction base='string'>
  2587.               <enumeration value='unbounded'/>
  2588.             </restriction>
  2589.           </simpleType>
  2590.         </union>
  2591.       </simpleType>
  2592.     </attribute>
  2593.   </attributeGroup>
  2594. ]]></eg>
  2595. </note>
  2596. <p>
  2597. Any number (greater than 1) of <termref def="dt-atomic"/> or <termref def="dt-list"/>
  2598. <termref def="dt-datatype"/>s can participate in a <termref def="dt-union"/> type.  
  2599. </p>
  2600. <p>
  2601. <termdef id="dt-memberTypes" term="memberTypes">
  2602. The datatypes that participate in the
  2603. definition of a <termref def="dt-union"/> datatype are known as the
  2604. <term>memberTypes</term> of that <termref def="dt-union"/> datatype.
  2605. </termdef>
  2606. </p>
  2607. <p>
  2608. The order in which the <termref def="dt-memberTypes"/> are specified in the
  2609. definition (that is, the order of the <simpleType> children of the <union>
  2610. element, or the order of the <dtref ref="QName"/>s in the <emph>memberTypes</emph>
  2611. attribute) is significant.
  2612. During validation, an element or attribute's value is validated against the
  2613. <termref def="dt-memberTypes"/> in the order in which they appear in the
  2614. definition until a match is found.  The evaluation order can be overridden
  2615. with the use of <xspecref href="&xsdl;#xsi_type">xsi:type</xspecref>.
  2616. </p>
  2617. <note>
  2618. <p>
  2619. For example, given the definition below, the first instance of the <size> element
  2620. validates correctly as an <specref ref="integer"/>, the second and third as
  2621. <specref ref="string"/>.
  2622. </p>
  2623. <eg><![CDATA[
  2624.   <xsd:element name='size'>
  2625.     <xsd:simpleType>
  2626.       <xsd:union>
  2627.         <xsd:simpleType>
  2628.           <xsd:restriction base='integer'/>
  2629.         </xsd:simpleType>
  2630.         <xsd:simpleType>
  2631.           <xsd:restriction base='string'/>
  2632.         </xsd:simpleType>
  2633.       </xsd:union>
  2634.     </xsd:simpleType>
  2635.   </xsd:element>
  2636. ]]></eg>
  2637. <eg><![CDATA[
  2638.   <size>1</size>
  2639.   <size>large</size>
  2640.   <size xsi:type='xsd:string'>1</size>
  2641. ]]></eg></note>
  2642. <p> The <dtref ref="canonical-lexical-representation"/> for a
  2643. <termref def="dt-union"/> datatype is defined as the lexical form in which
  2644. the values have the canonical lexical representation
  2645. of the appropriate  <termref def="dt-memberTypes"/>.</p>
  2646. <note>
  2647. <p>
  2648. A datatype which is <termref def="dt-atomic"/> in this specification
  2649. need not be an "atomic" datatype in any programming language used to
  2650. implement this specification.  Likewise, a datatype which is a
  2651. <termref def="dt-list"/> in this specification need not be a "list"
  2652. datatype in any programming language used to implement this specification.
  2653. Furthermore, a datatype which is a <termref def="dt-union"/> in this
  2654. specification need not be a "union" datatype in any programming
  2655. language used to implement this specification.
  2656. </p>
  2657. </note>
  2658. </div4>
  2659. </div3>
  2660. <div3 id="primitive-vs-derived">
  2661. <head>Primitive vs. derived datatypes</head>
  2662. <p>
  2663. Next, we distinguish between <termref def="dt-primitive"/> and 
  2664. <termref def="dt-derived"/> datatypes.
  2665. </p>
  2666. <ulist>
  2667. <item>
  2668. <p>
  2669. <termdef id="dt-primitive" term="primitive"><term>Primitive</term>
  2670. datatypes are those that are not defined in terms of other datatypes;
  2671. they exist <emph>ab initio</emph>.
  2672. </termdef>
  2673. </p>
  2674. </item>
  2675. <item>
  2676. <p>
  2677. <termdef id="dt-derived" term="derived"><term>Derived</term>
  2678. datatypes are those that are defined in terms of other datatypes.
  2679. </termdef>
  2680. </p>
  2681. </item>
  2682. </ulist>
  2683. <p>
  2684. For example, in this specification, <dtref ref="float"/> is a well-defined
  2685. mathematical
  2686. <!-- find example other than float -->
  2687. concept that cannot be defined in terms of other datatypes, while
  2688. a <dtref ref="integer"/> is a special case of the more general datatype
  2689. <dtref ref='decimal'/>.
  2690. </p>
  2691. <p>
  2692. <termdef id='dt-anySimpleType' term='anySimpleType' role='local'>
  2693. There exists a conceptual datatype, whose name is <term>anySimpleType</term>,
  2694. that is the simple version of the
  2695. <xtermref href="&xsdl;#key-urType">ur-type definition</xtermref> from
  2696. <bibref ref='structural-schemas'/>.  <term>anySimpleType</term> can be
  2697. considered as the <termref def='dt-basetype'/> of all <termref def='dt-primitive'/>
  2698. types.  The <termref def='dt-value-space'/> of <term>anySimpleType</term>
  2699. can be considered to be the <termref def='dt-union'/> of the
  2700. <termref def='dt-value-space'/>s of all <termref def='dt-primitive'/> datatypes.
  2701. </termdef>
  2702. </p>
  2703. <p>
  2704. The datatypes defined by this specification fall into both
  2705. the <termref def="dt-primitive"/> and <termref def="dt-derived"/>
  2706. categories.  It is felt that a judiciously chosen set of
  2707. <termref def="dt-primitive"/> datatypes will serve the widest
  2708. possible audience by providing a set of convenient datatypes that
  2709. can be used as is, as well as providing a rich enough base from
  2710. which the variety of datatypes needed by schema designers can be
  2711. <termref def="dt-derived"/>.
  2712. </p>
  2713. <p>
  2714. In the example above, <dtref ref="integer"/> is <termref def="dt-derived"/>
  2715. from <dtref ref='decimal'/>.
  2716. </p>
  2717. <note>
  2718. <p>
  2719. A datatype which is <termref def="dt-primitive"/> in this specification
  2720. need not be a "primitive" datatype in any programming language used to
  2721. implement this specification.  Likewise, a datatype which is
  2722. <termref def="dt-derived"/> in this specification need not be a
  2723. "derived" datatype in any programming language used to implement
  2724. this specification.
  2725. </p>
  2726. </note>
  2727. <p>
  2728. As described in more detail in <specref ref="xr-defn"/>,
  2729. each <termref def="dt-user-derived"/> datatype <termref def="dt-must"/>
  2730. be defined in terms of another datatype in one of three ways: 1) by assigning
  2731. <termref def="dt-constraining-facet"/>s which serve to <emph>restrict</emph> the
  2732. <termref def="dt-value-space"/> of the <termref def="dt-user-derived"/>
  2733. datatype to a subset of that of the <termref def="dt-basetype"/>; 2) by creating
  2734. a <termref def="dt-list"/> datatype whose <termref def="dt-value-space"/>
  2735. consists of finite-length sequences of values of its
  2736. <termref def="dt-itemType"/>; or 3) by creating a <termref def="dt-union"/>
  2737. datatype whose <termref def="dt-value-space"/> consists of the union of the
  2738. <termref def="dt-value-space"/> its <termref def="dt-memberTypes"/>.
  2739. </p>
  2740.  
  2741. <div4 id='restriction'>
  2742. <head>Derived by restriction</head>
  2743. <p>
  2744. <!-- add the exception for pattern -->
  2745. <termdef id='dt-restriction' term='restriction'>A datatype is said to be
  2746. <termref def="dt-derived"/> by <term>restriction</term> from another datatype
  2747. when values for zero or more <termref def="dt-constraining-facet"/>s are specified
  2748. that serve to constrain its <termref def='dt-value-space'/> and/or its
  2749. <termref def='dt-lexical-space'/> to a subset of those of its
  2750. <termref def='dt-basetype'/>.
  2751. </termdef>
  2752. </p>
  2753. <p>
  2754. <termdef id="dt-basetype" term="base type">Every
  2755. datatype that is <termref def="dt-derived"/> by <term>restriction</term>
  2756. is defined in terms of an existing datatype, referred to as its
  2757. <term>base type</term>. <term>base type</term>s can be either
  2758. <termref def="dt-primitive"/> or <termref def="dt-derived"/>.
  2759. </termdef>
  2760. </p>
  2761. </div4>
  2762. <div4 id='list'>
  2763. <head>Derived by list</head>
  2764. <p>
  2765. A <termref def='dt-list'/> datatype can be <termref def="dt-derived"/>
  2766. from another datatype (its <termref def='dt-itemType'/>) by creating
  2767. a <termref def='dt-value-space'/> that consists of a finite-length sequence
  2768. of values of its <termref def='dt-itemType'/>.
  2769. </p>
  2770. </div4>
  2771. <div4 id='union'>
  2772. <head>Derived by union</head>
  2773. <p>
  2774. One datatype can be <termref def="dt-derived"/> from one or more
  2775. datatypes by <termref def='dt-union'/>ing their <termref def="dt-value-space"/>s
  2776. and, consequently, their <termref def="dt-lexical-space"/>s.
  2777. </p>
  2778. </div4>
  2779. </div3>
  2780. <div3 id="built-in-vs-user-derived">
  2781. <head>Built-in vs. user-derived datatypes</head>
  2782. <ulist>
  2783. <item>
  2784. <p>
  2785. <termdef id="dt-built-in" term="built-in"><term>Built-in</term>
  2786. datatypes are those which are defined in this specification,
  2787. and can be either <termref def="dt-primitive"/> or
  2788. <termref def="dt-derived"/>;
  2789. </termdef>
  2790. </p>
  2791. </item>
  2792. <item>
  2793. <p>
  2794. <termdef id="dt-user-derived" term="user-derived">
  2795. <term>User-derived</term> datatypes are those <termref def="dt-derived"/>
  2796. datatypes that are defined by individual schema designers.
  2797. </termdef>
  2798. </p>
  2799. </item>
  2800. </ulist>
  2801. <p>
  2802. Conceptually there is no difference between the
  2803. <termref def="dt-built-in"/> <termref def="dt-derived"/> datatypes
  2804. included in this specification and the <termref def="dt-user-derived"/>
  2805. datatypes which will be created by individual schema designers.
  2806. The <termref def="dt-built-in"/> <termref def="dt-derived"/> datatypes
  2807. are those which are believed to be so common that if they were not
  2808. defined in this specification many schema designers would end up
  2809. "reinventing" them.  Furthermore, including these
  2810. <termref def="dt-derived"/> datatypes in this specification serves to
  2811. demonstrate the mechanics and utility of the datatype generation
  2812. facilities of this specification.
  2813. </p>
  2814. <note>
  2815. <p>
  2816. A datatype which is <termref def="dt-built-in"/> in this specification
  2817. need not be a "built-in" datatype in any programming language used
  2818. to implement this specification.  Likewise, a datatype which is
  2819. <termref def="dt-user-derived"/> in this specification need not
  2820. be a "user-derived" datatype in any programming language used to
  2821. implement this specification.
  2822. </p>
  2823. </note>
  2824. </div3>
  2825. </div2>
  2826. </div1>
  2827. <div1 id="built-in-datatypes">
  2828. <head>Built-in datatypes</head>
  2829. <graphic source="type-hierarchy.gif" alt="Diagram of built-in type hierarchy" map="typeImage"/>
  2830. <!--
  2831.     thanx to Asir S Vedamuthu for creating this image map
  2832.   -->
  2833.   <imagemap source="image-map.html" id="typeImage"/>
  2834.  
  2835. <p>
  2836.       Each built-in datatype in this specification (both
  2837.       <termref def='dt-primitive'/> and
  2838.       <termref def='dt-derived'/>) can be uniquely addressed via a
  2839.       URI Reference constructed as follows:
  2840. </p>
  2841. <olist>
  2842. <item><p>the base URI is the URI of the XML Schema namespace</p></item>
  2843. <item><p>the fragment identifier is the name of the datatype</p></item>
  2844. </olist>
  2845. <p>        
  2846.       For example, to address the <dtref ref='int'/> datatype, the URI is:
  2847. </p>
  2848. <ulist>
  2849.       <item><p><code>http://www.w3.org/2001/XMLSchema#int</code></p></item>
  2850. </ulist>
  2851. <p>
  2852.       Additionally, each facet definition element can be uniquely
  2853.       addressed via a URI constructed as follows:
  2854. </p>
  2855. <olist>
  2856. <item><p>the base URI is the URI of the XML Schema namespace</p></item>
  2857. <item><p>the fragment identifier is the name of the facet</p></item>
  2858. </olist>
  2859. <p>
  2860.       For example, to address the maxInclusive facet, the URI is:
  2861. </p>
  2862. <ulist>
  2863.       <item><p><code>http://www.w3.org/2001/XMLSchema#maxInclusive</code></p></item>
  2864. </ulist>
  2865. <p>
  2866.       Additionally, each facet usage in a built-in datatype definition
  2867.       can be uniquely addressed via a URI constructed as follows:
  2868. </p>
  2869. <olist>
  2870. <item><p>the base URI is the URI of the XML Schema namespace</p></item>
  2871. <item><p>the fragment identifier is the name of the datatype, followed
  2872.     by a period (".") followed by the name of the facet</p></item>
  2873. </olist>
  2874. <p>        
  2875.       For example, to address the usage of the maxInclusive facet in
  2876.       the definition of int, the URI is:
  2877. </p>
  2878. <ulist>
  2879.       <item><p><code>http://www.w3.org/2001/XMLSchema#int.maxInclusive</code></p></item>
  2880. </ulist>
  2881. <div2 id="namespaces">
  2882. <head>Namespace considerations</head>
  2883. <p>
  2884. The <termref def="dt-built-in"/> datatypes defined by this specification
  2885. are designed to be used with the &schema-language; as well as other
  2886. XML specifications. 
  2887. To facilitate usage within the &schema-language;, the <termref def="dt-built-in"/>
  2888. datatypes in this specification have the namespace name:
  2889. </p>
  2890. <ulist>
  2891. <item><p>http://www.w3.org/2001/XMLSchema</p></item>
  2892. </ulist>
  2893. <p>
  2894. To facilitate usage in specifications other than the &schema-language;,
  2895. such as those that do not want to know anything about aspects of the
  2896. &schema-language; other than the datatypes, each <termref def="dt-built-in"/>
  2897. datatype is also defined in the namespace whose URI is:
  2898. </p>
  2899. <ulist>
  2900. <item><p>http://www.w3.org/2001/XMLSchema-datatypes</p></item>
  2901. </ulist>
  2902. <p>
  2903. This applies to both
  2904. <termref def="dt-built-in"/> <termref def="dt-primitive"/> and
  2905. <termref def="dt-built-in"/> <termref def="dt-derived"/> datatypes.
  2906. </p>
  2907. <p>
  2908. Each <termref def="dt-user-derived"/> datatype is also associated with a
  2909. unique namespace.  However, <termref def="dt-user-derived"/> datatypes
  2910. do not come from the namespace defined by this specification; rather,
  2911. they come from the namespace of the schema in which they are defined
  2912. (see <xspecref href="&xsdl;#declare-schema">XML Representation of
  2913. Schemas</xspecref> in <bibref ref="structural-schemas"/>).
  2914. </p>
  2915. </div2>
  2916. <div2 id="built-in-primitive-datatypes">
  2917. <head>Primitive datatypes</head>
  2918. <p>
  2919. The <termref def="dt-primitive"/> datatypes defined by this specification
  2920. are described below.  For each datatype, the
  2921. <termref def="dt-value-space"/> and <termref def="dt-lexical-space"/>
  2922. are defined, <termref def="dt-constraining-facet"/>s which apply
  2923. to the datatype are listed and any datatypes <termref def="dt-derived"/>
  2924. from this datatype are specified.
  2925. </p>
  2926. <p>
  2927. <termref def="dt-primitive"/> datatypes can only be added by revisions
  2928. to this specification.
  2929. </p>
  2930. <div3 id="string">
  2931. <head>string</head>
  2932. <p>
  2933. <termdef id="dt-string" term="string" role='local'>The <term>string</term> datatype
  2934. represents character strings in XML.  The <termref def="dt-value-space"/>
  2935. of <term>string</term> is the set of finite-length sequences of
  2936. <xtermref href="&xmlspec;#dt-character">character</xtermref>s (as defined in
  2937. <bibref ref="XML"/>) that <termref def="dt-match"/> the
  2938. <xnt href="&xmlspec;#NT-Char">Char</xnt> production from <bibref ref="XML"/>.
  2939. A <xtermref href="&xmlspec;#dt-character">character</xtermref> is an atomic unit of
  2940. communication; it is not further specified except to note that every
  2941. <xtermref href="&xmlspec;#dt-character">character</xtermref> has a corresponding
  2942. Universal Character Set code point, which is an integer.
  2943. </termdef>
  2944. </p>
  2945. <note>
  2946. <p>
  2947. Many human languages have writing systems that require
  2948. child elements for control of aspects such as bidirectional formating or
  2949. ruby annotation (see <bibref ref='ruby'/> and Section 8.2.4
  2950. <xspecref href='&html4;struct/dirlang.html#h-8.2.4'>Overriding the
  2951. bidirectional algorithm: the BDO element</xspecref> of <bibref ref='html4'/>).
  2952. Thus, <term>string</term>, as a simple type that can contain only
  2953. characters but not child elements, is often not suitable for representing text.
  2954. In such situations, a complex type that allows mixed content should be considered.
  2955. For more information, see Section 5.5
  2956. <xspecref href='http://www.w3.org/TR/2001/REC-xmlschema-0-20010502/#textType'>Any Element, Any Attribute</xspecref>
  2957. of <bibref ref='schema-primer'/>.
  2958. </p>
  2959. </note>
  2960. <note>
  2961. <p>
  2962. As noted in <compref ref="dc-ordered"/>, the fact that this specification does
  2963. not specify an <termref def="dt-order-relation"/> for <termref def="dt-string"/>
  2964. does not preclude other applications from treating strings as being ordered.
  2965. </p>
  2966. </note>
  2967. <div4 id="string-facets">
  2968. <head>Constraining facets</head>
  2969. <facets/>
  2970. </div4>
  2971. <div4 id="string-derived-types">
  2972. <head>Derived datatypes</head>
  2973. <subtypes/>
  2974. </div4>
  2975. </div3>
  2976. <div3 id="boolean">
  2977. <head>boolean</head>
  2978. <p>
  2979. <termdef id="dt-boolean" term="boolean" role='local'><term>boolean</term> has the
  2980. <termref def="dt-value-space"/> required to support the mathematical
  2981. concept of binary-valued logic: {true, false}.</termdef>
  2982. </p>
  2983. <div4 id="boolean-lexical-representation">
  2984. <head>Lexical representation</head>
  2985. <p>
  2986. An instance of a datatype that is defined as <termref def="dt-boolean"/>
  2987. can have the following legal literals {true, false, 1, 0}.
  2988. </p>
  2989. </div4>
  2990. <div4 id="boolean-canonical-representation">
  2991. <head>Canonical representation</head>
  2992. <p>
  2993. The canonical representation for <term>boolean</term> is the set of
  2994. literals {true, false}.
  2995. </p>
  2996. </div4>
  2997. <div4 id="boolean-facets">
  2998. <head>Constraining facets</head>
  2999. <facets/>
  3000. </div4>
  3001. </div3>
  3002. <div3 id='decimal'>
  3003. <head>decimal</head>
  3004. <p>
  3005. <termdef id="dt-decimal" term="decimal" role='local'><term>decimal</term>
  3006. represents arbitrary precision decimal numbers.
  3007. The <termref def="dt-value-space"/> of <term>decimal</term>
  3008. is the set of the values <emph role="eq">i × 10^-n</emph>,
  3009. where <emph role="eq">i</emph> and <emph role="eq">n</emph> are integers
  3010. such that <emph role="eq">n >= 0</emph>.
  3011. The <termref def="dt-order-relation"/> on <term>decimal</term>
  3012. is: <emph role="eq">x < y iff y - x</emph> is positive.
  3013. </termdef>
  3014. </p>
  3015. <p>
  3016. <termdef id="dt-decimal-with-totalDigits" term="decimal-with-totalDigits" role='local'>
  3017. The <termref def="dt-value-space"/> of types derived from <term>decimal</term>
  3018. with a value for <termref def="dt-totalDigits"/> of <emph role="eq">p</emph>
  3019. is the set of values <emph role="eq">i × 10^-n</emph>, where
  3020. <emph role="eq">n</emph> and <emph role="eq">i</emph> are integers such that
  3021. <emph role="eq">p >= n >= 0</emph> and the number of significant decimal digits
  3022. in <emph role="eq">i</emph> is less than or equal to <emph role="eq">p</emph>.
  3023. </termdef>
  3024. </p>
  3025. <p>
  3026. <termdef id="dt-decimal-with-fractionDigits" term="decimal-with-fractionDigits" role='local'>
  3027. The <termref def="dt-value-space"/> of types derived from <term>decimal</term>
  3028. with a value for <termref def="dt-fractionDigits"/> of <emph role="eq">s</emph>
  3029. is the set of values <emph role="eq">i × 10^-n</emph>, where
  3030. <emph role="eq">i</emph> and <emph role="eq">n</emph> are integers such
  3031. that <emph role="eq">0 <= n <= s</emph>.
  3032. </termdef>
  3033. </p>
  3034. <note>
  3035. <p>
  3036. All <termref def="dt-minimally-conforming"/> processors <termref def="dt-must"/>
  3037. support decimal numbers with a minimum of 18 decimal digits (i.e., with a
  3038. <termref def="dt-totalDigits"/> of 18).  However,
  3039. <termref def="dt-minimally-conforming"/> processors <termref def="dt-may"/>
  3040. set an application-defined limit on the maximum number of decimal digits
  3041. they are prepared to support, in which case that application-defined
  3042. maximum number <termref def="dt-must"/> be clearly documented.
  3043. </p>
  3044. </note>
  3045. <div4 id="decimal-lexical-representation">
  3046. <head>Lexical representation</head>
  3047. <p>
  3048. <term>decimal</term> has a lexical representation
  3049. consisting of a finite-length sequence of decimal digits (#x30-#x39) separated
  3050. by a period as a decimal indicator.  If <termref def='dt-totalDigits'/> is
  3051. specified, the number of digits must be less than or equal to
  3052. <termref def='dt-totalDigits'/>.
  3053. If <termref def='dt-fractionDigits'/> is specified, the
  3054. number of digits following the decimal point must be less than or equal to
  3055. the <termref def='dt-fractionDigits'/>.  An optional leading sign is allowed.
  3056. If the sign is omitted, "+" is assumed.  Leading and trailing zeroes are optional.
  3057. If the fractional part is zero, the period and following zero(es) can
  3058. be omitted.
  3059. For example: <code>-1.23, 12678967.543233, +100000.00, 210</code>.
  3060. </p>
  3061. </div4>
  3062. <div4 id="decimal-canonical-representation">
  3063. <head>Canonical representation</head>
  3064. <p>
  3065. The canonical representation for <term>decimal</term> is defined by
  3066. prohibiting certain options from the
  3067. <specref ref="decimal-lexical-representation"/>.  Specifically, the preceding
  3068. optional "+" sign is prohibited.  The decimal point is required. Leading and 
  3069. trailing zeroes are prohibited subject to the following: there must be at least
  3070. one digit to the right and to the left of the decimal point which may be a zero.
  3071. </p>
  3072. </div4>
  3073. <div4 id="decimal-facets">
  3074. <head>Constraining facets</head>
  3075. <facets/>
  3076. </div4>
  3077. <div4 id="decimal-derived-types">
  3078. <head>Derived datatypes</head>
  3079. <subtypes/>
  3080. </div4>
  3081. </div3>
  3082.  
  3083. <div3 id="float">
  3084. <head>float</head>
  3085. <p>
  3086. <termdef id="dt-float" term="float" role='local'><term>float</term> corresponds
  3087. to the IEEE single-precision 32-bit floating point type
  3088. <bibref ref="ieee754"/>.  The basic <termref def="dt-value-space"/> of
  3089. <term>float</term> consists of the values
  3090. <emph role="eq">m × 2^e</emph>, where <emph role="eq">m</emph>
  3091. is an integer whose absolute value is less than
  3092. <emph role="eq">2^24</emph>, and <emph role="eq">e</emph> is an integer
  3093. between -149 and 104, inclusive.  In addition to the basic
  3094. <termref def="dt-value-space"/> described above, the
  3095. <termref def="dt-value-space"/> of <term>float</term> also contains the
  3096. following <emph>special values</emph>: positive and negative zero,
  3097. positive and negative infinity and not-a-number.
  3098. The <termref def="dt-order-relation"/> on <term>float</term>
  3099. is: <emph role="eq">x < y iff y - x</emph> is positive.
  3100. Positive zero is greater than negative zero. Not-a-number equals itself and is
  3101. greater than all float values including positive infinity.
  3102. </termdef>
  3103. </p>
  3104. <p>
  3105. A literal in the <termref def="dt-lexical-space"/> representing a
  3106. decimal number <emph role="eq">d</emph> maps to the normalized value
  3107. in the <termref def="dt-value-space"/> of <term>float</term> that is
  3108. closest to <emph role="eq">d</emph> in the sense defined by
  3109. <bibref ref='clinger1990'/>; if <emph role="eq">d</emph> is
  3110. exactly halfway between two such values then the even value is chosen.
  3111. </p>
  3112. <div4 id="float-lexical-representation">
  3113. <head>Lexical representation</head>
  3114. <p>
  3115. <term>float</term> values have a lexical representation
  3116. consisting of a mantissa followed, optionally, by the character
  3117. "E" or "e", followed by an exponent.  The exponent <termref def="dt-must"/>
  3118. be an <dtref ref="integer"/>. The mantissa must be a  <dtref ref='decimal'/> number. The representations
  3119. for exponent and mantissa must follow the lexical rules for
  3120. <dtref ref="integer"/> and <dtref ref='decimal'/>.  If the "E" or "e" and
  3121. the following exponent are omitted, an exponent value of 0 is assumed.
  3122. </p>
  3123. <p>
  3124. The <emph>special values</emph> positive and negative zero, positive
  3125. and negative infinity and not-a-number have lexical representations <code>0</code>,
  3126. <code>-0</code>, <code>INF</code>, <code>-INF</code> and
  3127. <code>NaN</code>, respectively.
  3128. </p>
  3129. <p>
  3130. For example, <code>-1E4, 1267.43233E12, 12.78e-2, 12 and INF</code>
  3131. are all legal literals for <term>float</term>.
  3132. </p>
  3133. </div4>
  3134. <div4 id="float-canonical-representation">
  3135. <head>Canonical representation</head>
  3136. <p>
  3137. The canonical representation for <term>float</term> is defined by
  3138. prohibiting certain options from the
  3139. <specref ref="float-lexical-representation"/>.  Specifically, the exponent 
  3140. must be indicated by "E".  Leading zeroes and the preceding optional "+" sign
  3141. are prohibited in the exponent.
  3142. For the mantissa, the preceding optional "+" sign is prohibited 
  3143. and the decimal point is required.  
  3144. For the exponent, the preceding optional "+" sign is prohibited.
  3145. Leading and trailing zeroes are prohibited subject to the following:
  3146. number representations must
  3147. be normalized such that there is a single
  3148. digit to the left of the decimal point and at least a single digit to the 
  3149. right of the decimal point. 
  3150. </p>
  3151. </div4>
  3152. <div4 id="float-facets">
  3153. <head>Constraining facets</head>
  3154. <facets/>
  3155. </div4>
  3156. </div3>
  3157. <div3 id="double">
  3158. <head>double</head>
  3159. <p>
  3160. <termdef id="dt-double" term="double" role='local'>The <term>double</term>
  3161. datatype corresponds to IEEE double-precision 64-bit floating point
  3162. type <bibref ref="ieee754"/>.  The basic <termref def="dt-value-space"/>
  3163. of <term>double</term> consists of the values
  3164. <emph role="eq">m × 2^e</emph>, where <emph role="eq">m</emph>
  3165. is an integer whose absolute value is less than
  3166. <emph role="eq">2^53</emph>, and <emph role="eq">e</emph> is an
  3167. integer between -1075 and 970, inclusive.  In addition to the basic
  3168. <termref def="dt-value-space"/> described above, the
  3169. <termref def="dt-value-space"/> of <term>double</term> also contains
  3170. the following <emph>special values</emph>: positive and negative zero,
  3171. positive and negative infinity and not-a-number.
  3172. The <termref def="dt-order-relation"/> on <term>double</term>
  3173. is: <emph role="eq">x < y iff y - x</emph> is positive.
  3174. Positive zero is greater than negative zero. Not-a-number equals itself and is
  3175. greater than all double values including positive infinity.
  3176. </termdef>
  3177. </p>
  3178. <p>
  3179. A literal in the <termref def="dt-lexical-space"/> representing a
  3180. decimal number <emph role="eq">d</emph> maps to the normalized value
  3181. in the <termref def="dt-value-space"/> of <term>double</term> that is
  3182. closest to <emph role="eq">d</emph>; if <emph role="eq">d</emph> is
  3183. exactly halfway between two such values then the even value is chosen.
  3184. This is the <emph>best approximation</emph> of <emph role="eq">d</emph>
  3185. (<bibref ref="clinger1990"/>, <bibref ref="gay1990"/>), which is more
  3186. accurate than the mapping required by <bibref ref="ieee754"/>.
  3187. </p>
  3188. <div4 id="double-lexical-representation">
  3189. <head>Lexical representation</head>
  3190. <p>
  3191. <term>double</term> values have a lexical representation
  3192. consisting of a mantissa followed, optionally, by the character "E" or
  3193. "e", followed by an exponent.  The exponent <termref def="dt-must"/> be
  3194. an integer.  The mantissa must be a decimal number. The representations
  3195. for exponent and mantissa must follow the lexical rules for
  3196. <dtref ref="integer"/> and <dtref ref='decimal'/>.  If the "E" or "e"
  3197. and the following exponent are omitted, an exponent value of 0 is assumed.
  3198. </p>
  3199. <p>
  3200. The <emph>special values</emph> positive and negative zero, positive
  3201. and negative infinity and not-a-number have lexical representations <code>0</code>,
  3202. <code>-0</code>, <code>INF</code>, <code>-INF</code> and
  3203. <code>NaN</code>, respectively.
  3204. </p>
  3205. <p>
  3206. For example, <code>-1E4, 1267.43233E12, 12.78e-2, 12 and INF</code>
  3207. are all legal literals for <term>double</term>.
  3208. </p>
  3209. </div4>
  3210. <div4 id="double-canonical-representation">
  3211. <head>Canonical representation</head>
  3212. <p>
  3213. The canonical representation for <term>double</term> is defined by
  3214. prohibiting certain options from the
  3215. <specref ref="double-lexical-representation"/>.  Specifically, the exponent 
  3216. must be indicated by "E".  Leading zeroes and the preceding optional "+" sign
  3217. are prohibited in the exponent.
  3218. For the mantissa, the preceding optional "+" sign is prohibited 
  3219. and the decimal point is required.  
  3220. For the exponent, the preceding optional "+" sign is prohibited.
  3221. Leading and trailing zeroes are prohibited subject to the following:
  3222. number representations must
  3223. be normalized such that there is a single
  3224. digit to the left of the decimal point and at least a single digit to the 
  3225. right of the decimal point. 
  3226. </p>
  3227. </div4>
  3228. <div4 id="double-facets">
  3229. <head>Constraining facets</head>
  3230. <facets/>
  3231. </div4>
  3232. </div3>
  3233.  
  3234. <div3 id="duration">
  3235. <head>duration</head>
  3236. <p>
  3237. <termdef id="dt-duration" term="duration" role='local'>
  3238. <term>duration</term> represents a duration of time.
  3239. The <termref def="dt-value-space"/> of <term>duration</term> is 
  3240. a six-dimensional space where the coordinates
  3241. designate the Gregorian year, month, day, hour, minute, and second components defined in
  3242. § 5.5.3.2 of <bibref ref="ISO8601"/>,
  3243. respectively.  These components are ordered
  3244. in their significance by their order of appearance i.e. as year, month, day,
  3245. hour, minute, and second.
  3246. </termdef></p>
  3247.  
  3248. <div4 id="duration-lexical-repr">
  3249. <head>Lexical representation</head>
  3250. <p>
  3251. The lexical representation for <term>duration</term> is the
  3252. <bibref ref="ISO8601"/> extended format P<emph>n</emph>Y<emph>n</emph>
  3253. M<emph>n</emph>DT<emph>n</emph>H <emph>n</emph>M<emph>n</emph>S, where
  3254. <emph>n</emph>Y represents the number of years, <emph>n</emph>M the
  3255. number of months, <emph>n</emph>D the number of days, 'T' is the
  3256. date/time separator, <emph>n</emph>H the number of hours,
  3257. <emph>n</emph>M the number of minutes and <emph>n</emph>S the
  3258. number of seconds.  The number of seconds can include decimal digits
  3259. to arbitrary precision.</p>
  3260. <p>
  3261. The values of the
  3262. Year, Month, Day, Hour and Minutes components are not restricted but 
  3263. allow an arbitrary integer.  Similarly, the value of the Seconds component
  3264. allows an arbitrary decimal.  Thus, the lexical representation of
  3265. <term>duration</term> does not follow the alternative 
  3266. format of § 5.5.3.2.1 of <bibref ref="ISO8601"/>.</p>
  3267. <p>
  3268. An optional preceding minus sign ('-') is
  3269. allowed, to indicate a negative duration.  If the sign is omitted a
  3270. positive duration is indicated. See also <specref ref="isoformats"/>.
  3271. </p>
  3272. <p>
  3273. For example, to indicate a duration of 1 year, 2 months, 3 days, 10
  3274. hours, and 30 minutes, one would write: <code>P1Y2M3DT10H30M</code>.
  3275. One could also indicate a duration of minus 120 days as:
  3276. <code>-P120D</code>.
  3277. </p>
  3278. <p>
  3279. Reduced precision and truncated representations of this format are allowed
  3280. provided they conform to the following:
  3281. </p>
  3282. <ulist>
  3283. <item>
  3284. <p>
  3285. If the number of years, months, days, hours, minutes, or seconds in any
  3286. expression equals zero, the number and its corresponding designator <termref def="dt-may"/>
  3287. be omitted.  However, at least one number and its designator <termref def='dt-must'/>
  3288. be present.
  3289. </p>
  3290. </item>
  3291. <item>
  3292. <p>
  3293. The seconds part <termref def="dt-may"/> have a decimal fraction.
  3294. </p>
  3295. </item>
  3296. <!-- INTERIOR FIELDS DISALLOWED FOR TIME INSTANT NOT DURATION
  3297. <item>If a field is omitted either all fields to its left or to its right
  3298. must be omitted i.e. interior fields cannot be omitted.</item>  -->
  3299. <item>
  3300. <p>
  3301. The designator 'T' shall be absent if all of the time items are absent.
  3302. The designator 'P' must always be present.
  3303. </p>
  3304. </item>
  3305. </ulist>
  3306. <p>
  3307. For example, P1347Y, P1347M and P1Y2MT2H are all allowed;
  3308. P0Y1347M and P0Y1347M0D are allowed. P-1347M is not allowed although
  3309. -P1347M is allowed.  P1Y2MT is not allowed.
  3310. </p>
  3311.  
  3312. </div4>
  3313.  
  3314. <div4 id="duration-order">
  3315. <head>Order relation on duration</head>
  3316. <p>
  3317. In general, the <termref def="dt-order-relation"/> on <term>duration</term>
  3318. is a partial order since there is no determinate relationship between certain
  3319. durations such as one month (P1M) and 30 days (P30D).   
  3320. The <termref def="dt-order-relation"/>
  3321. of two <term>duration</term> values <emph role="eq">x</emph> and
  3322. <emph role="eq">y</emph> is <emph role="eq">x < y iff s+x < s+y</emph>
  3323. for each qualified <dtref ref='dateTime'/> <emph role="eq"> s</emph>
  3324. in the list below.  These values for <emph>s</emph> cause the greatest deviations in the addition of 
  3325. dateTimes and durations.  Addition of durations to time instants is defined
  3326. in <specref ref="adding-durations-to-dateTimes"/>.
  3327. <ulist>
  3328. <item><p>1696-09-01T00:00:00Z</p></item> 
  3329. <item><p>1697-02-01T00:00:00Z</p></item>
  3330. <item><p>1903-03-01T00:00:00Z</p></item>
  3331. <item><p>1903-07-01T00:00:00Z</p></item>
  3332. </ulist>
  3333. </p>
  3334. <p>
  3335. The following table shows the strongest relationship that can be determined
  3336. between example durations. The symbol <> means that the order relation is
  3337. indeterminate.  Note that because of leap-seconds, a seconds field can vary
  3338. from 59 to 60. However, because of the way that addition is defined in
  3339. <specref ref="adding-durations-to-dateTimes"/>, they are still totally ordered.
  3340. </p>
  3341.  <table border="1" cellspacing="0" cellpadding="4">
  3342.     <tbody>
  3343.     <tr>
  3344.       <th> </th>
  3345.       <th colspan="7" style='background-color:#FFFF99'>Relation</th>
  3346.     </tr>
  3347.     <tr>
  3348.       <td style="background-color:#FFFF99">P<strong>1Y</strong></td>
  3349.       <td>> P<strong>364D</strong></td>
  3350.       <td><> P<strong>365D</strong></td>
  3351.       <td colspan="3"> </td>
  3352.       <td><> P<strong>366D</strong></td>
  3353.       <td>< P<strong>367D</strong></td>
  3354.     </tr>
  3355.     <tr>
  3356.       <td style='background-color:#FFFF99'>P<strong>1M</strong></td>
  3357.       <td>> P<strong>27D</strong></td>
  3358.       <td><> P<strong>28D</strong></td>
  3359.       <td colspan="2"><> P<strong>29D</strong></td>
  3360.       <td><> P<strong>30D</strong></td>
  3361.       <td><> P<strong>31D</strong></td>
  3362.       <td>< P<strong>32D</strong></td>
  3363.     </tr>
  3364.     <tr>
  3365.       <td style='background-color:#FFFF99'>P<strong>5M</strong></td>
  3366.       <td>> P<strong>149D</strong></td>
  3367.       <td><> P<strong>150D</strong></td>
  3368.       <td><> P<strong>151D</strong></td>
  3369.       <td colspan="2"><> P<strong>152D</strong></td>
  3370.       <td><> P<strong>153D</strong></td>
  3371.       <td>< P<strong>154D</strong></td>
  3372.     </tr>
  3373.     </tbody>
  3374.   </table>
  3375. <p>
  3376. Implementations are free to optimize the computation of the ordering relationship. For example, the following table can be used to
  3377. compare durations of a small number of months against days.
  3378. </p>
  3379.   <table border="1" cellspacing="0" cellpadding="2">
  3380.       <tbody>
  3381.     <tr>
  3382.       <th align="center"> </th>
  3383.       <th align="center" style="background-color: #FFFF99">Months</th>
  3384.       <th align="center" style="background-color: #FFFF99">1</th>
  3385.       <th align="center" style="background-color: #FFFF99">2</th>
  3386.       <th align="center" style="background-color: #FFFF99">3</th>
  3387.       <th align="center" style="background-color: #FFFF99">4</th>
  3388.       <th align="center" style="background-color: #FFFF99">5</th>
  3389.       <th align="center" style="background-color: #FFFF99">6</th>
  3390.       <th align="center" style="background-color: #FFFF99">7</th>
  3391.       <th align="center" style="background-color: #FFFF99">8</th>
  3392.       <th align="center" style="background-color: #FFFF99">9</th>
  3393.       <th align="center" style="background-color: #FFFF99">10</th>
  3394.       <th align="center" style="background-color: #FFFF99">11</th>
  3395.       <th align="center" style="background-color: #FFFF99">12</th>
  3396.       <th align="center" style="background-color: #FFFF99">13</th>
  3397.       <th align="center" style="background-color: #FFFF99">...</th>
  3398.     </tr>
  3399.     <tr>
  3400.       <th align="center" rowspan="2" style="background-color: #FFFF99">Days</th>
  3401.       <th align="center" style="background-color: #FFFF99">Minimum</th>
  3402.       <td align="center">28</td>
  3403.       <td align="center">59</td>
  3404.       <td align="center">89</td>
  3405.       <td align="center">120</td>
  3406.       <td align="center">150</td>
  3407.       <td align="center">181</td>
  3408.       <td align="center">212</td>
  3409.       <td align="center">242</td>
  3410.       <td align="center">273</td>
  3411.       <td align="center">303</td>
  3412.       <td align="center">334</td>
  3413.       <td align="center">365</td>
  3414.       <td align="center">393</td>
  3415.       <td align="center">...</td>
  3416.     </tr>
  3417.     <tr>
  3418.       <th align="center" style="background-color: #FFFF99">Maximum</th>
  3419.       <td align="center">31</td>
  3420.       <td align="center">62</td>
  3421.       <td align="center">92</td>
  3422.       <td align="center">123</td>
  3423.       <td align="center">153</td>
  3424.       <td align="center">184</td>
  3425.       <td align="center">215</td>
  3426.       <td align="center">245</td>
  3427.       <td align="center">276</td>
  3428.       <td align="center">306</td>
  3429.       <td align="center">337</td>
  3430.       <td align="center">366</td>
  3431.       <td align="center">397</td>
  3432.       <td align="center">...</td>
  3433.     </tr>
  3434.     </tbody>
  3435.   </table>
  3436. </div4>
  3437.  
  3438. <div4 id = "facet-comparison-for-durations">
  3439. <head>Facet Comparison for durations</head>
  3440. <p>In comparing <term>duration</term>
  3441. values with <compref ref='dc-minInclusive'/>,  <compref ref='dc-minExclusive'/>,
  3442. <compref ref='dc-maxInclusive'/> and <compref ref='dc-maxExclusive'/> facet values
  3443. indeterminate comparisons should be considered as "false".
  3444. </p>
  3445. </div4>
  3446.  
  3447. <div4 id = "total-order-durations">
  3448. <head>Totally ordered durations</head>
  3449. <p>
  3450. Certain derived datatypes of durations can be guaranteed have a total order. For 
  3451. this, they must have fields from only one row in the list below and the time zone
  3452. must either be required or prohibited.
  3453. </p>
  3454. <ulist>
  3455. <item><p>year, month</p></item>
  3456. <item><p>day, hour, minute, second</p></item>
  3457. </ulist>
  3458. <p>
  3459. For example, a datatype could be defined to correspond to the 
  3460. <bibref ref='SQL'/> datatype Year-Month interval that required a four digit
  3461. year field and a two digit month field but required all other fields to be unspecified.  This datatype could be defined as below and would have a total order.
  3462. </p>
  3463. <eg><![CDATA[<simpleType name='SQL-Year-Month-Interval'>
  3464.     <restriction base='duration'>
  3465.       <pattern value='P\p{Nd}{4}Y\p{Nd}{2}M'/>
  3466.     </restriction>
  3467. </simpleType>]]></eg>
  3468. </div4>
  3469.  
  3470. <div4 id="duration-facets">
  3471. <head>Constraining facets</head>
  3472. <facets/>
  3473. </div4>
  3474. </div3>
  3475.  
  3476. <div3 id="dateTime">
  3477. <head>dateTime</head>
  3478. <p>
  3479. <termdef id="dt-dateTime" term="dateTime" role='local'>
  3480. <term>dateTime</term> represents a specific instant of time.  The
  3481. <termref def="dt-value-space"/> of <term>dateTime</term> is the space
  3482. of <emph>Combinations of date and time of day</emph> values as defined
  3483. in § 5.4 of <bibref ref="ISO8601"/>. 
  3484. </termdef>
  3485. </p>
  3486. <div4 id="dateTime-lexical-repr">
  3487. <head>Lexical representation</head>
  3488. <p>
  3489. A single lexical representation, which is a subset of the lexical
  3490. representations allowed by <bibref ref="ISO8601"/>, is allowed for
  3491. <term>dateTime</term>.  This lexical representation is the
  3492. <bibref ref="ISO8601"/> extended format CCYY-MM-DDThh:mm:ss
  3493. where "CC" represents the century, "YY" the year, "MM" the month and
  3494. "DD" the day, preceded by an optional leading "-" sign to indicate a
  3495. negative number. If the sign is omitted, "+" is assumed. The letter
  3496. "T" is the date/time separator and "hh", "mm", "ss" represent hour,
  3497. minute and second respectively.  Additional digits can be used to
  3498. increase the precision of fractional seconds if desired i.e the format
  3499. ss.ss... with any number of digits after the decimal point is supported. 
  3500. The fractional seconds part is optional; other parts of the
  3501. lexical form are not optional.
  3502. To accommodate
  3503. year values greater than 9999 additional digits can be added to the
  3504. left of this representation.  Leading zeros are required if the year value
  3505. would otherwise have fewer than four digits; otherwise they are forbidden.
  3506. The year 0000 is prohibited.
  3507. </p>
  3508. <p>
  3509. The CCYY field must have at least four digits, the MM, DD, SS, hh, mm
  3510. and ss fields exactly two digits each (not counting fractional seconds);
  3511. leading zeroes must be used if the field would otherwise have too few digits.
  3512. </p>
  3513. <p>
  3514. This representation may be immediately followed by a "Z" to indicate
  3515. Coordinated Universal Time (UTC) or, to indicate the time zone, i.e. the
  3516. difference between the local time and Coordinated Universal Time,
  3517. immediately followed by a sign,
  3518. + or -, followed by the difference from UTC represented as hh:mm (note:
  3519. the minutes part is required).
  3520. See <specref ref="isoformats"/> for details about legal values in the
  3521. various fields.
  3522. If the time zone is included, both hours and minutes must be present.
  3523. </p>
  3524. <p>
  3525. For example, to indicate 1:20 pm on May the 31st, 1999 for Eastern
  3526. Standard Time which is 5 hours behind Coordinated Universal Time (UTC), one
  3527. would write: <code>1999-05-31T13:20:00-05:00</code>.
  3528. </p>
  3529. </div4>
  3530. <div4 id="dateTime-canonical-repr">
  3531. <head>Canonical representation</head>
  3532. <p>
  3533. The canonical representation for <term>dateTime</term> is defined
  3534. by prohibiting certain options from the
  3535. <specref ref="dateTime-lexical-repr"/>.   
  3536. Specifically, either the time zone must
  3537. be omitted or, if present,  the time zone must be Coordinated Universal
  3538. Time (UTC) indicated by a "Z".  
  3539. </p>
  3540. </div4>
  3541. <div4 id="dateTime-order">
  3542. <head>Order relation on dateTime</head>
  3543. <p>In general, the <termref def="dt-order-relation"/> on <term>dateTime</term>
  3544. is a partial order since there is no determinate relationship between certain
  3545. instants. For example, there is no determinate
  3546. ordering between 
  3547. (a)
  3548. 2000-01-20T12:00:00 and (b) 2000-01-20T12:00:00<strong>Z</strong>. Based on
  3549. timezones currently in use, (c) could vary from 2000-01-20T12:00:00+12:00 to
  3550. 2000-01-20T12:00:00-13:00. It is, however, possible for this range to expand or
  3551. contract in the future, based on local laws. Because of this, the following
  3552. definition uses a somewhat broader range of indeterminate values: +14:00..-14:00.</p>
  3553. <p>The following definition uses the notation S[year] to represent the year
  3554. field of S, S[month] to represent the month field, and so on. The notation (Q
  3555. & "-14:00") means adding the timezone -14:00 to Q, where Q did not
  3556. already have a timezone. <emph>This is a logical explanation of the process. Actual
  3557. implementations are free to optimize as long as they produce the same results.</emph>
  3558. </p>
  3559. <p>
  3560. The ordering between two <term>dateTime</term>s P and Q is defined by the following
  3561. algorithm:
  3562. </p>
  3563.   <p>A.Normalize P and Q. That is, if there is a timezone present, but
  3564.   it is not Z, convert it to Z using the addition operation defined in 
  3565.   <specref ref="adding-durations-to-dateTimes"/></p>
  3566.   <ulist>
  3567.     <item><p>Thus 2000-03-04T23:00:00+03:00 normalizes to 2000-03-04T20:00:00Z</p></item>
  3568.   </ulist>
  3569.   <p>B. If P and Q either both have a time zone or both do not have a time
  3570.    zone, compare P and Q field by field from the year field down to the
  3571.    second field, and return a result as soon as it can be determined. That is:</p>
  3572.   <olist>
  3573.     <item><p>For each i in {year, month, day, hour, minute, second}
  3574.       <olist>
  3575.         <item><p>If P[i] and Q[i] are both not specified, continue to the next i</p></item>
  3576.         <item><p>If P[i] is not specified and Q[i] is, or vice versa, stop and return
  3577.           P <> Q</p></item>
  3578.         <item><p>If P[i] < Q[i], stop and return P < Q</p></item>
  3579.         <item><p>If P[i] > Q[i], stop and return P > Q</p></item>
  3580.       </olist>
  3581.     </p>
  3582.     </item>
  3583.     <item><p>Stop and return P = Q</p></item>
  3584.   </olist>
  3585.   <p>C.Otherwise, if P contains a time zone and Q does not, compare
  3586.   as follows:
  3587.  </p>
  3588.     <olist>
  3589.       <item><p>P < Q if P < (Q with time zone +14:00)</p></item>
  3590.       <item><p>P > Q if P > (Q with time zone -14:00)</p></item>
  3591.       <item><p>P <> Q otherwise, that is, if (Q with time zone +14:00) < P < (Q with time zone -14:00)</p></item>
  3592.      </olist>
  3593.    <p>D. Otherwise, if P does not contain a time zone and Q does, compare
  3594.   as follows:</p>
  3595.     <olist>
  3596.       <item><p> P < Q if (P with time zone -14:00) < Q.</p></item>
  3597.       <item><p> P > Q if (P with time zone +14:00) > Q.</p></item>
  3598.       <item><p> P <> Q otherwise, that is, if (P with time zone +14:00) < Q < (P with time zone -14:00)</p></item>
  3599.     </olist>
  3600. <p>Examples:</p>
  3601.     <table border="1" cellspacing="0" cellpadding="4">
  3602.     <tbody>
  3603.       <tr>
  3604.         <th align="center" style="background-color: #FFFF99">Determinate</th>
  3605.         <th align="center" style="background-color: #FFFF99">Indeterminate</th>
  3606.       </tr>
  3607.       <tr>
  3608.         <td align="center">2000-01-15T00:00:00 <strong><</strong> 2000-02-15T00:00:00</td>
  3609.         <td align="center">2000-01-01T12:00:00 <strong><></strong>
  3610.           1999-12-31T23:00:00Z</td>
  3611.       </tr>
  3612.       <tr>
  3613.         <td align="center">2000-01-15T12:00:00 <strong><</strong> 2000-01-16T12:00:00Z</td>
  3614.         <td align="center">2000-01-16T12:00:00 <strong><></strong>
  3615.           2000-01-16T12:00:00Z</td>
  3616.       </tr>
  3617.       <tr>
  3618.         <td align="center"> </td>
  3619.         <td align="center">2000-01-16T00:00:00 <strong><></strong> 2000-01-16T12:00:00Z</td>
  3620.       </tr>
  3621.       </tbody>
  3622.     </table>
  3623. </div4>
  3624. <div4 id="totally-ordered-instants">
  3625. <head>Totally ordered dateTimes</head>
  3626. <p>Certain derived types from <term>dateTime</term> 
  3627. can be guaranteed have a total order. To
  3628. do so, they must require that a specific set of fields are always specified, and
  3629. that remaining fields (if any) are always unspecified. For example, the date
  3630. datatype without time zone is defined to contain exactly year, month, and day.
  3631. Thus dates without time zone have a total order among themselves.</p>
  3632. </div4>
  3633. <div4 id="dateTime-facets">
  3634. <head>Constraining facets</head>
  3635. <facets/>
  3636. </div4>
  3637. </div3>
  3638.  
  3639. <div3 id="time">
  3640. <head>time</head>
  3641. <p>
  3642. <termdef id="dt-time" term="time" role='local'><term>time</term>
  3643. represents an instant of time that recurs every day.  The
  3644. <termref def="dt-value-space"/> of <term>time</term> is the space
  3645. of <emph>time of day</emph> values as defined in § 5.3 of
  3646. <bibref ref="ISO8601"/>.  Specifically, it is a set of zero-duration daily
  3647. time instances.</termdef>
  3648. </p>
  3649. <p>
  3650. Since the lexical representation allows an optional time zone 
  3651. indicator, <term>time</term> values are partially ordered because it may
  3652. not be able to determine the order of two values one of which has a
  3653. time zone and the other does not.  The order relation on 
  3654. <term>time</term> values is the 
  3655. <specref ref='dateTime-order'/> using an arbitrary date. See also
  3656. <specref ref="adding-durations-to-dateTimes"/>.  Pairs of <term>time</term> values with or without time zone indicators are totally ordered.  
  3657. </p>
  3658. <div4 id="time-lexical-repr">
  3659. <head>Lexical representation</head>
  3660. <p>
  3661. The lexical representation for <term>time</term> is the left
  3662. truncated lexical representation for <dtref ref="dateTime"/>:
  3663. hh:mm:ss.sss with optional following time zone indicator.  For example,
  3664. to indicate 1:20 pm for Eastern Standard Time which is 5 hours behind
  3665. Coordinated Universal Time (UTC), one would write: 13:20:00-05:00. See also
  3666. <specref ref="isoformats"/>.
  3667. </p>
  3668. </div4>
  3669. <div4 id="time-canonical-repr">
  3670. <head>Canonical representation</head>
  3671. <p>
  3672. The canonical representation for <term>time</term> is defined
  3673. by prohibiting certain options from the
  3674. <specref ref="time-lexical-repr"/>.  Specifically, either the time zone must
  3675. be omitted or, if present,  the time zone must be Coordinated Universal
  3676. Time (UTC) indicated by a "Z".  
  3677. Additionally, the canonical representation for midnight is 00:00:00.
  3678. </p>
  3679. </div4>
  3680. <div4 id="time-facets">
  3681. <head>Constraining facets</head>
  3682. <facets/>
  3683. </div4>
  3684. </div3>
  3685.  
  3686. <div3 id="date">
  3687. <head>date</head>
  3688. <p>
  3689. <termdef id="dt-date" term="date" role='local'><term>date</term>
  3690. represents a calendar date.  The <termref def="dt-value-space"/>
  3691. of <term>date</term> is the set of Gregorian calendar dates as defined
  3692. in § 5.2.1 of <bibref ref="ISO8601"/>.  Specifically,
  3693. it is a set of one-day long, non-periodic instances
  3694. e.g. lexical 1999-10-26 to represent the calendar date 1999-10-26, independent
  3695. of how many hours this day has.
  3696. </termdef>
  3697. </p>
  3698. <p>
  3699. Since the lexical representation allows an optional time zone 
  3700. indicator, <term>date</term> values are partially ordered because it may
  3701. not be possible to unequivocally determine the order of two values one of which has a
  3702. time zone and the other does not.  If  
  3703. <term>date</term> values are considered as periods of time, the order relation 
  3704. on <term>date</term> values is the order relation on their starting instants.
  3705. This is discussed in <specref ref='dateTime-order'/>.  See also
  3706. <specref ref="adding-durations-to-dateTimes"/>.  Pairs of <term>date</term> values with or without time zone indicators are totally ordered.  
  3707. </p>
  3708. <div4 id="date-lexical-repr">
  3709. <head>Lexical representation</head>
  3710. <p>
  3711. The lexical representation for <term>date</term> is the reduced (right
  3712. truncated) lexical representation  for <dtref ref="dateTime"/>:
  3713. CCYY-MM-DD.  No left truncation is allowed.  An optional following time
  3714. zone qualifier is allowed as for <dtref ref="dateTime"/>.   To
  3715. accommodate year values outside the range from 0001 to 9999, additional
  3716. digits can be added to the left of this representation and a preceding "-" 
  3717. sign is allowed.
  3718. </p>
  3719. <p>
  3720. For example, to indicate May the 31st, 1999, one would write: 1999-05-31.
  3721. See also <specref ref="isoformats"/>.
  3722. </p>
  3723. </div4>
  3724. <div4 id="date-facets">
  3725. <head>Constraining facets</head>
  3726. <facets/>
  3727. </div4>
  3728. </div3>
  3729.  
  3730. <div3 id="gYearMonth">
  3731. <head>gYearMonth</head>
  3732. <p>
  3733. <termdef id="dt-gYearMonth" term="gYearMonth" role='local'>
  3734. <term>gYearMonth</term> represents a
  3735. specific gregorian month in a specific gregorian year.  The
  3736. <termref def="dt-value-space"/> of <term>gYearMonth</term>
  3737. is the set of Gregorian calendar months as defined in § 5.2.1 of
  3738. <bibref ref="ISO8601"/>.  Specifically, it is a set of one-month long,
  3739. non-periodic instances
  3740. e.g. 1999-10 to represent the whole month of 1999-10, independent of
  3741. how many days this month has.
  3742. </termdef>
  3743. </p>
  3744. <p>
  3745. Since the lexical representation allows an optional time zone 
  3746. indicator, <term>gYearMonth</term> values are partially ordered because it may
  3747. not be possible to unequivocally determine the order of two values one of
  3748. which has a time zone and the other does not.  If <term>gYearMonth</term>
  3749. values are considered as periods of time, the order relation on
  3750. <term>gYearMonth</term> values is the order relation on their starting instants.
  3751. This is discussed in <specref ref='dateTime-order'/>.  See also
  3752. <specref ref="adding-durations-to-dateTimes"/>.  Pairs of <term>gYearMonth</term>
  3753. values with or without time zone indicators are totally ordered.  
  3754. </p>
  3755. <note>
  3756. <p>
  3757. Because month/year combinations in one calendar only rarely correspond
  3758. to month/year combinations in other calendars, values of this type
  3759. are not, in general, convertible to simple values corresponding to month/year
  3760. combinations in other calendars.  This type should therefore be used with caution
  3761. in contexts where conversion to other calendars is desired.
  3762. </p>
  3763. </note>
  3764. <div4 id="gYearMonth-lexical-repr">
  3765. <head>Lexical representation</head>
  3766. <p>
  3767. The lexical representation for <term>gYearMonth</term> is the reduced
  3768. (right truncated) lexical representation for <dtref ref="dateTime"/>:
  3769. CCYY-MM.  No left truncation is allowed.  An optional following time
  3770. zone qualifier is allowed.  To accommodate year values outside the range from 0001 to 9999, additional digits
  3771. can be added to the left of this representation and a preceding "-" sign is allowed. 
  3772. </p>
  3773. <p>
  3774. For example, to indicate the month of May 1999, one would write: 1999-05.
  3775. See also <specref ref="isoformats"/>.
  3776. </p>
  3777. </div4>
  3778.  
  3779. <div4 id="gYearMonth-facets">
  3780. <head>Constraining facets</head>
  3781. <facets/>
  3782. </div4>
  3783. </div3>
  3784.  
  3785. <div3 id="gYear">
  3786. <head>gYear</head>
  3787. <p>
  3788. <termdef id="dt-gYear" term="gYear" role='local'>
  3789. <term>gYear</term> represents a
  3790. gregorian calendar year.  The <termref def="dt-value-space"/> of
  3791. <term>gYear</term> is the set of Gregorian calendar years as defined in
  3792. § 5.2.1 of <bibref ref="ISO8601"/>. Specifically, it is a set of one-year
  3793. long, non-periodic instances
  3794. e.g. lexical 1999 to represent the whole year 1999, independent of
  3795. how many months and days this year has.
  3796. </termdef>
  3797. </p>
  3798. <p>
  3799. Since the lexical representation allows an optional time zone 
  3800. indicator, <term>gYear</term> values are partially ordered because it may
  3801. not be possible to unequivocally determine the order of two values one of which has a
  3802. time zone and the other does not.  If  
  3803. <term>gYear</term> values are considered as periods of time, the order relation 
  3804. on <term>gYear</term> values is the order relation on their starting instants.
  3805. This is discussed in <specref ref='dateTime-order'/>.  See also
  3806. <specref ref="adding-durations-to-dateTimes"/>.  Pairs of <term>gYear</term> values with or without time zone indicators are totally ordered.  
  3807. </p>
  3808. <note>
  3809. <p>
  3810. Because years in one calendar only rarely correspond to years
  3811. in other calendars, values of this type
  3812. are not, in general, convertible to simple values corresponding to years
  3813. in other calendars.  This type should therefore be used with caution
  3814. in contexts where conversion to other calendars is desired.
  3815. </p>
  3816. </note>
  3817. <div4 id="gYear-lexical-repr">
  3818. <head>Lexical representation</head>
  3819. <p>
  3820. The lexical representation for <term>gYear</term> is the reduced (right
  3821. truncated) lexical representation for <dtref ref="dateTime"/>: CCYY.
  3822. No left truncation is allowed.  An optional following time
  3823. zone qualifier is allowed as for <dtref ref="dateTime"/>.   To
  3824. accommodate year values outside the range from 0001 to 9999, additional
  3825. digits can be added to the left of this representation and a preceding
  3826. "-" sign is allowed.
  3827. </p>
  3828. <p>
  3829. For example, to indicate 1999, one would write: 1999.
  3830. See also <specref ref="isoformats"/>.
  3831. </p>
  3832. </div4>
  3833.  
  3834. <div4 id="gYear-facets">
  3835. <head>Constraining facets</head>
  3836. <facets/>
  3837. </div4>
  3838. </div3>
  3839.  
  3840. <div3 id="gMonthDay">
  3841. <head>gMonthDay</head>
  3842. <p>
  3843. <termdef id="dt-gMonthDay" term="gMonthDay" role='local'>
  3844. <term>gMonthDay</term> is a gregorian date that recurs, specifically a day of
  3845. the year such as the third of May.  Arbitrary recurring dates are not
  3846. supported by this datatype.  The <termref def="dt-value-space"/> of
  3847. <term>gMonthDay</term> is the set of <emph>calendar
  3848. dates</emph>, as defined in § 3 of <bibref ref="ISO8601"/>.  Specifically,
  3849. it is a set of one-day long, annually periodic instances.
  3850. </termdef>
  3851. </p>
  3852. <p>
  3853. Since the lexical representation allows an optional time zone 
  3854. indicator, <term>gMonthDay</term> values are partially ordered because it may
  3855. not be possible to unequivocally determine the order of two values one of which has a
  3856. time zone and the other does not.  If  
  3857. <term>gMonthDay</term> values are considered as periods of time, the order relation 
  3858. on <term>gMonthDay</term> values is the order relation on their starting instants.
  3859. This is discussed in <specref ref='dateTime-order'/>.  See also
  3860. <specref ref="adding-durations-to-dateTimes"/>.  Pairs of <term>gMonthDay</term> values with or without time zone indicators are totally ordered.  
  3861. </p>
  3862. <note>
  3863. <p>
  3864. Because day/month combinations in one calendar only rarely correspond
  3865. to day/month combinations in other calendars, values of this type do not,
  3866. in general, have any straightforward or intuitive representation
  3867. in terms of most other calendars. This type should therefore be
  3868. used with caution in contexts where conversion to other calendars
  3869. is desired.
  3870. </p>
  3871. </note>
  3872. <div4 id="gMonthDay-lexical-repr">
  3873. <head>Lexical representation</head>
  3874. <p>
  3875. The lexical representation for <term>gMonthDay</term> is the left
  3876. truncated lexical representation for <dtref ref="date"/>: --MM-DD.
  3877. An optional following time
  3878. zone qualifier is allowed as for <dtref ref="date"/>.
  3879. No preceding sign is allowed.  No other formats are allowed. See also <specref ref="isoformats"/>.
  3880. </p>
  3881. <p>This datatype can be used to represent a specific day in a month.
  3882. To say, for example, that my birthday occurs on the 14th of September ever year.
  3883. </p>
  3884. </div4>
  3885.  
  3886. <div4 id="gMonthDay-facets">
  3887. <head>Constraining facets</head>
  3888. <facets/>
  3889. </div4>
  3890. </div3>
  3891.  
  3892. <div3 id="gDay">
  3893. <head>gDay</head>
  3894. <p>
  3895. <termdef id="dt-gDay" term="gDay" role='local'>
  3896. <term>gDay</term> is a gregorian day that recurs, specifically a day
  3897. of the month such as the 5th of the month.  Arbitrary recurring days
  3898. are not supported by this datatype.  The <termref def="dt-value-space"/>
  3899. of <term>gDay</term> is the space of a set of <emph>calendar
  3900. dates</emph> as defined in § 3 of <bibref ref="ISO8601"/>.  Specifically,
  3901. it is a set of one-day long, monthly periodic instances.
  3902. </termdef>
  3903. </p>
  3904. <p>
  3905. This datatype can be used to represent a specific day of the month.
  3906. To say, for example, that I get my paycheck on the 15th of each month.
  3907. </p>
  3908. <p>
  3909. Since the lexical representation allows an optional time zone 
  3910. indicator, <term>gDay</term> values are partially ordered because it may
  3911. not be possible to unequivocally determine the order of two values one of
  3912. which has a time zone and the other does not.  If  
  3913. <term>gDay</term> values are considered as periods of time, the order relation 
  3914. on <term>gDay</term> values is the order relation on their starting instants.
  3915. This is discussed in <specref ref='dateTime-order'/>.  See also
  3916. <specref ref="adding-durations-to-dateTimes"/>.  Pairs of <term>gDay</term>
  3917. values with or without time zone indicators are totally ordered.  
  3918. </p>
  3919. <note>
  3920. <p>
  3921. Because days in one calendar only rarely correspond
  3922. to days in other calendars, values of this type do not,
  3923. in general, have any straightforward or intuitive representation
  3924. in terms of most other calendars. This type should therefore be
  3925. used with caution in contexts where conversion to other calendars
  3926. is desired.
  3927. </p>
  3928. </note>
  3929. <div4 id="gDay-lexical-repr">
  3930. <head>Lexical representation</head>
  3931. <p>
  3932. The lexical representation for <term>gDay</term> is the left
  3933. truncated lexical representation for <dtref ref="date"/>: ---DD .
  3934. An optional following time
  3935. zone qualifier is allowed as for <dtref ref="date"/>.  No preceding sign is
  3936. allowed. No other formats are allowed.  See also <specref ref="isoformats"/>.
  3937. </p>
  3938. </div4>
  3939.  
  3940. <div4 id="gDay-facets">
  3941. <head>Constraining facets</head>
  3942. <facets/>
  3943. </div4>
  3944. </div3>
  3945.  
  3946. <div3 id="gMonth">
  3947. <head>gMonth</head>
  3948. <p>
  3949. <termdef id="dt-gMonth" term="gMonth" role='local'>
  3950. <term>gMonth</term> is a gregorian month that recurs every year.
  3951. The <termref def="dt-value-space"/>
  3952. of <term>gMonth</term> is the space of a set of <emph>calendar
  3953. months</emph> as defined in § 3 of <bibref ref="ISO8601"/>.  Specifically,
  3954. it is a set of one-month long, yearly periodic instances.
  3955. </termdef>
  3956. </p>
  3957. <p>
  3958. This datatype can be used to represent a specific month.
  3959. To say, for example, that Thanksgiving falls in the month of November.
  3960. </p>
  3961. <p>
  3962. Since the lexical representation allows an optional time zone 
  3963. indicator, <term>gMonth</term> values are partially ordered because it may
  3964. not be possible to unequivocally determine the order of two values one of which has a
  3965. time zone and the other does not.  If  
  3966. <term>gMonth</term> values are considered as periods of time, the order relation 
  3967. on <term>gMonth</term> is the order relation on their starting instants.
  3968. This is discussed in <specref ref='dateTime-order'/>.  See also
  3969. <specref ref="adding-durations-to-dateTimes"/>.  Pairs of <term>gMonth</term>
  3970. values with or without time zone indicators are totally ordered.  
  3971. </p>
  3972. <note>
  3973. <p>
  3974. Because months in one calendar only rarely correspond
  3975. to months in other calendars, values of this type do not,
  3976. in general, have any straightforward or intuitive representation
  3977. in terms of most other calendars. This type should therefore be
  3978. used with caution in contexts where conversion to other calendars
  3979. is desired.
  3980. </p>
  3981. </note>
  3982. <div4 id="gMonth-lexical-repr">
  3983. <head>Lexical representation</head>
  3984. <p>
  3985. The lexical representation for <term>gMonth</term> is the left
  3986. and right truncated lexical representation for <dtref ref="date"/>: --MM--.
  3987. An optional following time
  3988. zone qualifier is allowed as for <dtref ref="date"/>.  No preceding sign is
  3989. allowed. No other formats are allowed.  See also <specref ref="isoformats"/>.
  3990. </p>
  3991. </div4>
  3992.  
  3993. <div4 id="gMonth-facets">
  3994. <head>Constraining facets</head>
  3995. <facets/>
  3996. </div4>
  3997. </div3>
  3998. <div3 id="hexBinary">
  3999. <head>hexBinary</head>
  4000. <p>
  4001. <termdef id="dt-hexBinary" term="hexBinary" role='local'>
  4002. <term>hexBinary</term> represents
  4003. arbitrary hex-encoded binary data.  The <termref def="dt-value-space"/> of
  4004. <term>hexBinary</term> is the set of finite-length sequences of binary
  4005. octets.
  4006. </termdef>
  4007. </p>
  4008. <div4 id='hexBinary-lexical-representation'>
  4009. <head>Lexical Representation</head>
  4010. <p>
  4011. <term>hexBinary</term> has a lexical representation where
  4012. each binary octet is encoded as a character tuple, consisting of two
  4013. hexadecimal digits ([0-9a-fA-F]) representing the octet code. For example,
  4014. "0FB7" is a <emph>hex</emph> encoding for the 16-bit integer 4023
  4015. (whose binary representation is 111110110111).
  4016. </p>
  4017. </div4>
  4018. <div4 id="hexBinary-canonical-repr">
  4019. <head>Canonical Rrepresentation</head>
  4020. <p>
  4021. The canonical representation for <term>hexBinary</term> is defined
  4022. by prohibiting certain options from the
  4023. <specref ref="hexBinary-lexical-representation"/>.  Specifically, the lower case
  4024. hexadecimal digits ([a-f]) are not allowed.
  4025. </p>
  4026. </div4>
  4027. <div4 id="hexBinary-facets">
  4028. <head>Constraining facets</head>
  4029. <facets/> 
  4030. </div4>
  4031. </div3>
  4032. <div3 id="base64Binary">
  4033. <head>base64Binary</head>
  4034. <p>
  4035. <termdef id="dt-base64Binary" term="base64Binary" role='local'>
  4036. <term>base64Binary</term>
  4037. represents Base64-encoded arbitrary binary data.  The <termref def="dt-value-space"/> of
  4038. <term>base64Binary</term> is the set of finite-length sequences of binary
  4039. octets. For <term>base64Binary</term> data the
  4040. entire binary stream is encoded using the Base64
  4041. Content-Transfer-Encoding defined in Section 6.8 of <bibref ref="RFC2045"/>.
  4042. </termdef>
  4043. </p>
  4044. <div4 id="base64Binary-facets">
  4045. <head>Constraining facets</head>
  4046. <facets/> 
  4047. </div4>
  4048. </div3>
  4049. <div3 id="anyURI">
  4050. <head>anyURI</head>
  4051. <p>
  4052. <termdef id="dt-anyURI" term="anyURI" role='local'>
  4053. <term>anyURI</term> represents a Uniform Resource Identifier Reference
  4054. (URI).  An <term>anyURI</term> value can be absolute or relative, and may
  4055. have an optional fragment identifier (i.e., it may be a URI Reference).  This
  4056. type should be used to specify the intention that the value fulfills
  4057. the role of a URI as defined by <bibref ref='RFC2396'/>, as amended by
  4058. <bibref ref='RFC2732'/>.
  4059. </termdef>
  4060. </p>
  4061. <p>
  4062. The mapping from <term>anyURI</term> values to URIs is as defined in
  4063. Section 5.4 <xspecref href='&xlink;#link-locators'>Locator Attribute</xspecref>
  4064. of <bibref ref='XLink'/> (see also Section 8
  4065. <xspecref href='&charmod;#sec-URIs'>Character Encoding in URI References</xspecref>
  4066. of <bibref ref='CharMod'/>).  This means
  4067. that a wide range of internationalized resource identifiers can be specified
  4068. when an <term>anyURI</term> is called for, and still be understood as 
  4069. URIs per <bibref ref='RFC2396'/>, as amended by <bibref ref='RFC2732'/>,
  4070. where appropriate to identify resources.
  4071. </p>
  4072.  
  4073. <note>
  4074. <p>
  4075. Each URI scheme imposes specialized syntax rules for URIs in
  4076. that scheme, including restrictions on the syntax of allowed fragement
  4077. identifiers. Because it is
  4078. impractical for processors to check that a value is a
  4079. context-appropriate URI reference, this specification follows the
  4080. lead of <bibref ref='RFC2396'/> (as amended by <bibref ref='RFC2732'/>)
  4081. in this matter: such rules and restrictions are not part of type validity
  4082. and are not checked by <termref def='dt-minimally-conforming'/> processors.
  4083. Thus in practice the above definition imposes only very modest obligations
  4084. on <termref def='dt-minimally-conforming'/> processors.
  4085. </p>
  4086. </note>
  4087.  
  4088. <div4 id="anyURI-lexical-representation">
  4089. <head>Lexical representation</head>
  4090. <p>
  4091. The <termref def="dt-lexical-space"/> of <term>anyURI</term> is
  4092. finite-length character sequences which, when the algorithm defined in
  4093. Section 5.4 of <bibref ref='XLink'/> is applied to them, result in strings
  4094. which are legal URIs according to <bibref ref='RFC2396'/>, as amended by
  4095. <bibref ref='RFC2732'/>.
  4096. </p>
  4097. <note>
  4098. <p>
  4099. Spaces are, in principle, allowed in the <termref def='dt-lexical-space'/>
  4100. of <term>anyURI</term>, however, their use is highly discouraged
  4101. (unless they are encoded by %20).
  4102. </p>
  4103. </note>
  4104. </div4>
  4105. <div4 id="anyURI-facets">
  4106. <head>Constraining facets</head>
  4107. <facets/>
  4108. </div4>
  4109. </div3>
  4110. <div3 id="QName">
  4111. <head>QName</head>
  4112. <p>
  4113. <termdef id="dt-QName" term="QName" role='local'>
  4114. <term>QName</term> represents
  4115. <xspecref href="&xmlnsspec;#dt-qname">XML qualified names</xspecref>.
  4116. The <termref def="dt-value-space"/> of <term>QName</term> is the set of
  4117. tuples {<xspecref href="&xmlnsspec;#dt-NSName">namespace name</xspecref>,
  4118. <xspecref href="&xmlnsspec;#dt-localname">local part</xspecref>},
  4119. where <xspecref href="&xmlnsspec;#dt-NSName">namespace name</xspecref>
  4120. is an <dtref ref="anyURI"/>
  4121. and <xspecref href="&xmlnsspec;#dt-localname">local part</xspecref> is
  4122. an <dtref ref="NCName"/>.
  4123.  
  4124. The <termref def="dt-lexical-space"/> of <term>QName</term> is the set
  4125. of strings that <termref def="dt-match"/> the <xspecref href="&xmlnsspec;#NT-QName">
  4126. QName</xspecref> production of <bibref ref="XMLNS"/>.
  4127. </termdef>
  4128. </p>
  4129. <note>
  4130. <p>
  4131. The mapping between literals in the <termref def='dt-lexical-space'/> and
  4132. values in the <termref def='dt-value-space'/> of <term>QName</term> requires
  4133. a namespace declaration to be in scope for the context in which <term>QName</term>
  4134. is used.
  4135. </p>
  4136. </note>
  4137. <div4 id="QName-facets">
  4138. <head>Constraining facets</head>
  4139. <facets/>
  4140. </div4>
  4141. </div3>
  4142.  
  4143. <div3 id="NOTATION">
  4144. <head>NOTATION</head>
  4145. <p>
  4146. <termdef id="dt-NOTATION" term="NOTATION" role='local'>
  4147. <term>NOTATION</term>
  4148. represents the <xnt href="&xmlspec;#NT-NotationType">NOTATION</xnt> attribute
  4149. type from <bibref ref="XML"/>. The <termref def="dt-value-space"/>
  4150. of <term>NOTATION</term> is the set <dtref ref='QName'/>s.  The
  4151. <termref def="dt-lexical-space"/> of <term>NOTATION</term> is the set
  4152. of all names of <xspecref href="&xsdl;#declare-notation">notations</xspecref>
  4153. declared in the current schema.
  4154. </termdef>
  4155. </p>
  4156. <constraintnote type="cos" id="enumeration-required-notation">
  4157. <head>enumeration facet value required for NOTATION</head>
  4158. <p>
  4159. It is an <termref def="dt-error"/> for <term>NOTATION</term>
  4160. to be used directly in a schema.  Only datatypes that are
  4161. <termref def="dt-derived"/> from <term>NOTATION</term> by
  4162. specifying a value for <termref def="dt-enumeration"/> can be used
  4163. in a schema.
  4164. </p>
  4165. </constraintnote>
  4166. <p>
  4167. For compatibility (see <specref ref="terminology"/>) <term>NOTATION</term>
  4168. should be used only on attributes.
  4169. </p>
  4170. <div4 id="NOTATION-facets">
  4171. <head>Constraining facets</head>
  4172. <facets/>
  4173. </div4>
  4174. </div3>
  4175. </div2>
  4176. <div2 id="built-in-derived">
  4177. <head>Derived datatypes</head>
  4178. <p>
  4179. This section gives conceptual definitions for all
  4180. <termref def="dt-built-in"/> <termref def="dt-derived"/> datatypes
  4181. defined by this specification. The XML representation used to define
  4182. <termref def="dt-derived"/> datatypes (whether
  4183. <termref def="dt-built-in"/> or <termref def="dt-user-derived"/>) is
  4184. given in section <specref ref="xr-defn"/> and the complete
  4185. definitions of the <termref def="dt-built-in"/> 
  4186. <termref def="dt-derived"/> datatypes are provided in Appendix A
  4187. <specref ref="schema"/>.
  4188. </p>
  4189. <div3 id="normalizedString">
  4190. <head>normalizedString</head>
  4191. <p>
  4192. <termdef id="dt-normalizedString" term="normalizedString" role='local'>
  4193. <term>normalizedString</term>
  4194. represents white space normalized strings.
  4195. The <termref def="dt-value-space"/> of <term>normalizedString</term> is the 
  4196. set of strings that do not
  4197. contain the carriage return (#xD), line feed (#xA) nor tab (#x9) characters.
  4198. The <termref def="dt-lexical-space"/> of <term>normalizedString</term> is the 
  4199. set of strings that do not
  4200. contain the carriage return (#xD) nor tab (#x9) characters.
  4201. The <termref def="dt-basetype"/> of <term>normalizedString</term> is <baseref/>.
  4202. </termdef>
  4203. </p>
  4204. <div4 id="normalizedString-facets">
  4205. <head>Constraining facets</head>
  4206. <facets/>
  4207. </div4>
  4208. <div4 id="normalizedString-derived-types">
  4209. <head>Derived datatypes</head>
  4210. <subtypes/>
  4211. </div4>
  4212. </div3>
  4213. <div3 id="token">
  4214. <head>token</head>
  4215. <p>
  4216. <termdef id="dt-token" term="token" role='local'>
  4217. <term>token</term>
  4218. represents tokenized strings.
  4219. The <termref def="dt-value-space"/> of <term>token</term> is the 
  4220. set of strings that do not
  4221. contain the line feed (#xA) nor tab (#x9) characters, that have no
  4222. leading or trailing spaces (#x20) and that have no internal sequences
  4223. of two or more spaces.
  4224. The <termref def="dt-lexical-space"/> of <term>token</term> is the 
  4225. set of strings that do not
  4226. contain the line feed (#xA) nor tab (#x9) characters, that have no
  4227. leading or trailing spaces (#x20) and that have no internal sequences
  4228. of two or more spaces.
  4229. The <termref def="dt-basetype"/> of <term>token</term> is <baseref/>.
  4230. </termdef>
  4231. </p>
  4232. <div4 id="token-facets">
  4233. <head>Constraining facets</head>
  4234. <facets/>
  4235. </div4>
  4236. <div4 id="token-derived-types">
  4237. <head>Derived datatypes</head>
  4238. <subtypes/>
  4239. </div4>
  4240. </div3>
  4241. <div3 id="language">
  4242. <head>language</head>
  4243. <p>
  4244. <termdef id="dt-language" term="language" role='local'>
  4245. <term>language</term>
  4246. represents natural language identifiers as defined by
  4247. <bibref ref="RFC1766"/>.  The <termref def="dt-value-space"/> of
  4248. <term>language</term> is the set of all strings that are valid
  4249. language identifiers as defined in the
  4250. <xspecref href="&xmlspec;#sec-lang-tag">language identification</xspecref>
  4251. section of <bibref ref="XML"/>.  The <termref def="dt-lexical-space"/> of
  4252. <term>language</term> is the set of all strings that are valid
  4253. language identifiers as defined in the
  4254. <xspecref href="&xmlspec;#sec-lang-tag">language identification</xspecref>
  4255. section of <bibref ref="XML"/>.
  4256. The <termref def="dt-basetype"/> of <term>language</term> is <baseref/>.
  4257. </termdef>
  4258. </p>
  4259. <div4 id="language-facets">
  4260. <head>Constraining facets</head>
  4261. <facets/>
  4262. </div4>
  4263. </div3>
  4264.  
  4265. <div3 id="NMTOKEN">
  4266. <head>NMTOKEN</head>
  4267. <p>
  4268. <termdef id="dt-NMTOKEN" term="NMTOKEN" role='local'>
  4269. <term>NMTOKEN</term> represents
  4270. the <xnt href="&xmlspec;#NT-TokenizedType">NMTOKEN attribute type</xnt>
  4271. from <bibref ref="XML"/>. The <termref def="dt-value-space"/> of
  4272. <term>NMTOKEN</term> is the set of tokens that <termref def="dt-match"/>
  4273. the <xnt href="&xmlspec;#NT-Nmtoken">Nmtoken</xnt> production in
  4274. <bibref ref="XML"/>. The <termref def="dt-lexical-space"/> of
  4275. <term>NMTOKEN</term> is the set of strings that <termref def="dt-match"/>
  4276. the <xnt href="&xmlspec;#NT-Nmtoken">Nmtoken</xnt> production in
  4277. <bibref ref="XML"/>.  The <termref def="dt-basetype"/> of
  4278. <term>NMTOKEN</term> is <baseref/>.
  4279. </termdef>
  4280. </p>
  4281. <p>
  4282. For compatibility (see <specref ref="terminology"/>) <term>NMTOKEN</term>
  4283. should be used only on attributes.
  4284. </p>
  4285. <div4 id="NMTOKEN-facets">
  4286. <head>Constraining facets</head>
  4287. <facets/>
  4288. </div4>
  4289. <div4 id="NMTOKEN-derived-types">
  4290. <head>Derived datatypes</head>
  4291. <subtypes/>
  4292. </div4>
  4293. </div3>
  4294. <div3 id="NMTOKENS">
  4295. <head>NMTOKENS</head>
  4296. <p>
  4297. <termdef id="dt-NMTOKENS" term="NMTOKENS" role='local'>
  4298. <term>NMTOKENS</term>
  4299. represents the <xnt href="&xmlspec;#NT-TokenizedType">NMTOKENS attribute
  4300. type</xnt> from <bibref ref="XML"/>. The <termref def="dt-value-space"/>
  4301. of <term>NMTOKENS</term> is the set of finite, non-zero-length sequences of
  4302. <termref def="dt-NMTOKEN"/>s.  The <termref def="dt-lexical-space"/>
  4303. of <term>NMTOKENS</term> is the set of white space separated lists of tokens,
  4304. of which each token is in the <termref def="dt-lexical-space"/> of
  4305. <dtref ref="NMTOKEN"/>.  The <termref def="dt-itemType"/> of
  4306. <term>NMTOKENS</term> is <itemTyperef/>.
  4307. </termdef>
  4308. </p>
  4309. <p>
  4310. For compatibility (see <specref ref="terminology"/>)
  4311. <term>NMTOKENS</term> should be used only on attributes.
  4312. </p>
  4313. <div4 id="NMTOKENS-facets">
  4314. <head>Constraining facets</head>
  4315. <facets/>
  4316. </div4>
  4317. </div3>
  4318. <div3 id="Name">
  4319. <head>Name</head>
  4320. <p>
  4321. <termdef id="dt-Name" term="Name" role='local'>
  4322. <term>Name</term>
  4323. represents <xspecref href="&xmlspec;#dt-name">XML Names</xspecref>.
  4324. The <termref def="dt-value-space"/> of <term>Name</term> is
  4325. the set of all strings which <termref def="dt-match"/> the
  4326. <xnt href="&xmlspec;#NT-Name">Name</xnt> production of
  4327. <bibref ref="XML"/>.  The <termref def="dt-lexical-space"/> of
  4328. <term>Name</term> is the set of all strings which <termref def="dt-match"/>
  4329. the <xnt href="&xmlspec;#NT-Name">Name</xnt> production of
  4330. <bibref ref="XML"/>. The <termref def="dt-basetype"/> of <term>Name</term>
  4331. is <baseref/>.
  4332. </termdef>
  4333. </p>
  4334. <div4 id="Name-facets">
  4335. <head>Constraining facets</head>
  4336. <facets/>
  4337. </div4>
  4338. <div4 id="Name-derived-types">
  4339. <head>Derived datatypes</head>
  4340. <subtypes/>
  4341. </div4>
  4342. </div3>
  4343. <div3 id="NCName">
  4344. <head>NCName</head>
  4345. <p>
  4346. <termdef id="dt-NCName" term="NCName" role='local'>
  4347. <term>NCName</term> represents XML
  4348. "non-colonized" Names.  The <termref def="dt-value-space"/> of
  4349. <term>NCName</term> is the set of all strings which <termref def="dt-match"/>
  4350. the <xnt href="&xmlnsspec;#NT-NCName">NCName</xnt> production of
  4351. <bibref ref="XMLNS"/>.  The <termref def="dt-lexical-space"/> of
  4352. <term>NCName</term> is the set of all strings which <termref def="dt-match"/>
  4353. the <xnt href="&xmlnsspec;#NT-NCName">NCName</xnt> production of
  4354. <bibref ref="XMLNS"/>.  The <termref def="dt-basetype"/> of
  4355. <term>NCName</term> is <baseref/>.
  4356. </termdef>
  4357. </p>
  4358. <div4 id="NCName-facets">
  4359. <head>Constraining facets</head>
  4360. <facets/>
  4361. </div4>
  4362. <div4 id="NCName-derived-types">
  4363. <head>Derived datatypes</head>
  4364. <subtypes/>
  4365. </div4>
  4366. </div3>
  4367. <div3 id="ID">
  4368. <head>ID</head>
  4369. <p>
  4370. <termdef id="dt-ID" term="ID" role='local'>
  4371. <term>ID</term> represents the
  4372. <xnt href="&xmlspec;#NT-TokenizedType">ID attribute type</xnt> from
  4373. <bibref ref="XML"/>.  The <termref def="dt-value-space"/> of
  4374. <term>ID</term> is the set of all strings that <termref def="dt-match"/>
  4375. the <xnt href="&xmlnsspec;#NT-NCName">NCName</xnt> production in
  4376. <bibref ref="XMLNS"/>.  The
  4377. <termref def="dt-lexical-space"/> of <term>ID</term> is the set of all
  4378. strings that <termref def="dt-match"/> the
  4379. <xnt href="&xmlnsspec;#NT-NCName">NCName</xnt> production in
  4380. <bibref ref="XMLNS"/>.
  4381. The <termref def="dt-basetype"/> of <term>ID</term> is <baseref/>.
  4382. </termdef>
  4383. </p>
  4384. <p>
  4385. For compatibility (see <specref ref="terminology"/>)
  4386. <term>ID</term> should be used only on attributes.
  4387. </p>
  4388.  
  4389. <div4 id="ID-facets">
  4390. <head>Constraining facets</head>
  4391. <facets/>
  4392. </div4>
  4393. </div3>
  4394. <div3 id="IDREF">
  4395. <head>IDREF</head>
  4396. <p>
  4397. <termdef id="dt-IDREF" term="IDREF" role='local'>
  4398. <term>IDREF</term> represents the
  4399. <xnt href="&xmlspec;#NT-TokenizedType">IDREF attribute type</xnt> from
  4400. <bibref ref="XML"/>.  The <termref def="dt-value-space"/> of
  4401. <term>IDREF</term> is the set of all strings that <termref def="dt-match"/>
  4402. the <xnt href="&xmlnsspec;#NT-NCName">NCName</xnt> production in
  4403. <bibref ref="XMLNS"/>.  The
  4404. <termref def="dt-lexical-space"/> of <term>IDREF</term> is the set of 
  4405. strings that <termref def="dt-match"/> the
  4406. <xnt href="&xmlnsspec;#NT-NCName">NCName</xnt> production in
  4407. <bibref ref="XMLNS"/>.
  4408. The <termref def="dt-basetype"/> of <term>IDREF</term> is <baseref/>.
  4409. </termdef>
  4410. </p>
  4411.  
  4412. <p>
  4413. For compatibility (see <specref ref="terminology"/>) this datatype
  4414. should be used only on attributes.
  4415. </p>
  4416.  
  4417. <div4 id="IDREF-facets">
  4418. <head>Constraining facets</head>
  4419. <facets/>
  4420. </div4>
  4421. <div4 id="IDREF-derived-types">
  4422. <head>Derived datatypes</head>
  4423. <subtypes/>
  4424. </div4>
  4425. </div3>
  4426.  
  4427. <div3 id="IDREFS">
  4428. <head>IDREFS</head>
  4429. <p>
  4430. <termdef id="dt-IDREFS" term="IDREFS" role='local'>
  4431. <term>IDREFS</term> represents the
  4432. <xnt href="&xmlspec;#NT-TokenizedType">IDREFS attribute type</xnt> from
  4433. <bibref ref="XML"/>.  The <termref def="dt-value-space"/> of
  4434. <term>IDREFS</term> is the set of finite, non-zero-length sequences of
  4435. <dtref ref="IDREF"/>s.
  4436. The <termref def="dt-lexical-space"/> of <term>IDREFS</term> is the
  4437. set of white space separated lists of tokens, of which each token is in the
  4438. <termref def="dt-lexical-space"/> of <dtref ref="IDREF"/>.
  4439. The <termref def="dt-itemType"/> of <term>IDREFS</term> is
  4440. <itemTyperef/>.
  4441. </termdef>
  4442. </p>
  4443. <p>
  4444. For compatibility (see <specref ref="terminology"/>) <term>IDREFS</term>
  4445. should be used only on attributes.
  4446. </p>
  4447.  
  4448. <div4 id="IDREFS-facets">
  4449. <head>Constraining facets</head>
  4450. <facets/>
  4451. </div4>
  4452. </div3>
  4453.  
  4454. <div3 id="ENTITY">
  4455. <head>ENTITY</head>
  4456. <p>
  4457. <termdef id="dt-ENTITY" term="ENTITY" role='local'>
  4458. <term>ENTITY</term> represents the
  4459. <xnt href="&xmlspec;#NT-TokenizedType">ENTITY</xnt> attribute type from
  4460. <bibref ref="XML"/>.  The <termref def="dt-value-space"/> of
  4461. <term>ENTITY</term> is the set of all strings that <termref def="dt-match"/>
  4462. the <xnt href="&xmlnsspec;#NT-NCName">NCName</xnt> production in
  4463. <bibref ref="XMLNS"/> and have been declared as an
  4464. <xspecref href="&xmlspec;#dt-unparsed">unparsed entity</xspecref> in
  4465. a <xspecref href="&xmlspec;#dt-doctype">document type definition</xspecref>.
  4466. The <termref def="dt-lexical-space"/> of <term>ENTITY</term> is the set
  4467. of all strings that <termref def="dt-match"/> the
  4468. <xnt href="&xmlnsspec;#NT-NCName">NCName</xnt> production in
  4469. <bibref ref="XMLNS"/>.
  4470. The <termref def="dt-basetype"/> of <term>ENTITY</term> is <baseref/>.
  4471. </termdef>
  4472. </p>
  4473. <note>
  4474. <p>
  4475. The <termref def="dt-value-space"/> of <term>ENTITY</term> is scoped
  4476. to a specific instance document.
  4477. </p>
  4478. </note>
  4479. <p>
  4480. For compatibility (see <specref ref="terminology"/>) <term>ENTITY</term>
  4481. should be used only on attributes.
  4482. </p>
  4483. <div4 id="ENTITY-facets">
  4484. <head>Constraining facets</head>
  4485. <facets/>
  4486. </div4>
  4487. <div4 id="ENTITY-derived-types">
  4488. <head>Derived datatypes</head>
  4489. <subtypes/>
  4490. </div4>
  4491. </div3>
  4492.  
  4493. <div3 id="ENTITIES">
  4494. <head>ENTITIES</head>
  4495. <p>
  4496. <termdef id="dt-ENTITIES" term="ENTITIES" role='local'>
  4497. <term>ENTITIES</term>
  4498. represents the <xnt href="&xmlspec;#NT-TokenizedType">ENTITIES attribute
  4499. type</xnt> from <bibref ref="XML"/>. The <termref def="dt-value-space"/>
  4500. of <term>ENTITIES</term> is the set of finite, non-zero-length sequences of
  4501. <termref def="dt-ENTITY"/>s that have been declared as
  4502. <xspecref href="&xmlspec;#dt-unparsed">unparsed entities</xspecref>
  4503. in a <xspecref href="&xmlspec;#dt-doctype">document type definition</xspecref>.
  4504. The <termref def="dt-lexical-space"/> of <term>ENTITIES</term> is the
  4505. set of white space separated lists of tokens, of which each token is in the
  4506. <termref def="dt-lexical-space"/> of <dtref ref="ENTITY"/>.
  4507. The <termref def="dt-itemType"/> of <term>ENTITIES</term> is
  4508. <itemTyperef/>.
  4509. </termdef>
  4510. </p>
  4511. <note>
  4512. <p>
  4513. The <termref def="dt-value-space"/> of <term>ENTITIES</term> is scoped
  4514. to a specific instance document.
  4515. </p>
  4516. </note>
  4517. <p>
  4518. For compatibility (see <specref ref="terminology"/>) <term>ENTITIES</term>
  4519. should be used only on attributes.
  4520. </p>
  4521. <div4 id="ENTITIES-facets">
  4522. <head>Constraining facets</head>
  4523. <facets/>
  4524. </div4>
  4525. </div3>
  4526.  
  4527. <div3 id="integer">
  4528. <head>integer</head>
  4529. <p>
  4530. <termdef id="dt-integer" term="integer" role='local'>
  4531. <term>integer</term> is
  4532. <termref def="dt-derived"/> from <dtref ref='decimal'/> by fixing the
  4533. value of <termref def="dt-fractionDigits"/> to be 0. This results in the standard
  4534. mathematical concept of the integer numbers. The
  4535. <termref def="dt-value-space"/> of <term>integer</term> is the infinite
  4536. set {...,-2,-1,0,1,2,...}.  The <termref def="dt-basetype"/> of
  4537. <term>integer</term> is <baseref/>.
  4538. </termdef>
  4539. </p>
  4540. <div4 id="integer-lexical-representation">
  4541. <head>Lexical representation</head>
  4542. <p>
  4543. <term>integer</term> has a lexical representation consisting of a finite-length sequence
  4544. of decimal digits (#x30-#x39) with an optional leading sign.  If the sign is omitted,
  4545. "+" is assumed.  For example: -1, 0, 12678967543233, +100000.
  4546. </p>
  4547. </div4>
  4548. <div4 id="integer-canonical-repr">
  4549. <head>Canonical representation</head>
  4550. <p>
  4551. The canonical representation for <term>integer</term> is defined
  4552. by prohibiting certain options from the
  4553. <specref ref="integer-lexical-representation"/>.  Specifically, the preceding optional "+" sign is prohibited and leading zeroes are prohibited.  
  4554. </p>
  4555. </div4>
  4556. <div4 id="integer-facets">
  4557. <head>Constraining facets</head>
  4558. <facets/>
  4559. </div4>
  4560. <div4 id="integer-derived-types">
  4561. <head>Derived datatypes</head>
  4562. <subtypes/>
  4563. </div4>
  4564. </div3>
  4565. <div3 id="nonPositiveInteger">
  4566. <head>nonPositiveInteger</head>
  4567. <p>
  4568. <termdef id="dt-nonPositiveInteger" term="nonPositiveInteger" role='local'>
  4569. <term>nonPositiveInteger</term> is <termref def="dt-derived"/> from
  4570. <dtref ref="integer"/> by setting the value of
  4571. <termref def="dt-maxInclusive"/> to be 0.  This results in the
  4572. standard mathematical concept of the non-positive integers.
  4573. The <termref def="dt-value-space"/> of <term>nonPositiveInteger</term>
  4574. is the infinite set {...,-2,-1,0}.  The <termref def="dt-basetype"/>
  4575. of <term>nonPositiveInteger</term> is <baseref/>.
  4576. </termdef>
  4577. </p>
  4578. <div4 id="nonPositiveInteger-lexical-representation">
  4579. <head>Lexical representation</head>
  4580. <p>
  4581. <term>nonPositiveInteger</term> has a lexical representation consisting
  4582. of a negative sign ("-") followed by a finite-length
  4583. sequence of decimal digits (#x30-#x39).  If the sequence of digits consists of all
  4584. zeros then the sign is optional.
  4585. For example: -1, 0, -12678967543233, -100000.
  4586. </p>
  4587. </div4>
  4588. <div4 id="nonPositiveInteger-canonical-repr">
  4589. <head>Canonical representation</head>
  4590. <p>
  4591. The canonical representation for <term>nonPositiveInteger</term> is defined
  4592. by prohibiting certain options from the
  4593. <specref ref="nonPositiveInteger-lexical-representation"/>.  Specifically, the
  4594. negative sign ("-") is required with the token "0" and leading zeroes are prohibited.  
  4595. </p>
  4596. </div4>
  4597. <div4 id="nonPositiveInteger-facets">
  4598. <head>Constraining facets</head>
  4599. <facets/>
  4600. </div4>
  4601. <div4 id="nonPositiveInteger-derived-types">
  4602. <head>Derived datatypes</head>
  4603. <subtypes/>
  4604. </div4>
  4605. </div3>
  4606. <div3 id="negativeInteger">
  4607. <head>negativeInteger</head>
  4608. <p>
  4609. <termdef id="dt-negativeInteger" term="negativeInteger" role='local'>
  4610. <term>negativeInteger</term> is <termref def="dt-derived"/> from
  4611. <dtref ref="nonPositiveInteger"/> by setting the value of
  4612. <termref def="dt-maxInclusive"/> to be -1.  This results in the
  4613. standard mathematical concept of the negative integers.  The
  4614. <termref def="dt-value-space"/> of <term>negativeInteger</term>
  4615. is the infinite set {...,-2,-1}.  The <termref def="dt-basetype"/>
  4616. of <term>negativeInteger</term>  is <baseref/>.
  4617. </termdef>
  4618. </p>
  4619. <div4 id="negativeInteger-lexical-representation">
  4620. <head>Lexical representation</head>
  4621. <p>
  4622. <term>negativeInteger</term> has a lexical representation consisting
  4623. of a negative sign ("-") followed by a finite-length
  4624. sequence of decimal digits (#x30-#x39).  For example: -1, -12678967543233, -100000.
  4625. </p>
  4626. </div4>
  4627. <div4 id="negativeInteger-canonical-repr">
  4628. <head>Canonical representation</head>
  4629. <p>
  4630. The canonical representation for <term>negativeInteger</term> is defined
  4631. by prohibiting certain options from the
  4632. <specref ref="negativeInteger-lexical-representation"/>.  Specifically,  leading zeroes are prohibited.  
  4633. </p>
  4634. </div4>
  4635. <div4 id="negativeInteger-facets">
  4636. <head>Constraining facets</head>
  4637. <facets/>
  4638. </div4>
  4639. </div3>
  4640. <div3 id="long">
  4641. <head>&long;</head>
  4642. <p>
  4643. <termdef id="dt-long" term="long" role='local'>
  4644. <term>&long;</term> is
  4645. <termref def="dt-derived"/> from <dtref ref="integer"/> by setting the
  4646. value of <termref def="dt-maxInclusive"/> to be 9223372036854775807
  4647. and <termref def="dt-minInclusive"/> to be -9223372036854775808.
  4648. The <termref def="dt-basetype"/> of <term>&long;</term> is
  4649. <baseref/>.
  4650. </termdef>
  4651. </p>
  4652. <div4 id="long-lexical-representation">
  4653. <head>Lexical representation</head>
  4654. <p>
  4655. <term>&long;</term> has a lexical representation consisting
  4656. of an optional sign followed by a finite-length
  4657. sequence of decimal digits (#x30-#x39).  If the sign is omitted, "+" is assumed.
  4658. For example: -1, 0,
  4659. 12678967543233, +100000.
  4660. </p>
  4661. </div4>
  4662. <div4 id="long-canonical-repr">
  4663. <head>Canonical representation</head>
  4664. <p>
  4665. The canonical representation for <term>long</term> is defined
  4666. by prohibiting certain options from the
  4667. <specref ref="long-lexical-representation"/>.  Specifically, the
  4668. the optional "+" sign is prohibited and leading zeroes are prohibited.
  4669. </p>
  4670. </div4>
  4671. <div4 id="long-facets">
  4672. <head>Constraining facets</head>
  4673. <facets/>
  4674. </div4>
  4675. <div4 id="long-derived-types">
  4676. <head>Derived datatypes</head>
  4677. <subtypes/>
  4678. </div4>
  4679. </div3>
  4680. <div3 id="int">
  4681. <head>∫</head>
  4682. <p>
  4683. <termdef id="dt-int" term="int" role='local'>
  4684. <term>∫</term>
  4685. is <termref def="dt-derived"/> from <dtref ref="long"/> by setting the
  4686. value of <termref def="dt-maxInclusive"/> to be 2147483647 and
  4687. <termref def="dt-minInclusive"/> to be -2147483648.  The
  4688. <termref def="dt-basetype"/> of <term>∫</term> is <baseref/>.
  4689. </termdef>
  4690. </p>
  4691. <div4 id="int-lexical-representation">
  4692. <head>Lexical representation</head>
  4693. <p>
  4694. <term>∫</term> has a lexical representation consisting
  4695. of an optional sign followed by a finite-length
  4696. sequence of decimal digits (#x30-#x39).  If the sign is omitted, "+" is assumed.
  4697. For example: -1, 0,
  4698. 126789675, +100000.
  4699. </p>
  4700. </div4>
  4701. <div4 id="int-canonical-repr">
  4702. <head>Canonical representation</head>
  4703. <p>
  4704. The canonical representation for <term>∫</term> is defined
  4705. by prohibiting certain options from the
  4706. <specref ref="int-lexical-representation"/>.  Specifically, the
  4707. the optional "+" sign is prohibited and leading zeroes are prohibited.
  4708. </p>
  4709. </div4>
  4710. <div4 id="int-facets">
  4711. <head>Constraining facets</head>
  4712. <facets/>
  4713. </div4>
  4714. <div4 id="int-derived-types">
  4715. <head>Derived datatypes</head>
  4716. <subtypes/>
  4717. </div4>
  4718. </div3>
  4719. <div3 id="short">
  4720. <head>&short;</head>
  4721. <p>
  4722. <termdef id="dt-short" term="short" role='local'>
  4723. <term>&short;</term> is
  4724. <termref def="dt-derived"/> from <dtref ref="int"/> by setting the
  4725. value of <termref def="dt-maxInclusive"/> to be 32767 and
  4726. <termref def="dt-minInclusive"/> to be -32768.  The
  4727. <termref def="dt-basetype"/> of <term>&short;</term> is
  4728. <baseref/>.
  4729. </termdef>
  4730. </p>
  4731. <div4 id="short-lexical-representation">
  4732. <head>Lexical representation</head>
  4733. <p>
  4734. <term>&short;</term> has a lexical representation consisting
  4735. of an optional sign followed by a finite-length sequence of decimal
  4736. digits (#x30-#x39).  If the sign is omitted, "+" is assumed.
  4737. For example: -1, 0, 12678, +10000.
  4738. </p>
  4739. </div4>
  4740. <div4 id="short-canonical-repr">
  4741. <head>Canonical representation</head>
  4742. <p>
  4743. The canonical representation for <term>&short;</term> is defined
  4744. by prohibiting certain options from the
  4745. <specref ref="short-lexical-representation"/>.  Specifically, the
  4746. the optional "+" sign is prohibited and leading zeroes are prohibited.
  4747. </p>
  4748. </div4>
  4749. <div4 id="short-facets">
  4750. <head>Constraining facets</head>
  4751. <facets/>
  4752. </div4>
  4753. <div4 id="short-derived-types">
  4754. <head>Derived datatypes</head>
  4755. <subtypes/>
  4756. </div4>
  4757. </div3>
  4758. <div3 id="byte">
  4759. <head>&byte;</head>
  4760. <p>
  4761. <termdef id="dt-byte" term="byte" role='local'>
  4762. <term>&byte;</term>
  4763. is <termref def="dt-derived"/> from <dtref ref="short"/>
  4764. by setting the value of <termref def="dt-maxInclusive"/> to be 127
  4765. and <termref def="dt-minInclusive"/> to be -128.
  4766. The <termref def="dt-basetype"/> of <term>&byte;</term> is
  4767. <baseref/>.
  4768. </termdef>
  4769. </p>
  4770. <div4 id="byte-lexical-representation">
  4771. <head>Lexical representation</head>
  4772. <p>
  4773. <term>&byte;</term> has a lexical representation consisting
  4774. of an optional sign followed by a finite-length
  4775. sequence of decimal digits (#x30-#x39).  If the sign is omitted, "+" is assumed.
  4776. For example: -1, 0,
  4777. 126, +100.
  4778. </p>
  4779. </div4>
  4780. <div4 id="byte-canonical-repr">
  4781. <head>Canonical representation</head>
  4782. <p>
  4783. The canonical representation for <term>&byte;</term> is defined
  4784. by prohibiting certain options from the
  4785. <specref ref="byte-lexical-representation"/>.  Specifically, the
  4786. the optional "+" sign is prohibited and leading zeroes are prohibited.
  4787. </p>
  4788. </div4>
  4789. <div4 id="byte-facets">
  4790. <head>Constraining facets</head>
  4791. <facets/>
  4792. </div4>
  4793. </div3>
  4794. <div3 id="nonNegativeInteger">
  4795. <head>nonNegativeInteger</head>
  4796. <p>
  4797. <termdef id="dt-nonNegativeInteger" term="nonNegativeInteger" role='local'>
  4798. <term>nonNegativeInteger</term> is <termref def="dt-derived"/> from
  4799. <dtref ref="integer"/> by setting the value of
  4800. <termref def="dt-minInclusive"/> to be 0.  This results in the
  4801. standard mathematical concept of the non-negative integers. The
  4802. <termref def="dt-value-space"/> of <term>nonNegativeInteger</term>
  4803. is the infinite set {0,1,2,...}.  The <termref def="dt-basetype"/> of
  4804. <term>nonNegativeInteger</term> is <baseref/>.
  4805. </termdef>
  4806. </p>
  4807. <div4 id="nonNegativeInteger-lexical-representation">
  4808. <head>Lexical representation</head>
  4809. <p>
  4810. <term>nonNegativeInteger</term> has a lexical representation consisting
  4811. of an optional sign followed by a finite-length
  4812. sequence of decimal digits (#x30-#x39).  If the sign is omitted, "+" is assumed.
  4813. For example:
  4814. 1, 0, 12678967543233, +100000.
  4815. </p>
  4816. </div4>
  4817. <div4 id="nonNegativeInteger-canonical-repr">
  4818. <head>Canonical representation</head>
  4819. <p>
  4820. The canonical representation for <term>nonNegativeInteger</term> is defined
  4821. by prohibiting certain options from the
  4822. <specref ref="nonNegativeInteger-lexical-representation"/>.  Specifically, the
  4823. the optional "+" sign is prohibited and leading zeroes are prohibited.
  4824. </p>
  4825. </div4>
  4826. <div4 id="nonNegativeInteger-facets">
  4827. <head>Constraining facets</head>
  4828. <facets/>
  4829. </div4>
  4830. <div4 id="nonNegativeInteger-derived-types">
  4831. <head>Derived datatypes</head>
  4832. <subtypes/>
  4833. </div4>
  4834. </div3>
  4835. <div3 id="unsignedLong">
  4836. <head>&unsignedLong;</head>
  4837. <p>
  4838. <termdef id="dt-unsignedLong" term="unsignedLong" role='local'>
  4839. <term>&unsignedLong;</term> is <termref def="dt-derived"/> from
  4840. <dtref ref="nonNegativeInteger"/> by setting the value of
  4841. <termref def="dt-maxInclusive"/> to be 18446744073709551615.
  4842. The <termref def="dt-basetype"/> of <term>&unsignedLong;</term> is
  4843. <baseref/>.
  4844. </termdef>
  4845. </p>
  4846. <div4 id="unsignedLong-lexical-representation">
  4847. <head>Lexical representation</head>
  4848. <p>
  4849. <term>&unsignedLong;</term> has a lexical representation consisting
  4850. of a finite-length sequence of decimal digits (#x30-#x39).
  4851. For example: 0,
  4852. 12678967543233, 100000.
  4853. </p>
  4854. </div4>
  4855. <div4 id="unsignedLong-canonical-repr">
  4856. <head>Canonical representation</head>
  4857. <p>
  4858. The canonical representation for <term>unsignedLong</term> is defined
  4859. by prohibiting certain options from the
  4860. <specref ref="unsignedLong-lexical-representation"/>.  Specifically, 
  4861. leading zeroes are prohibited.
  4862. </p>
  4863. </div4>
  4864. <div4 id="unsignedLong-facets">
  4865. <head>Constraining facets</head>
  4866. <facets/>
  4867. </div4>
  4868. <div4 id="unsignedLong-derived-types">
  4869. <head>Derived datatypes</head>
  4870. <subtypes/>
  4871. </div4>
  4872. </div3>
  4873. <div3 id="unsignedInt">
  4874. <head>&unsignedInt;</head>
  4875. <p>
  4876. <termdef id="dt-unsignedInt" term="unsignedInt" role='local'>
  4877. <term>&unsignedInt;</term> is <termref def="dt-derived"/> from
  4878. <dtref ref="unsignedLong"/> by setting the value of
  4879. <termref def="dt-maxInclusive"/> to be 4294967295.  The
  4880. <termref def="dt-basetype"/> of <term>&unsignedInt;</term> is
  4881. <baseref/>.
  4882. </termdef>
  4883. </p>
  4884. <div4 id="unsignedInt-lexical-representation">
  4885. <head>Lexical representation</head>
  4886. <p>
  4887. <term>&unsignedInt;</term> has a lexical representation consisting
  4888. of a finite-length
  4889. sequence of decimal digits (#x30-#x39).  For example: 0,
  4890. 1267896754, 100000.
  4891. </p>
  4892. </div4>
  4893. <div4 id="unsignedInt-canonical-repr">
  4894. <head>Canonical representation</head>
  4895. <p>
  4896. The canonical representation for <term>unsignedInt</term> is defined
  4897. by prohibiting certain options from the
  4898. <specref ref="unsignedInt-lexical-representation"/>.  Specifically, 
  4899. leading zeroes are prohibited.
  4900. </p>
  4901. </div4>
  4902. <div4 id="unsignedInt-facets">
  4903. <head>Constraining facets</head>
  4904. <facets/>
  4905. </div4>
  4906. <div4 id="unsignedInt-derived-types">
  4907. <head>Derived datatypes</head>
  4908. <subtypes/>
  4909. </div4>
  4910. </div3>
  4911. <div3 id="unsignedShort">
  4912. <head>&unsignedShort;</head>
  4913. <p>
  4914. <termdef id="dt-unsignedShort" term="unsignedShort" role='local'>
  4915. <term>&unsignedShort;</term> is <termref def="dt-derived"/> from
  4916. <dtref ref="unsignedInt"/> by setting the value of
  4917. <termref def="dt-maxInclusive"/> to be 65535.  The
  4918. <termref def="dt-basetype"/> of <term>&unsignedShort;</term> is
  4919. <baseref/>.
  4920. </termdef>
  4921. </p>
  4922. <div4 id="unsignedShort-lexical-representation">
  4923. <head>Lexical representation</head>
  4924. <p>
  4925. <term>&unsignedShort;</term>  has a lexical representation consisting
  4926. of a finite-length
  4927. sequence of decimal digits (#x30-#x39).
  4928. For example: 0,
  4929. 12678, 10000.
  4930. </p>
  4931. </div4>
  4932. <div4 id="unsignedShort-canonical-repr">
  4933. <head>Canonical representation</head>
  4934. <p>
  4935. The canonical representation for <term>unsignedShort</term> is defined
  4936. by prohibiting certain options from the
  4937. <specref ref="unsignedShort-lexical-representation"/>.  Specifically, the
  4938. leading zeroes are prohibited.
  4939. </p>
  4940. </div4>
  4941. <div4 id="unsingedShort-facets">
  4942. <head>Constraining facets</head>
  4943. <facets/>
  4944. </div4>
  4945. <div4 id="unsignedShort-derived-types">
  4946. <head>Derived datatypes</head>
  4947. <subtypes/>
  4948. </div4>
  4949. </div3>
  4950. <div3 id="unsignedByte">
  4951. <head>&unsignedByte;</head>
  4952. <p>
  4953. <termdef id="dt-unsignedByte" term="unsignedByte" role='local'>
  4954. <term>&unsignedByte;</term> is <termref def="dt-derived"/> from
  4955. <dtref ref="unsignedShort"/> by setting the value of
  4956. <termref def="dt-maxInclusive"/> to be 255. The
  4957. <termref def="dt-basetype"/> of <term>&unsignedByte;</term> is
  4958. <baseref/>.
  4959. </termdef>
  4960. </p>
  4961. <div4 id="unsignedByte-lexical-representation">
  4962. <head>Lexical representation</head>
  4963. <p>
  4964. <term>&unsignedByte;</term>  has a lexical representation consisting
  4965. of a finite-length
  4966. sequence of decimal digits (#x30-#x39).
  4967. For example: 0,
  4968. 126, 100.
  4969. </p>
  4970. </div4>
  4971. <div4 id="unsignedByte-canonical-repr">
  4972. <head>Canonical representation</head>
  4973. <p>
  4974. The canonical representation for <term>unsignedByte</term> is defined
  4975. by prohibiting certain options from the
  4976. <specref ref="unsignedByte-lexical-representation"/>.  Specifically, 
  4977. leading zeroes are prohibited.
  4978. </p>
  4979. </div4>
  4980. <div4 id="unisngedByte-facets">
  4981. <head>Constraining facets</head>
  4982. <facets/>
  4983. </div4>
  4984. </div3>
  4985. <div3 id="positiveInteger">
  4986. <head>positiveInteger</head>
  4987. <p>
  4988. <termdef id="dt-positiveInteger" term="positiveInteger" role='local'>
  4989. <term>positiveInteger</term> is <termref def="dt-derived"/> from
  4990. <dtref ref="nonNegativeInteger"/> by setting the value of
  4991. <termref def="dt-minInclusive"/> to be 1. This results in the standard
  4992. mathematical concept of the positive integer numbers.  
  4993. The <termref def="dt-value-space"/> of <term>positiveInteger</term>
  4994. is the infinite set {1,2,...}.  The <termref def="dt-basetype"/> of
  4995. <term>positiveInteger</term> is <baseref/>.
  4996. </termdef>
  4997. </p>
  4998. <div4 id="positiveInteger-lexical-representation">
  4999. <head>Lexical representation</head>
  5000. <p>
  5001. <term>positiveInteger</term> has a lexical representation consisting
  5002. of an optional positive sign ("+") followed by a finite-length
  5003. sequence of decimal digits (#x30-#x39).
  5004. For example: 1, 12678967543233, +100000.
  5005. </p>
  5006. </div4>
  5007. <div4 id="positiveInteger-canonical-repr">
  5008. <head>Canonical representation</head>
  5009. <p>
  5010. The canonical representation for <term>positiveInteger</term> is defined
  5011. by prohibiting certain options from the
  5012. <specref ref="positiveInteger-lexical-representation"/>.  Specifically, the
  5013. optional "+" sign is prohibited and leading zeroes are prohibited.
  5014. </p>
  5015. </div4>
  5016. <div4 id="positiveInteger-facets">
  5017. <head>Constraining facets</head>
  5018. <facets/>
  5019. </div4>
  5020. </div3>
  5021.  
  5022. </div2>
  5023. </div1>
  5024.  
  5025. <div1 id="datatype-components">
  5026. <head>Datatype components</head>
  5027. <p>
  5028. The following sections provide full details on the properties and
  5029. significance of each kind of schema component involved in datatype
  5030. definitions. For each property, the kinds of values it is allowed to have is
  5031. specified.  Any property not identified as optional is required to
  5032. be present; optional properties which are not present have
  5033. <xspecref href='&xsdl;#key-null'>absent</xspecref> as their value.
  5034. Any property identified as a having a set, subset or <termref def='dt-list'/>
  5035. value may have an empty value unless this is explicitly ruled out: this is
  5036. not the same as <xspecref href='&xsdl;#key-null'>absent</xspecref>.
  5037. Any property value identified as a superset or a subset of some set may
  5038. be equal to that set, unless a proper superset or subset is explicitly
  5039. called for.
  5040. </p>
  5041.  
  5042. <p>
  5043. For more information on the notion of datatype (schema) components,
  5044. see <xspecref href="&xsdl;#components">Schema Component Details</xspecref>
  5045. of <bibref ref="structural-schemas"/>.
  5046. </p>
  5047.  
  5048. <div2 id="rf-defn">
  5049. <head>Simple Type Definition</head>
  5050. <p>
  5051. Simple Type definitions provide for:
  5052. </p>
  5053. <ulist>
  5054. <item>
  5055. <p>
  5056. Establishing the <termref def="dt-value-space"/> and <termref def="dt-lexical-space"/>
  5057. of a datatype, through
  5058. the combined set of <termref def="dt-constraining-facet"/>s specified
  5059. in the definition;
  5060. </p>
  5061. </item>
  5062. <item>
  5063. <p>
  5064. Attaching a unique name (actually a <dtref ref="QName"/>) to the
  5065. <termref def="dt-value-space"/> and <termref def="dt-lexical-space"/>.
  5066. </p>
  5067. </item>
  5068. </ulist>
  5069.  
  5070. <div3 id='dc-defn'>
  5071. <head>The Simple Type Definition Schema Component</head>
  5072. <p>
  5073. The Simple Type Definition schema component has the following properties:
  5074. </p>
  5075. <compdef name="Simple Type Definition" ref="datatype">
  5076. <proplist>
  5077. <propdef id="defn-name" name="name">
  5078. Optional.  An NCName as defined by
  5079. <bibref ref="XMLNS"/>.
  5080. </propdef>
  5081. <propdef id="defn-target-namespace" name="target namespace">
  5082. Either <xspecref href="&xsdl;#key-null">absent</xspecref> or a
  5083. namespace name, as defined in <bibref ref="XMLNS"/>.
  5084. </propdef>
  5085. <propdef id="defn-variety" name="variety">
  5086. One of {<pt>atomic</pt>, <pt>list</pt>, <pt>union</pt>}. Depending on the
  5087. value of <propref ref="defn-variety"/>, further properties are defined as follows:
  5088. <glist>
  5089. <gitem>
  5090. <label>atomic</label>
  5091. <def>
  5092. <proplist>
  5093. <propdef id="defn-primitive" name="primitive type definition">
  5094. A <termref def="dt-built-in"/> <termref def="dt-primitive"/>
  5095. datatype definition (or the <xtermref href="&xsdl;#simple-ur-type-itself">
  5096. simple ur-type definition</xtermref>).
  5097. </propdef>
  5098. </proplist>
  5099. </def>
  5100. </gitem>
  5101. <gitem>
  5102. <label>list</label>
  5103. <def>
  5104.  
  5105. <proplist>
  5106. <propdef id="defn-itemType" name="item type definition">
  5107. An <termref def="dt-atomic"/> or <termref def="dt-union"/> simple type definition.
  5108. </propdef>
  5109. </proplist>
  5110. </def>
  5111. </gitem>
  5112. <gitem>
  5113. <label>union</label>
  5114. <def>
  5115. <proplist>
  5116. <propdef id="defn-memberTypes" name="member type definitions">
  5117. A non-empty sequence of simple type definitions.
  5118. </propdef>
  5119. </proplist>
  5120. </def>
  5121. </gitem>
  5122. </glist>
  5123. </propdef>    
  5124. <propdef id="defn-facets" name="facets">
  5125. A possibly empty set of <specref ref="facets"/>.
  5126. </propdef>
  5127. <propdef id="defn-fund-facets" name="fundamental facets">
  5128. A set of <specref ref="fundamental-facets"/>
  5129. </propdef>
  5130. <propdef id="defn-basetype" name="base type definition">
  5131. If the datatype has been <termref def="dt-derived"/> by
  5132. <termref def='dt-restriction'/> then the <compref ref='dc-defn'/> component
  5133. from which it is <termref def="dt-derived"/>, otherwise
  5134. the <specref ref='anySimpleType-component'/>.
  5135. </propdef>
  5136. <propdef id="defn-final" name="final">
  5137. A  subset of <emph>{restriction, list, union}</emph>.
  5138. </propdef>
  5139. <propdef id="defn-annotation" name="annotation">
  5140. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  5141. </propdef>
  5142. </proplist>
  5143. </compdef>
  5144. <p>
  5145. Datatypes are identified by their <propref ref="defn-name"/>
  5146. and <propref ref="defn-target-namespace"/>.  Except
  5147. for anonymous datatypes (those with no <propref ref="defn-name"/>),
  5148. datatype definitions <termref def="dt-must"/> be uniquely identified
  5149. within a schema.
  5150. </p>
  5151. <p>
  5152. If <propref ref="defn-variety"/> is <termref def="dt-atomic"/>
  5153. then the <termref def="dt-value-space"/> of the datatype defined will
  5154. be a subset of the <termref def="dt-value-space"/> of
  5155. <propref ref="defn-basetype"/> (which is a subset of the
  5156. <termref def="dt-value-space"/> of <propref ref="defn-primitive"/>).
  5157. If <propref ref="defn-variety"/> is <termref def="dt-list"/>
  5158. then the <termref def="dt-value-space"/> of the datatype defined will
  5159. be the set of finite-length sequence of values from the
  5160. <termref def="dt-value-space"/> of <propref ref="defn-itemType"/>.
  5161. If <propref ref="defn-variety"/> is <termref def="dt-union"/> then the
  5162. <termref def="dt-value-space"/> of the datatype defined will be the
  5163. union of the <termref def="dt-value-space"/>s of each datatype in
  5164. <propref ref="defn-memberTypes"/>.
  5165. </p>
  5166. <p>
  5167. If <propref ref="defn-variety"/> is <termref def="dt-atomic"/>
  5168. then the <propref ref="defn-variety"/> of <propref ref="defn-basetype"/> 
  5169. must be <termref def="dt-atomic"/>.
  5170. If <propref ref="defn-variety"/> is <termref def="dt-list"/>
  5171. then the <propref ref="defn-variety"/> of <propref ref="defn-itemType"/>
  5172. must be either <termref def="dt-atomic"/> or <termref def="dt-union"/>.
  5173. If <propref ref="defn-variety"/> is <termref def="dt-union"/>
  5174. then
  5175. <propref ref="defn-memberTypes"/> must be a list of datatype definitions.
  5176. </p>
  5177. <p>
  5178. The value of <propref ref="defn-facets"/> consists of the set of
  5179. <termref def="dt-facet"/>s specified directly in the datatype definition
  5180. unioned with the possibly empty set of <propref ref="defn-facets"/> of
  5181. <propref ref="defn-basetype"/>.
  5182. </p>
  5183. <p>
  5184. The value of <propref ref="defn-fund-facets"/> consists of the set of
  5185. <termref def="dt-fundamental-facet"/>s and their values.
  5186. </p>
  5187. <p>
  5188. If <propref ref='defn-final'/> is the empty set then the type can be used
  5189. in deriving other types; the explicit values <emph>restriction</emph>,
  5190. <emph>list</emph> and <emph>union</emph> prevent further derivations
  5191. by <termref def='dt-restriction'/>, <termref def='dt-list'/> and
  5192. <termref def='dt-union'/> respectively.
  5193. </p>
  5194. </div3>
  5195.  
  5196. <div3 id='xr-defn'>
  5197. <head>XML Representation of Simple Type Definition Schema Components</head>
  5198.  
  5199. <p>
  5200. The XML representation for a <compref ref="dc-defn"/> schema component
  5201. is a <eltref ref="simpleType"/> element information item. The
  5202. correspondences between the properties of the information item and
  5203. properties of the component are as follows:
  5204. </p>
  5205. <reprdef eltname="simpleType">
  5206.  <reprelt eltname="simpleType"/>
  5207. <reprcomp abstract="Datatype Definition" ref="dc-defn">
  5208. <propmap name="defn-name">
  5209. The &v-value; of the <code>name</code> &i-attribute;, if present,
  5210. otherwise <xtermref href="&xsdl;#key-null">null</xtermref>
  5211. </propmap>
  5212. <propmap name="defn-final">
  5213. A set corresponding to the &v-value; of the
  5214. <code>final</code> &i-attribute;, if present, otherwise of the &v-value; of the
  5215. <code>finalDefault</code> &i-attribute; the ancestor
  5216. <xtermref href="&xsdl;#element-schema">schema</xtermref>
  5217. element information item, if present, otherwise the empty string, as follows:
  5218.    <glist>
  5219.     <gitem>
  5220.      <label>the empty string</label>
  5221.      <def>
  5222. <p>the empty set;</p>
  5223.      </def>
  5224.     </gitem>
  5225.     <gitem>
  5226.      <label>
  5227.       <code>#all</code>
  5228.      </label>
  5229.      <def>
  5230.       <p><emph>{restriction, list, union}</emph>;</p>
  5231.      </def>
  5232.     </gitem>
  5233.     <gitem>
  5234.      <label><emph>otherwise</emph></label>
  5235.      <def>
  5236.       <p>a set with members drawn from the set above, each being present or
  5237. absent depending on whether the string contains an equivalently named
  5238. space-delimited substring.</p>
  5239.       <note>
  5240.        <p>Although the <code>finalDefault</code> &i-attribute; of
  5241.        <xtermref href="&xsdl;#element-schema">schema</xtermref> may include
  5242.        values other than
  5243.        <pt>restriction</pt>, <pt>list</pt> or <pt>union</pt>, those values
  5244.        are ignored in the determination of <propref ref="defn-final"/>
  5245.        </p>
  5246.       </note>
  5247.      </def>
  5248.     </gitem>
  5249.    </glist>
  5250. </propmap>
  5251. <propmap name="defn-target-namespace">
  5252. The &v-value; of the <code>targetNamespace</code> &i-attribute;
  5253. of the parent <code>schema</code> element information item.
  5254. </propmap>
  5255. <propmap name="defn-annotation">
  5256. The annotation corresponding to the <eltref ref="annotation"/>
  5257. element information item in the &i-children;, if present, otherwise
  5258. <xspecref href="&xsdl;#key-null">null</xspecref>
  5259. </propmap>
  5260. </reprcomp>
  5261. </reprdef>
  5262. <p>
  5263. A <termref def="dt-derived"/> datatype can be <termref def="dt-derived"/>
  5264. from a <termref def="dt-primitive"/> datatype or another
  5265. <termref def="dt-derived"/> datatype by one of three means:
  5266. by <emph>restriction</emph>, by <emph>list</emph> or by <emph>union</emph>.
  5267. </p>
  5268.  
  5269. <div4 id="derivation-by-restriction">
  5270. <head>Derivation by restriction</head>
  5271. <reprdef eltname="restriction">
  5272. <reprelt eltname="restriction"/>
  5273. <reprcomp abstract="Simple Type Definition" ref="dc-defn">
  5274. <propmap name="defn-variety">
  5275. The &v-value; of <propref ref="defn-variety"/> of <propref ref="defn-basetype"/>
  5276. </propmap>
  5277. <propmap name="defn-facets">
  5278. The union of the set of <specref ref='facets'/> components 
  5279. resolved to by the facet &i-children; merged with <propref ref='defn-facets'/>
  5280. from <propref ref='defn-basetype'/>, subject to the Facet Restriction Valid
  5281. constraints specified in <specref ref='facets'/>.
  5282. </propmap>
  5283. <propmap name="defn-basetype">
  5284. The <compref ref='dc-defn'/> component resolved to by the &v-value; of the
  5285. <code>base</code> &i-attribute; or the <eltref ref='simpleType'/> &i-children;,
  5286. whichever is present.
  5287. </propmap>
  5288. </reprcomp>
  5289. </reprdef>
  5290.  
  5291. <note role="example">
  5292. <p>
  5293. An electronic commerce schema might define a datatype called
  5294. <emph>Sku</emph> (the barcode number that appears on products) from the
  5295. <termref def="dt-built-in"/> datatype <dtref ref="string"/> by
  5296. supplying a value for the <termref def="dt-pattern"/> facet.
  5297. </p>
  5298. <eg><![CDATA[<simpleType name='Sku'>
  5299.     <restriction base='string'>
  5300.       <pattern value='\d{3}-[A-Z]{2}'/>
  5301.     </restriction>
  5302. </simpleType>]]></eg>
  5303. <p>
  5304. In this case, <emph>Sku</emph> is the name of the new
  5305. <termref def="dt-user-derived"/> datatype, <dtref ref="string"/> is
  5306. its <termref def="dt-basetype"/> and <termref def="dt-pattern"/>
  5307. is the facet.
  5308. </p>
  5309. </note>
  5310.  
  5311. </div4>
  5312.  
  5313. <div4 id="derivation-by-list">
  5314. <head>Derivation by list</head>
  5315. <reprdef eltname="list">
  5316.  <reprelt eltname="list"/>
  5317. <reprcomp abstract="Simple Type Definition" ref="dc-defn">
  5318. <propmap name="defn-variety">
  5319. list
  5320. </propmap>
  5321. <propmap name="defn-itemType">
  5322. The <compref ref='dc-defn'/> component resolved to by the &v-value; of the
  5323. <code>itemType</code> &i-attribute;
  5324. or the <eltref ref='simpleType'/> &i-children;,
  5325. whichever is present.
  5326. </propmap>
  5327. </reprcomp>
  5328. </reprdef>
  5329.  
  5330. <p>
  5331. A <termref def="dt-list"/> datatype must be <termref def="dt-derived"/>
  5332. from an <termref def="dt-atomic"/> or a <termref def="dt-union"/> datatype,
  5333. known as the
  5334. <termref def="dt-itemType"/> of the <termref def="dt-list"/> datatype.
  5335. This yields a datatype whose <termref def="dt-value-space"/> is composed of
  5336. finite-length sequences of values from the <termref def="dt-value-space"/> of the
  5337. <termref def="dt-itemType"/> and whose <termref def="dt-lexical-space"/> is
  5338. composed of white space separated lists of literals of the
  5339. <termref def="dt-itemType"/>.
  5340. </p>
  5341. <note role="example">
  5342. <p>
  5343. A system might want to store lists of floating point values. 
  5344. </p>
  5345. <eg><![CDATA[<simpleType name='listOfFloat'>
  5346.   <list itemType='float'/>
  5347. </simpleType>
  5348. ]]></eg>
  5349. <p>
  5350. In this case, <emph>listOfFloat</emph> is the name of the new
  5351. <termref def="dt-user-derived"/> datatype, <dtref ref="float"/> is its
  5352. <termref def="dt-itemType"/> and <termref def="dt-list"/> is the
  5353. derivation method.
  5354. </p>
  5355. </note>
  5356. <p>
  5357. As mentioned in <specref ref="list-datatypes"/>,
  5358. when a datatype is <termref def="dt-derived"/> from a
  5359. <termref def="dt-list"/> datatype, the following
  5360. <termref def="dt-constraining-facet"/>s can be used:
  5361. </p>
  5362. <ulist>
  5363. <item><p><termref def="dt-length"/></p></item>
  5364. <item><p><termref def="dt-maxLength"/></p></item>
  5365. <item><p><termref def="dt-minLength"/></p></item>
  5366. <item><p><termref def="dt-enumeration"/></p></item>
  5367. <item><p><termref def="dt-pattern"/></p></item>
  5368. <item><p><termref def="dt-whiteSpace"/></p></item>
  5369. </ulist>
  5370. <p>
  5371. regardless of the <termref def="dt-constraining-facet"/>s that are applicable
  5372. to the <termref def="dt-atomic"/> datatype that serves as the
  5373. <termref def="dt-itemType"/> of the <termref def="dt-list"/>.
  5374. </p>
  5375. <p>
  5376. For each of <termref def='dt-length'/>, <termref def='dt-maxLength'/>
  5377. and <termref def='dt-minLength'/>, the
  5378. <emph>unit of length</emph> is measured in number of list items.
  5379. The value of <termref def='dt-whiteSpace'/>
  5380. is fixed to the value <emph>collapse</emph>.</p>
  5381. </div4>
  5382.  
  5383. <div4 id="derivation-by-union">
  5384. <head>Derivation by union</head>
  5385. <reprdef eltname="union">
  5386.  <reprelt eltname="union"/>
  5387. <reprcomp abstract="Simple Type Definition" ref="dc-defn">
  5388. <propmap name="defn-variety">
  5389. union
  5390. </propmap>
  5391. <propmap name="defn-memberTypes">
  5392. The sequence of <compref ref='dc-defn'/> components resolved to by the
  5393. items in the &v-value; of the
  5394. <code>memberTypes</code> &i-attribute;, if any,
  5395. in order, followed by the <compref ref='dc-defn'/> components resolved to by the
  5396. <eltref ref='simpleType'/> &i-children;, if any, in order.
  5397. If <propref ref='defn-variety'/> is <emph>union</emph> for
  5398. any <compref ref='dc-defn'/> components resolved to above, then
  5399. the that <compref ref='dc-defn'/> is replaced by its
  5400. <propref ref='defn-memberTypes'/>.
  5401. </propmap>
  5402. </reprcomp>
  5403. </reprdef>
  5404.  
  5405. <p>
  5406. A <termref def="dt-union"/> datatype can be <termref def="dt-derived"/>
  5407. from one or more <termref def="dt-atomic"/>, <termref def="dt-list"/> or
  5408. other <termref def="dt-union"/> datatypes, known as the <termref def="dt-memberTypes"/>
  5409. of that <termref def="dt-union"/> datatype.
  5410. </p>
  5411. <note role="example">
  5412. <p>
  5413. As an example, taken from a typical display oriented text markup language,
  5414. one might want to express font sizes as an integer between 8 and 72, or with
  5415. one of the tokens "small", "medium" or "large".  The <termref def="dt-union"/>
  5416. type definition below would accomplish that.
  5417. </p>
  5418. <eg><![CDATA[
  5419. <xsd:attribute name="size">
  5420.   <xsd:simpleType>
  5421.     <xsd:union>
  5422.       <xsd:simpleType>
  5423.         <xsd:restriction base="xsd:positiveInteger">
  5424.           <xsd:minInclusive value="8"/>
  5425.           <xsd:maxInclusive value="72"/>
  5426.         </xsd:restriction>
  5427.       </xsd:simpleType>
  5428.       <xsd:simpleType>
  5429.         <xsd:restriction base="xsd:NMTOKEN">
  5430.           <xsd:enumeration value="small"/>
  5431.           <xsd:enumeration value="medium"/>
  5432.           <xsd:enumeration value="large"/>
  5433.         </xsd:restriction>
  5434.       </xsd:simpleType>
  5435.     </xsd:union>
  5436.   </xsd:simpleType>
  5437. </xsd:attribute>
  5438. ]]></eg>
  5439. <eg><![CDATA[
  5440. <p>
  5441. <font size='large'>A header</font>
  5442. </p>
  5443. <p>
  5444. <font size='12'>this is a test</font>
  5445. </p>
  5446. ]]></eg>
  5447. </note>
  5448. <p>
  5449. As mentioned in <specref ref="union-datatypes"/>,
  5450. when a datatype is <termref def="dt-derived"/> from a
  5451. <termref def="dt-union"/> datatype, the only following
  5452. <termref def="dt-constraining-facet"/>s can be used:
  5453. </p>
  5454. <ulist>
  5455. <item><p><termref def="dt-pattern"/></p></item>
  5456. <item><p><termref def="dt-enumeration"/></p></item>
  5457. </ulist>
  5458. <p>
  5459. regardless of the <termref def="dt-constraining-facet"/>s that are
  5460. applicable to the datatypes that participate in the <termref def="dt-union"/>
  5461. </p>
  5462. </div4>
  5463. </div3>
  5464.  
  5465. <div3 id='defn-rep-constr'>
  5466. <head>Constraints on XML Representation of Simple Type Definition</head>
  5467.  
  5468. <constraintnote type="src" id="src-single-facet-value">
  5469. <head>Single Facet Value</head>
  5470. <p>
  5471. Unless otherwise specifically allowed by this specification
  5472. (<specref ref='src-multiple-patterns'/> and
  5473. <specref ref='src-multiple-enumerations'/>) any given
  5474. <termref def='dt-constraining-facet'/> can only be specifed once within
  5475. a single derivation step.
  5476. </p>
  5477. </constraintnote>
  5478.  
  5479. <constraintnote type="src" id="src-list-itemType-or-simpleType">
  5480. <head>itemType attribute or simpleType child</head>
  5481. <p>
  5482. Either the <code>itemType</code> &i-attribute; or the
  5483. <eltref ref='simpleType'/> &i-child; of the <eltref ref='list'/> element
  5484. must be present, but not both.
  5485. </p>
  5486. </constraintnote>
  5487.  
  5488. <constraintnote type="src" id="src-restriction-base-or-simpleType">
  5489. <head>base attribute or simpleType child</head>
  5490. <p>
  5491. Either the <code>base</code> &i-attribute; or the
  5492. <code>simpleType</code> &i-child; of the <eltref ref='restriction'/>
  5493. element must be present, but not both.
  5494. </p>
  5495. </constraintnote>
  5496.  
  5497. <constraintnote type="src" id="src-union-memberTypes-or-simpleTypes">
  5498. <head>memberTypes attribute or simpleType children</head>
  5499. <p>
  5500. Either the <code>memberTypes</code> &i-attribute; of the <eltref ref='union'/>
  5501. element must be non-empty or
  5502. there must be at least one <code>simpleType</code> &i-child;.
  5503. </p>
  5504. </constraintnote>
  5505. </div3>
  5506.  
  5507. <div3 id='defn-validation-rules'>
  5508. <head>Simple Type Definition Validation Rules</head>
  5509.  
  5510. <constraintnote type="cvc" id="cvc-facet-valid">
  5511. <head>Facet Valid</head>
  5512. <p>
  5513. A value in a <termref def="dt-value-space"/> is facet-valid with
  5514. respect to a <termref def="dt-constraining-facet"/> component if:
  5515. </p>
  5516. <olist>
  5517. <item>
  5518. <p>
  5519. the value is facet-valid with respect to the particular
  5520. <termref def="dt-constraining-facet"/> as specified below.
  5521. </p>
  5522. </item>
  5523. </olist>
  5524. </constraintnote>
  5525.  
  5526. <constraintnote type="cvc" id="cvc-datatype-valid">
  5527. <head>Datatype Valid</head>
  5528. <p>
  5529. A string is datatype-valid with respect to a datatype definition if:
  5530. </p>
  5531. <olist>
  5532.     <item>
  5533.         <p>
  5534.         it <termref def="dt-match"/>es a literal in the
  5535.         <termref def="dt-lexical-space"/> of the datatype, determined as follows:
  5536.         </p>
  5537.         <olist>
  5538.             <item>
  5539.                 <p>
  5540.                 if <termref def='dt-pattern'/> is a member of <propref ref='defn-facets'/>,
  5541.                 then the string must be <specref ref='cvc-pattern-valid'/>;
  5542.                 </p>
  5543.             </item>
  5544.             <item>
  5545.                 <p>
  5546.                 if <termref def='dt-pattern'/> is not a member of <propref ref='defn-facets'/>,
  5547.                 then
  5548.                 </p>
  5549.                 <olist>
  5550.                     <item>
  5551.                         <p>
  5552.                         if <propref ref="defn-variety"/> is <termref def="dt-atomic"/> then
  5553.                         the string must <termref def="dt-match"/> a literal in the
  5554.                         <termref def="dt-lexical-space"/> of <propref ref="defn-basetype"/>
  5555.                         </p>
  5556.                     </item>
  5557.                     <item>
  5558.                         <p>
  5559.                         if <propref ref="defn-variety"/> is <termref def="dt-list"/> then
  5560.                         the string must be a sequence of white space separated tokens, each of
  5561.                         which <termref def="dt-match"/>es a literal in the
  5562.                         <termref def="dt-lexical-space"/> of <propref ref="defn-itemType"/>
  5563.                         </p>
  5564.                     </item>
  5565.                     <item>
  5566.                         <p>
  5567.                         if <propref ref="defn-variety"/> is <termref def="dt-union"/> then
  5568.                         the string must <termref def="dt-match"/> a literal in the
  5569.                         <termref def="dt-lexical-space"/> of at least one member of
  5570.                         <propref ref="defn-memberTypes"/>
  5571.                         </p>
  5572.                     </item>
  5573.                 </olist>
  5574.             </item>
  5575.         </olist>
  5576.     </item>
  5577.     <item>
  5578.         <p>
  5579.         the value denoted by the literal <termref def="dt-match"/>ed in the previous step
  5580.         is a member of the <termref def="dt-value-space"/> of the datatype, as determined
  5581.         by it being <specref ref="cvc-facet-valid"/>
  5582.         with respect to each member of <propref ref="defn-facets"/> (except
  5583.         for <termref def='dt-pattern'/>).
  5584.         </p>
  5585.     </item>
  5586. </olist>
  5587. </constraintnote>
  5588. </div3>
  5589.  
  5590. <div3 id='defn-coss'>
  5591. <head>Constraints on Simple Type Definition Schema Components</head>
  5592.  
  5593. <constraintnote type="cos" id="cos-applicable-facets">
  5594. <head>applicable facets</head>
  5595.  
  5596. <p>
  5597. The <termref def="dt-constraining-facet"/>s which are allowed
  5598. to be members of <propref ref="defn-facets"/> are dependent on
  5599. <propref ref="defn-basetype"/> as specified in the following table:
  5600. </p>
  5601. <applicable-facets/>
  5602. </constraintnote>
  5603.  
  5604. <constraintnote type="cos" id="cos-list-of-atomic">
  5605. <head>list of atomic</head>
  5606. <p>
  5607. If <propref ref="defn-variety"/> is <termref def="dt-list"/>, then
  5608. the <propref ref="defn-variety"/> of <propref ref="defn-itemType"/>
  5609.  <termref def="dt-must"/> be <termref def="dt-atomic"/> or
  5610. <termref def="dt-union"/>.
  5611. </p>
  5612. </constraintnote>
  5613.  
  5614. <constraintnote type="cos" id="cos-no-circular-unions">
  5615. <head>no circular unions</head>
  5616. <p>
  5617. If <propref ref="defn-variety"/> is <termref def="dt-union"/>,
  5618. then
  5619. it is an <termref def='dt-error'/> if
  5620. <propref ref='defn-name'/> and <propref ref='defn-target-namespace'/>
  5621.  <termref def='dt-match'/> <propref ref='defn-name'/>
  5622. and <propref ref='defn-target-namespace'/> of any member of
  5623. <propref ref='defn-memberTypes'/>.
  5624. </p>
  5625. </constraintnote>
  5626. </div3>
  5627.  
  5628. <div3 id='anySimpleType-component'>
  5629. <head>Simple Type Definition for anySimpleType</head>
  5630. <p>
  5631. There is a simple type definition nearly equivalent to the simple version
  5632. of the <xtermref href="&xsdl;#key-urType">ur-type definition</xtermref> present
  5633. in every schema by definition.  It has the following properties:
  5634. </p>
  5635. <compdef name="anySimpleType" ref="dt-anySimpleType">
  5636. <proplist>
  5637. <propdef id="anySimpleType-name" name="name">
  5638. anySimpleType
  5639. </propdef>
  5640. <propdef id="anySimpleType-target_namespace" name="target namespace">
  5641. http://www.w3.org/2001/XMLSchema
  5642. </propdef>
  5643. <propdef id="anySimpleType-basetype" name="basetype definition">
  5644. <xtermref href="&xsdl;#ur-type-itself">the ur-type definition</xtermref>
  5645. </propdef>
  5646. <propdef id="anySimpleType-final" name="final">
  5647. the empty set
  5648. </propdef>
  5649. <propdef id="anySimpleType-variety" name="variety">
  5650. <xtermref href="&xsdl;#key-null">absent</xtermref>
  5651. </propdef>
  5652. </proplist>
  5653. </compdef>
  5654. </div3>
  5655. </div2>
  5656.  
  5657. <div2 id='rf-fund-facets'>
  5658. <head>Fundamental Facets</head>
  5659.  
  5660. <div3 id="equal">
  5661. <head>equal</head>
  5662. <p>
  5663. Every <termref def="dt-value-space"/> supports the notion of equality,
  5664. with the following rules:
  5665. </p>
  5666. <ulist>
  5667. <item>
  5668. <p>
  5669. for any <emph role='eq'>a</emph> and <emph role='eq'>b</emph> in
  5670. the <termref def='dt-value-space'/>,
  5671. either <emph role='eq'>a</emph> is equal to <emph role='eq'>b</emph>,
  5672. denoted <emph role='eq'>a = b</emph>, or <emph role='eq'>a</emph>
  5673. is not equal to <emph role='eq'>b</emph>, denoted <emph role='eq'>a != b</emph>
  5674. </p>
  5675. </item>
  5676. <item>
  5677. <p>
  5678. there is no pair <emph role='eq'>a</emph> and <emph role='eq'>b</emph>
  5679. from the <termref def='dt-value-space'/> such that both
  5680. <emph role='eq'>a = b</emph> and <emph role='eq'>a != b</emph>
  5681. </p>
  5682. </item>
  5683. <item>
  5684. <p>
  5685. for all <emph role='eq'>a</emph> in the <termref def='dt-value-space'/>,
  5686. <emph role='eq'>a = a</emph>
  5687. </p>
  5688. </item>
  5689. <item>
  5690. <p>
  5691. for any <emph role='eq'>a</emph> and <emph role='eq'>b</emph>
  5692. in the <termref def='dt-value-space'/>,
  5693. <emph role='eq'>a = b</emph> if and only if <emph role='eq'>b = a</emph>
  5694. </p>
  5695. </item>
  5696. <item>
  5697. <p>
  5698. for any <emph role='eq'>a</emph>, <emph role='eq'>b</emph> and
  5699. <emph role='eq'>c</emph> in the <termref def='dt-value-space'/>,
  5700. if <emph role='eq'>a = b</emph> and
  5701. <emph role='eq'>b = c</emph>, then <emph role='eq'>a = c</emph>
  5702. </p>
  5703. </item>
  5704. <item>
  5705. <p>
  5706. for any <emph role='eq'>a</emph> and <emph role='eq'>b</emph>
  5707. in the <termref def='dt-value-space'/>
  5708. if <emph role='eq'>a = b</emph>, then <emph role='eq'>a</emph>
  5709. and <emph role='eq'>b</emph> cannot be distinguished
  5710. (i.e., equality is identity)
  5711. </p>
  5712. </item>
  5713. </ulist>
  5714. <p>
  5715. Note that a consequence of the above is that, given <termref def="dt-value-space"/>
  5716.  <emph role="eq">A</emph> and <termref def="dt-value-space"/>
  5717.  <emph role="eq">B</emph> where <emph role="eq">A</emph> and
  5718. <emph role="eq">B</emph> are not related by <termref def='dt-restriction'/>
  5719. or <termref def='dt-union'/>,
  5720. for every pair of values <emph role="eq">a</emph> from
  5721. <emph role="eq">A</emph> and <emph role="eq">b</emph> from
  5722. <emph role="eq">B</emph>, <emph role="eq">a != b</emph>.
  5723. </p>
  5724. <p>
  5725. On every datatype, the operation Equal is defined in terms of the equality
  5726. property of the <termref def="dt-value-space"/>: for any values
  5727. <emph role="eq">a, b</emph> drawn from the
  5728. <termref def="dt-value-space"/>, <emph role="eq">Equal(a,b)</emph> is
  5729. true if <emph role="eq">a = b</emph>, and false otherwise.
  5730. </p>
  5731.  
  5732. <note>
  5733. <p>
  5734. There is no schema component corresponding to the <term>equal</term>
  5735. <termref def='dt-fundamental-facet'/>.
  5736. </p>
  5737. </note>
  5738. </div3>
  5739.  
  5740. <div3 id='rf-ordered'>
  5741. <head>ordered</head>
  5742.  
  5743. <p>
  5744. <termdef id="dt-order-relation" term="order-relation">An
  5745. <term>order relation</term> on a <termref def="dt-value-space"/>
  5746. is a mathematical relation that imposes a
  5747. <termref def='dt-total-order'/> or a <termref def='dt-partial-order'/> on the
  5748. members of the <termref def="dt-value-space"/>.
  5749. </termdef>
  5750. </p>
  5751. <p>
  5752. <termdef id="dt-ordered" term="ordered">A
  5753. <termref def="dt-value-space"/>, and hence a datatype, is said to be
  5754. <term>ordered</term> if there exists an
  5755. <termref def="dt-order-relation"/> defined for that
  5756. <termref def="dt-value-space"/>.
  5757. </termdef>
  5758. </p>
  5759. <p>
  5760. <termdef id='dt-partial-order' term='partial order'>
  5761. A <term>partial order</term> is an <termref def='dt-order-relation'/>
  5762. that is <term>irreflexive</term>, <term>asymmetric</term> and
  5763. <term>transitive</term>.
  5764. </termdef>
  5765. </p>
  5766. <p>
  5767. A <termref def='dt-partial-order'/> has the following properties:
  5768. </p>
  5769. <ulist>
  5770. <item>
  5771. <p>
  5772. <!--
  5773. a R a
  5774. -->
  5775. for no <emph role='eq'>a</emph> in the <termref def='dt-value-space'/>,
  5776. <emph role='eq'>a < a</emph>
  5777. (irreflexivity)
  5778. </p>
  5779. </item>
  5780. <item>
  5781. <p>
  5782. <!--
  5783. a R b implies not(b R a)
  5784. -->
  5785. for all <emph role='eq'>a</emph> and <emph role='eq'>b</emph>
  5786. in the <termref def='dt-value-space'/>,
  5787. <emph role='eq'>a < b</emph>
  5788. implies not(<emph role='eq'>b < a</emph>)
  5789. (asymmetry)
  5790. </p>
  5791. </item>
  5792. <item>
  5793. <p>
  5794. <!--
  5795. a R b and b R c implies a R c
  5796. -->
  5797. for all <emph role='eq'>a</emph>, <emph role='eq'>b</emph>
  5798. and <emph role='eq'>c</emph>  in the <termref def='dt-value-space'/>,
  5799. <emph role='eq'>a < b</emph> and <emph role='eq'>b < c</emph>
  5800. implies <emph role='eq'>a < c</emph>
  5801. (transitivity)
  5802. </p>
  5803. </item>
  5804. <!--
  5805. Toys R Us
  5806. -->
  5807. <!--
  5808. <p>
  5809. for all <emph role='eq'>Toys</emph> and <emph role='eq'>Us</emph>
  5810.  in the <termref def='dt-value-space'/>,
  5811. <emph role='eq'>Toys < Us</emph>
  5812. (jeffreyity)
  5813. </p>
  5814. </item>
  5815. -->
  5816. </ulist>
  5817.  
  5818. <p>
  5819. The notation <emph role='eq'>a <> b</emph> is used to indicate the
  5820. case when <emph role='eq'>a != b</emph> and neither
  5821. <emph role='eq'>a < b</emph> nor <emph role='eq'>b < a</emph>
  5822. </p>
  5823. <p>
  5824. <termdef id='dt-total-order' term='total order'>
  5825. A <term>total order</term> is an <termref def='dt-partial-order'/>
  5826. such that for no <emph role='eq'>a</emph> and <emph role='eq'>b</emph>
  5827. is it the case that <emph role='eq'>a <> b</emph>.
  5828. </termdef>
  5829. </p>
  5830. <p>
  5831. A <termref def='dt-total-order'/> has all of the properties specified
  5832. above for <termref def='dt-partial-order'/>, plus
  5833. the following property:
  5834. </p>
  5835. <ulist>
  5836. <item>
  5837. <!--
  5838. a R b or b R a
  5839. -->
  5840. <p>
  5841. for all <emph role='eq'>a</emph> and <emph role='eq'>b</emph>
  5842.  in the <termref def='dt-value-space'/>,
  5843. either <emph role='eq'>a < b</emph> or <emph role='eq'>b < a</emph>
  5844. or <emph role='eq'>a = b</emph>
  5845. </p>
  5846. </item>
  5847. </ulist>
  5848. <note>
  5849. <p>
  5850. The fact that this specification does not define an
  5851. <termref def="dt-order-relation"/> for some datatype does not
  5852. mean that some other application cannot treat that datatype as
  5853. being ordered by imposing its own order relation.
  5854. </p>
  5855. </note>
  5856.  
  5857. <p>
  5858. <termref def="dt-ordered"/> provides for:
  5859. </p>
  5860. <ulist>
  5861. <item>
  5862. <p>
  5863. indicating whether an <termref def='dt-order-relation'/> is
  5864. defined on a <termref def='dt-value-space'/>, and if so,
  5865. whether that <termref def='dt-order-relation'/> is
  5866. a <termref def='dt-partial-order'/> or a <termref def='dt-total-order'/>
  5867. </p>
  5868. </item>
  5869. </ulist>
  5870.  
  5871. <div4 id='dc-ordered'>
  5872. <head>The ordered Schema Component</head>
  5873. <compdef name="ordered" ref="dt-ordered">
  5874. <proplist>
  5875. <propdef id="ordered-value" name="value">
  5876. One of <emph>{false, partial, total}</emph>.
  5877. </propdef>
  5878. </proplist>
  5879. </compdef>
  5880.  
  5881. <p>
  5882. <propref ref='ordered-value'/> depends on <propref ref='defn-variety'/>,
  5883. <propref ref='defn-facets'/> and <propref ref='defn-memberTypes'/>
  5884. in the <compref ref='dc-defn'/> component in which a
  5885. <termref def='dt-ordered'/> component appears as a member of
  5886. <propref ref='defn-fund-facets'/>.
  5887. </p>
  5888.  
  5889. <p>
  5890. When <propref ref="defn-variety"/> is <termref def="dt-atomic"/>,
  5891. <propref ref="ordered-value"/> is inherited from
  5892. <propref ref='ordered-value'/> of <propref ref='defn-basetype'/>.
  5893. For all <termref def='dt-primitive'/> types <propref ref='numeric-value'/>
  5894. is as specified    in the table in <specref ref='app-fundamental-facets'/>.
  5895. </p>
  5896. <p>
  5897. When <propref ref="defn-variety"/> is <termref def="dt-list"/>,
  5898. <propref ref="ordered-value"/> is <emph>false</emph>.
  5899. </p>
  5900.  
  5901. <p>
  5902. When <propref ref="defn-variety"/> is <termref def="dt-union"/>,
  5903. if <propref ref='ordered-value'/> is <emph>true</emph>
  5904. for every member of <propref ref="defn-memberTypes"/>
  5905. and all members of <propref ref="defn-memberTypes"/> share a common
  5906. ancestor, then <propref ref="ordered-value"/> is <emph>true</emph>;
  5907. else <propref ref='ordered-value'/> is <emph>false</emph>.
  5908. </p>
  5909. </div4>
  5910. </div3>
  5911.  
  5912. <div3 id='rf-bounded'>
  5913. <head>bounded</head>
  5914.  
  5915. <p>
  5916. <termdef id='dt-inclusive-upper-bound' term='inclusive upper bound'>
  5917. A value <emph role='eq'>u</emph> in an <termref def='dt-ordered'/>
  5918.  <termref def='dt-value-space'/> <emph role='eq'>U</emph>
  5919. is said to be an <term>inclusive upper bound</term> of a
  5920. <termref def='dt-value-space'/> <emph role='eq'>V</emph>
  5921. (where <emph role='eq'>V</emph> is a subset of <emph role='eq'>U</emph>)
  5922. if for all <emph role='eq'>v</emph> in <emph role='eq'>V</emph>,
  5923. <emph role='eq'>u</emph> >= <emph role='eq'>v</emph>.
  5924. </termdef>
  5925. </p>
  5926. <p>
  5927. <termdef id='dt-exclusive-upper-bound' term='exclusive upper bound'>
  5928. A value <emph role='eq'>u</emph> in an <termref def='dt-ordered'/>
  5929.  <termref def='dt-value-space'/> <emph role='eq'>U</emph>
  5930. is said to be an <term>exclusive upper bound</term> of a
  5931. <termref def='dt-value-space'/> <emph role='eq'>V</emph>
  5932. (where <emph role='eq'>V</emph> is a subset of <emph role='eq'>U</emph>)
  5933. if for all <emph role='eq'>v</emph> in <emph role='eq'>V</emph>,
  5934. <emph role='eq'>u</emph> > <emph role='eq'>v</emph>.
  5935. </termdef>
  5936. </p>
  5937. <p>
  5938. <termdef id='dt-inclusive-lower-bound' term='inclusive lower bound'>
  5939. A value <emph role='eq'>l</emph> in an <termref def='dt-ordered'/>
  5940.  <termref def='dt-value-space'/> <emph role='eq'>L</emph>
  5941. is said to be an <term>inclusive lower bound</term> of a
  5942. <termref def='dt-value-space'/> <emph role='eq'>V</emph>
  5943. (where <emph role='eq'>V</emph> is a subset of <emph role='eq'>L</emph>)
  5944. if for all <emph role='eq'>v</emph> in <emph role='eq'>V</emph>,
  5945. <emph role='eq'>l</emph> <= <emph role='eq'>v</emph>.
  5946. </termdef>
  5947. </p>
  5948. <p>
  5949. <termdef id='dt-exclusive-lower-bound' term='exclusive lower bound'>
  5950. A value <emph role='eq'>l</emph> in an <termref def='dt-ordered'/>
  5951.  <termref def='dt-value-space'/> <emph role='eq'>L</emph>
  5952. is said to be an <term>exclusive lower bound</term> of a
  5953. <termref def='dt-value-space'/> <emph role='eq'>V</emph>
  5954. (where <emph role='eq'>V</emph> is a subset of <emph role='eq'>L</emph>)
  5955. if for all <emph role='eq'>v</emph> in <emph role='eq'>V</emph>,
  5956. <emph role='eq'>l</emph> < <emph role='eq'>v</emph>.
  5957. </termdef>
  5958. </p>
  5959. <p>
  5960. <termdef id="dt-bounded" term="bounded">A datatype is <term>bounded</term>
  5961. if its <termref def="dt-value-space"/> has either an
  5962. <termref def='dt-inclusive-upper-bound'/> or an <termref def='dt-exclusive-upper-bound'/>
  5963. and either an <termref def="dt-inclusive-lower-bound"/> and an
  5964. <termref def="dt-exclusive-lower-bound"/>.
  5965. </termdef>
  5966. </p>
  5967.  
  5968. <p>
  5969. <termref def="dt-bounded"/> provides for:
  5970. </p>
  5971. <ulist>
  5972. <item>
  5973. <p>
  5974. indicating whether a <termref def='dt-value-space'/> is
  5975. <termref def='dt-bounded'/>
  5976. </p>
  5977. </item>
  5978. </ulist>
  5979.  
  5980. <div4 id='dc-bounded'>
  5981. <head>The bounded Schema Component</head>
  5982. <compdef name="bounded" ref="dt-bounded">
  5983. <proplist>
  5984. <propdef id="bounded-value" name="value">
  5985. A <dtref ref='boolean'/>.
  5986. </propdef>
  5987. </proplist>
  5988. </compdef>
  5989.  
  5990. <p>
  5991. <propref ref='bounded-value'/> depends on <propref ref='defn-variety'/>,
  5992. <propref ref='defn-facets'/> and <propref ref='defn-memberTypes'/>
  5993. in the <compref ref='dc-defn'/> component in which a
  5994. <termref def='dt-bounded'/> component appears as a member of
  5995. <propref ref='defn-fund-facets'/>.
  5996. </p>
  5997.  
  5998. <p>
  5999. When <propref ref="defn-variety"/> is <termref def="dt-atomic"/>,
  6000. if one of <termref def="dt-minInclusive"/> or <termref def="dt-minExclusive"/>
  6001. and one of <termref def="dt-maxInclusive"/> or <termref def="dt-maxExclusive"/>
  6002. are among <propref ref="defn-facets"/> , then
  6003. <propref ref="bounded-value"/> is <emph>true</emph>; else 
  6004. <propref ref="bounded-value"/> is <emph>false</emph>.
  6005. </p>
  6006. <p>
  6007. When <propref ref="defn-variety"/> is <termref def="dt-list"/>,
  6008. if <termref def="dt-length"/> or both of
  6009. <termref def="dt-minLength"/> and <termref def="dt-maxLength"/>
  6010. are among <propref ref="defn-facets"/>, then
  6011. <propref ref="bounded-value"/> is <emph>true</emph>; else
  6012. <propref ref="bounded-value"/> is <emph>false</emph>.
  6013. </p>
  6014.  
  6015. <p>
  6016. When <propref ref="defn-variety"/> is <termref def="dt-union"/>,
  6017. if <propref ref='bounded-value'/> is <emph>true</emph>
  6018. for every member of <propref ref="defn-memberTypes"/>
  6019. and all members of <propref ref="defn-memberTypes"/> share a common
  6020. ancestor, then <propref ref="bounded-value"/> is <emph>true</emph>;
  6021. else <propref ref='bounded-value'/> is <emph>false</emph>.
  6022. </p>
  6023.  
  6024. </div4>
  6025. </div3>
  6026.  
  6027. <div3 id='rf-cardinality'>
  6028. <head>cardinality</head>
  6029.  
  6030. <p>
  6031. <termdef id="dt-cardinality" term="cardinality">Every
  6032. <termref def="dt-value-space"/> has associated with it the concept of
  6033. <term>cardinality</term>.  Some <termref def="dt-value-space"/>s
  6034. are finite, some are countably infinite while still others could
  6035. conceivably be uncountably infinite (although no <termref def='dt-value-space'/>
  6036. defined by this specification is uncountable infinite). A datatype is
  6037. said to have the cardinality of its
  6038. <termref def="dt-value-space"/>.
  6039. </termdef>
  6040. </p>
  6041. <p>
  6042. It
  6043. is sometimes useful to categorize <termref def="dt-value-space"/>s
  6044. (and hence, datatypes) as to their cardinality.  There are two
  6045. significant cases:
  6046. </p>
  6047. <ulist>
  6048. <item>
  6049. <p>
  6050. <termref def="dt-value-space"/>s that are finite
  6051. </p>
  6052. </item>
  6053. <item>
  6054. <p>
  6055. <termref def="dt-value-space"/>s that are countably infinite
  6056. </p>
  6057. </item>
  6058. </ulist>
  6059.  
  6060. <p>
  6061. <termref def="dt-cardinality"/> provides for:
  6062. </p>
  6063. <ulist>
  6064. <item>
  6065. <p>
  6066. indicating whether the <termref def='dt-cardinality'/>
  6067. of a <termref def='dt-value-space'/> is
  6068. <emph>finite</emph> or <emph>countably infinite</emph>
  6069. </p>
  6070. </item>
  6071. </ulist>
  6072.  
  6073. <div4 id='dc-cardinality'>
  6074. <head>The cardinality Schema Component</head>
  6075. <compdef name="cardinality" ref="dt-cardinality">
  6076. <proplist>
  6077. <propdef id="cardinality-value" name="value">
  6078. One of <emph>{finite, countably infinite}</emph>.
  6079. </propdef>
  6080. </proplist>
  6081. </compdef>
  6082.  
  6083. <p>
  6084. <propref ref='cardinality-value'/> depends on <propref ref='defn-variety'/>,
  6085. <propref ref='defn-facets'/> and <propref ref='defn-memberTypes'/>
  6086. in the <compref ref='dc-defn'/> component in which a
  6087. <termref def='dt-cardinality'/> component appears as a member of
  6088. <propref ref='defn-fund-facets'/>.
  6089. </p>
  6090.  
  6091. <p>
  6092. When <propref ref="defn-variety"/> is <termref def="dt-atomic"/> and
  6093. <propref ref='cardinality-value'/> of <propref ref='defn-basetype'/>
  6094. is <emph>finite</emph>, then <propref ref='cardinality-value'/> is
  6095. <emph>finite</emph>.
  6096. </p>
  6097.  
  6098. <p>
  6099. When <propref ref="defn-variety"/> is <termref def="dt-atomic"/> and
  6100. <propref ref='cardinality-value'/> of <propref ref='defn-basetype'/>
  6101. is <emph>countably infinite</emph> and <strong>either</strong> of the following
  6102. conditions are true, then <propref ref="cardinality-value"/> is
  6103. <emph>finite</emph>; else <propref ref="cardinality-value"/>
  6104. is <emph>countably infinite</emph>:
  6105. </p>
  6106.  
  6107. <olist role='orval'>
  6108. <item>
  6109. <p>
  6110. one of <termref def="dt-length"/>, <termref def="dt-maxLength"/>,
  6111. <termref def="dt-totalDigits"/> is among <propref ref="defn-facets"/>,
  6112. </p>
  6113. </item>
  6114.  
  6115. <item>
  6116. <p>
  6117. <strong>all</strong> of the following are true:
  6118. </p>
  6119. <olist role='and'>
  6120. <item>
  6121. <p>
  6122. one of <termref def="dt-minInclusive"/> or
  6123. <termref def="dt-minExclusive"/>
  6124. is among <propref ref="defn-facets"/>
  6125. </p>
  6126. </item>
  6127. <item>
  6128. <p>
  6129. one of <termref def="dt-maxInclusive"/> or
  6130. <termref def="dt-maxExclusive"/>
  6131. is among <propref ref="defn-facets"/>
  6132. </p>
  6133. </item>
  6134. <item>
  6135. <p>
  6136. <strong>either</strong> of the following are true:
  6137. </p>
  6138. <olist role='orval'>
  6139. <item>
  6140. <p>
  6141. <termref def="dt-fractionDigits"/> is among <propref ref="defn-facets"/>
  6142. </p>
  6143. </item>
  6144. <item>
  6145. <p>
  6146. <propref ref='defn-basetype'/> is one of <dtref ref='date'/>,
  6147. <dtref ref='gYearMonth'/>, <dtref ref='gYear'/>, <dtref ref='gMonthDay'/>,
  6148. <dtref ref='gDay'/> or <dtref ref='gMonth'/> or any type <termref def='dt-derived'/>
  6149. from them
  6150. </p>
  6151. </item>
  6152. </olist>
  6153. </item>
  6154. </olist>
  6155. </item>
  6156. </olist>
  6157.  
  6158. <p>
  6159. When <propref ref="defn-variety"/> is <termref def="dt-list"/>,
  6160. if <termref def="dt-length"/> or both of
  6161. <termref def="dt-minLength"/> and <termref def="dt-maxLength"/>
  6162. are among <propref ref="defn-facets"/>, then
  6163. <propref ref="cardinality-value"/> is <emph>finite</emph>; else
  6164. <propref ref="cardinality-value"/> is <emph>countably infinite</emph>.
  6165. </p>
  6166.  
  6167. <p>
  6168. When <propref ref="defn-variety"/> is <termref def="dt-union"/>,
  6169. if <propref ref='cardinality-value'/> is <emph>finite</emph>
  6170. for every member of <propref ref="defn-memberTypes"/>, then
  6171. <propref ref="cardinality-value"/> is <emph>finite</emph>;
  6172. else <propref ref='cardinality-value'/> is <emph>countably infinite</emph>.
  6173. </p>
  6174. </div4>
  6175. </div3>
  6176.  
  6177. <div3 id='rf-numeric'>
  6178. <head>numeric</head>
  6179.  
  6180. <p>
  6181. <termdef id="dt-numeric" term="numeric">A datatype is said to be
  6182. <term>numeric</term> if its values are conceptually quantities (in some
  6183. mathematical number system).
  6184. </termdef>
  6185. </p>
  6186. <p>
  6187. <termdef id="dt-non-numeric" term="non-numeric">A datatype whose values
  6188. are not <termref def="dt-numeric"/> is said to be
  6189. <term>non-numeric</term>.
  6190. </termdef>
  6191. </p>
  6192. <p>
  6193. <termref def="dt-numeric"/> provides for:
  6194. </p>
  6195. <ulist>
  6196. <item>
  6197. <p>
  6198. indicating whether a <termref def='dt-value-space'/> is
  6199. <termref def='dt-numeric'/>
  6200. </p>
  6201. </item>
  6202. </ulist>
  6203.  
  6204. <div4 id='dc-numeric'>
  6205. <head>The numeric Schema Component</head>
  6206. <compdef name="numeric" ref="dt-numeric">
  6207. <proplist>
  6208. <propdef id="numeric-value" name="value">
  6209. A <dtref ref='boolean'/>
  6210. </propdef>
  6211. </proplist>
  6212. </compdef>
  6213.  
  6214. <p>
  6215. <propref ref='numeric-value'/> depends on <propref ref='defn-variety'/>,
  6216. <propref ref='defn-facets'/>, <propref ref='defn-basetype'/> and
  6217. <propref ref='defn-memberTypes'/> in the <compref ref='dc-defn'/> component
  6218. in which a <termref def='dt-cardinality'/> component appears as a member of
  6219. <propref ref='defn-fund-facets'/>.
  6220. </p>
  6221.  
  6222. <p>
  6223. When <propref ref='defn-variety'/> is <termref def='dt-atomic'/>,
  6224. <propref ref='numeric-value'/> is inherited from
  6225. <propref ref='numeric-value'/> of <propref ref='defn-basetype'/>.
  6226. For all <termref def='dt-primitive'/> types <propref ref='numeric-value'/>
  6227. is as specified    in the table in <specref ref='app-fundamental-facets'/>.
  6228. </p>
  6229.  
  6230. <p>
  6231. When <propref ref='defn-variety'/> is <termref def='dt-list'/>,
  6232. <propref ref='numeric-value'/> is <emph>false</emph>.
  6233. </p>
  6234.  
  6235. <p>
  6236. When <propref ref="defn-variety"/> is <termref def="dt-union"/>,
  6237. if <propref ref='numeric-value'/> is <emph>true</emph>
  6238. for every member of <propref ref="defn-memberTypes"/>, then
  6239. <propref ref="numeric-value"/> is <emph>true</emph>;
  6240. else <propref ref='numeric-value'/> is <emph>false</emph>.
  6241. </p>
  6242.  
  6243. </div4>
  6244. </div3>
  6245. </div2>
  6246.  
  6247. <div2 id='rf-facets'>
  6248. <head>Constraining Facets</head>
  6249.  
  6250. <div3 id='rf-length'>
  6251. <head>length</head>
  6252.  
  6253. <p>
  6254. <termdef id="dt-length" term="length" role='local'>
  6255. <term>length</term> is the number
  6256. of <emph>units of length</emph>, where <emph>units of length</emph>
  6257. varies depending on the type that is being <termref def="dt-derived"/> from.
  6258. The value of
  6259. <term>length</term> <termref def="dt-must"/> be a
  6260. <dtref ref="nonNegativeInteger"/>.
  6261. </termdef>
  6262. </p>
  6263. <p>
  6264. For <dtref ref="string"/> and datatypes <termref def="dt-derived"/> from <dtref ref="string"/>,
  6265. <term>length</term> is measured in units of <xtermref href="&xmlspec;#dt-character">
  6266. character</xtermref>s as defined in <bibref ref="XML"/>.
  6267. For <dtref ref='anyURI'/>, <term>length</term> is measured in units of
  6268. characters (as for <dtref ref='string'/>).
  6269. For <dtref ref="hexBinary"/> and <dtref ref="base64Binary"/> and datatypes <termref def="dt-derived"/> from them,
  6270. <term>length</term> is measured in octets (8 bits) of binary data.
  6271. For datatypes <termref def="dt-derived"/> by <termref def="dt-list"/>,
  6272. <term>length</term> is measured in number of list items.
  6273. </p>
  6274. <note>
  6275. <p>
  6276. For <dtref ref="string"/> and datatypes <termref def="dt-derived"/> from <dtref ref="string"/>,
  6277. <term>length</term> will not always coincide with "string length" as perceived
  6278. by some users or with the number of storage units in some digital representation.
  6279. Therefore, care should be taken when specifying a value for <term>length</term>
  6280. and in attempting to infer storage requirements from a given value for
  6281. <term>length</term>.
  6282. </p>
  6283. </note>
  6284.  
  6285. <p>
  6286. <termref def="dt-length"/> provides for:
  6287. </p>
  6288. <ulist>
  6289. <item>
  6290. <p>
  6291. Constraining a <termref def="dt-value-space"/>
  6292. to values with a specific number of <emph>units of length</emph>,
  6293. where <emph>units of length</emph>
  6294. varies depending on <propref ref="defn-basetype"/>.
  6295. </p>
  6296. </item>
  6297. </ulist>
  6298.  
  6299. <note role="example">
  6300. <p>
  6301. The following is the definition of a <termref def="dt-user-derived"/>
  6302. datatype to represent product codes which must be
  6303. exactly 8 characters in length.  By fixing the value of the
  6304. <term>length</term> facet we ensure that types derived from productCode can
  6305. change or set the values of other facets, such as <term>pattern</term>, but
  6306. cannot change the length.  
  6307. </p>
  6308. <eg><![CDATA[<simpleType name='productCode'>
  6309.    <restriction base='string'>
  6310.      <length value='8' fixed='true'/>
  6311.    </restriction>
  6312. </simpleType>]]></eg>
  6313. </note>
  6314.  
  6315. <div4 id='dc-length'>
  6316. <head>The length Schema Component</head>
  6317.  
  6318. <compdef name="length" ref="dt-length">
  6319. <proplist>
  6320. <propdef id="length-value" name="value">
  6321. A <dtref ref="nonNegativeInteger"/>.
  6322. </propdef>
  6323. <propdef id="length-fixed" name="fixed">
  6324. A <dtref ref="boolean"/>.
  6325. </propdef>
  6326. <propdef id="length-annotation" name="annotation">
  6327. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  6328. </propdef>
  6329. </proplist>
  6330. </compdef>
  6331.  
  6332. <p>
  6333. If <propref ref="length-fixed"/> is <emph>true</emph>, then types for which
  6334. the current type is the <propref ref="defn-basetype"/> cannot specify a
  6335. value for <compref ref="dc-length"/> other than <propref ref="length-value"/>.
  6336. </p>
  6337. </div4>
  6338.  
  6339. <div4 id="xr-length">
  6340. <head>XML Representation of length Schema Components</head>
  6341.  
  6342. <p>
  6343. The XML representation for a <compref ref="dc-length"/> schema
  6344. component is a <eltref ref="length"/> element information item. The
  6345. correspondences between the properties of the information item and
  6346. properties of the component are as follows:
  6347. </p>
  6348.  
  6349. <reprdef eltname="length">
  6350. <reprelt eltname="length"/>
  6351. <reprcomp abstract="length" ref="dc-fractionDigits">
  6352. <propmap name="length-value">
  6353. The &v-value; of the <code>value</code> &i-attribute;
  6354. </propmap>
  6355. <propmap name="length-fixed">
  6356. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  6357. </propmap>
  6358. <propmap name="defn-annotation">
  6359. The annotations corresponding to all the <eltref ref="annotation"/>
  6360. element information items in the &i-children;, if any.
  6361. </propmap>
  6362. </reprcomp>
  6363. </reprdef>
  6364.  
  6365. </div4>
  6366.  
  6367. <div4 id='length-validation-rules'>
  6368. <head>length Validation Rules</head>
  6369.  
  6370. <constraintnote type="cvc" id="cvc-length-valid">
  6371. <head>Length Valid</head>
  6372. <p>
  6373. A value in a <termref def="dt-value-space"/> is facet-valid with
  6374. respect to <termref def="dt-length"/>, determined as follows:
  6375. </p>
  6376. <olist>
  6377. <item>
  6378. <p>
  6379. if the <propref ref="defn-variety"/> is <termref def="dt-atomic"/> then
  6380. <olist>
  6381. <item>
  6382. <p>
  6383. if <propref ref="defn-primitive"/> is <dtref ref="string"/>, then the
  6384. length of the value, as measured in <xtermref href="&xmlspec;#dt-character">
  6385. character</xtermref>s
  6386. <termref def="dt-must"/> be equal to <propref ref="length-value"/>;
  6387. </p>
  6388. </item>
  6389. <item>
  6390. <p>
  6391. if <propref ref="defn-primitive"/> is <dtref ref="hexBinary"/> or <dtref ref="base64Binary"/>, then the
  6392. length of the value, as measured in octets of the binary data, 
  6393. <termref def="dt-must"/> be equal to <propref ref="length-value"/>;
  6394. </p>
  6395. </item>
  6396. </olist>
  6397. </p>
  6398. </item>
  6399. <item>
  6400. <p>
  6401. if the <propref ref="defn-variety"/> is <termref def="dt-list"/>,
  6402. then the length of the value, as measured
  6403. in list items, <termref def="dt-must"/> be equal to <propref ref="length-value"/>
  6404. </p>
  6405. </item>
  6406. </olist>
  6407. </constraintnote>
  6408. </div4>
  6409.  
  6410. <div4 id='length-coss'>
  6411. <head>Constraints on length Schema Components</head>
  6412. <constraintnote type="cos" id="length-minLength-maxLength">
  6413. <head>length and minLength or maxLength</head>
  6414. <p>
  6415. It is an <termref def="dt-error"/> for both
  6416. <compref ref="dc-length"/> and either of
  6417. <compref ref="dc-minLength"/> or <compref ref="dc-maxLength"/>
  6418. to be members of <propref ref="defn-facets"/>.
  6419. </p>
  6420. </constraintnote>
  6421.  
  6422. <constraintnote type="cos" id="length-valid-restriction">
  6423. <head>length valid restriction</head>
  6424. <p>
  6425. It is an <termref def="dt-error"/> if <compref ref='dc-length'/>
  6426. is among the members of <propref ref='defn-facets'/> of
  6427. <propref ref='defn-basetype'/> and <propref ref='length-value'/> is
  6428. not equal to the <propref ref='length-value'/> of the parent
  6429. <compref ref='dc-length'/>.
  6430. </p>
  6431. </constraintnote>
  6432.  
  6433. </div4>
  6434. </div3>
  6435.  
  6436. <div3 id='rf-minLength'>
  6437. <head>minLength</head>
  6438.  
  6439. <p>
  6440. <termdef id="dt-minLength" term="minLength" role='local'>
  6441. <term>minLength</term> is
  6442. the minimum number of <emph>units of length</emph>, where
  6443. <emph>units of length</emph> varies depending on the type that is being
  6444. <termref def="dt-derived"/> from.
  6445. The value of <term>minLength</term>
  6446.  <termref def="dt-must"/> be a <dtref ref="nonNegativeInteger"/>.
  6447. </termdef>
  6448. </p>
  6449. <p>
  6450. For <dtref ref="string"/> and datatypes <termref def="dt-derived"/> from <dtref ref="string"/>,
  6451. <term>minLength</term> is measured in units of <xtermref href="&xmlspec;#dt-character">
  6452. character</xtermref>s as defined in <bibref ref="XML"/>.
  6453. For <dtref ref="hexBinary"/> and <dtref ref="base64Binary"/> and datatypes <termref def="dt-derived"/> from them,
  6454. <term>minLength</term> is measured in octets (8 bits) of binary data.
  6455. For datatypes <termref def="dt-derived"/> by <termref def="dt-list"/>,
  6456. <term>minLength</term> is measured in number of list items.
  6457. </p>
  6458. <note>
  6459. <p>
  6460. For <dtref ref="string"/> and datatypes <termref def="dt-derived"/> from <dtref ref="string"/>,
  6461. <term>minLength</term> will not always coincide with "string length" as perceived
  6462. by some users or with the number of storage units in some digital representation.
  6463. Therefore, care should be taken when specifying a value for <term>minLength</term>
  6464. and in attempting to infer storage requirements from a given value for
  6465. <term>minLength</term>.
  6466. </p>
  6467. </note>
  6468.  
  6469. <p>
  6470. <termref def="dt-minLength"/> provides for:
  6471. </p>
  6472. <ulist>
  6473. <item>
  6474. <p>
  6475. Constraining a <termref def="dt-value-space"/>
  6476. to values with at least a specific number of <emph>units of length</emph>,
  6477. where <emph>units of length</emph>
  6478. varies depending on <propref ref="defn-basetype"/>.
  6479. </p>
  6480. </item>
  6481. </ulist>
  6482.  
  6483. <note role="example">
  6484. <p>
  6485. The following is the definition of a <termref def="dt-user-derived"/>
  6486. datatype which requires strings to have at least one character (i.e.,
  6487. the empty string is not in the <termref def="dt-value-space"/>
  6488. of this datatype).
  6489. </p>
  6490. <eg><![CDATA[<simpleType name='non-empty-string'>
  6491.   <restriction base='string'>
  6492.     <minLength value='1'/>
  6493.   </restriction>
  6494. </simpleType>]]></eg>
  6495. </note>
  6496.  
  6497. <div4 id="dc-minLength">
  6498. <head>The minLength Schema Component</head>
  6499.  
  6500. <compdef name="minLength" ref="dt-minLength">
  6501. <proplist>
  6502. <propdef id="minLength-value" name="value">
  6503. A <dtref ref="nonNegativeInteger"/>.
  6504. </propdef>
  6505. <propdef id="minLength-fixed" name="fixed">
  6506. A <dtref ref="boolean"/>.
  6507. </propdef>
  6508. <propdef id="minLength-annotation" name="annotation">
  6509. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  6510. </propdef>
  6511. </proplist>
  6512. </compdef>
  6513.  
  6514. <p>
  6515. If <propref ref="minLength-fixed"/> is <emph>true</emph>, then types for which
  6516. the current type is the <propref ref="defn-basetype"/> cannot specify a
  6517. value for <compref ref="dc-minLength"/> other than <propref ref="minLength-value"/>.
  6518. </p>
  6519. </div4>
  6520.  
  6521. <div4 id="xr-minLength">
  6522. <head>XML Representation of minLength Schema Component</head>
  6523.  
  6524. <p>
  6525. The XML representation for a <compref ref="dc-minLength"/> schema
  6526. component is a <eltref ref="minLength"/> element information item. The
  6527. correspondences between the properties of the information item and
  6528. properties of the component are as follows:
  6529. </p>
  6530.  
  6531. <reprdef eltname="minLength">
  6532. <reprelt eltname="minLength"/>
  6533. <reprcomp abstract="minLength" ref="dc-fractionDigits">
  6534. <propmap name="minLength-value">
  6535. The &v-value; of the <code>value</code> &i-attribute;
  6536. </propmap>
  6537. <propmap name="minLength-fixed">
  6538. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  6539. </propmap>
  6540. <propmap name="defn-annotation">
  6541. The annotations corresponding to all the <eltref ref="annotation"/>
  6542. element information items in the &i-children;, if any.
  6543. </propmap>
  6544. </reprcomp>
  6545. </reprdef>
  6546. </div4>
  6547.  
  6548. <div4 id='minLength-validation-rules'>
  6549. <head>minLength Validation Rules</head>
  6550. <constraintnote type="cvc" id="cvc-minLength-valid">
  6551. <head>minLength Valid</head>
  6552. <p>
  6553. A value in a <termref def="dt-value-space"/> is facet-valid with
  6554. respect to <termref def="dt-minLength"/>, determined as follows:
  6555. </p>
  6556. <olist>
  6557. <item>
  6558. <p>
  6559. if the <propref ref="defn-variety"/> is <termref def="dt-atomic"/> then
  6560. <olist>
  6561. <item>
  6562. <p>
  6563. if <propref ref="defn-primitive"/> is <dtref ref="string"/>, then the
  6564. length of the value, as measured in<xtermref href="&xmlspec;#dt-character">
  6565. character</xtermref>s
  6566. <termref def="dt-must"/> be greater than or equal to
  6567. <propref ref="minLength-value"/>;
  6568. </p>
  6569. </item>
  6570. <item>
  6571. <p>
  6572. if <propref ref="defn-primitive"/> is <dtref ref="hexBinary"/> or <dtref ref="base64Binary"/>, then the
  6573. length of the value, as measured in octets of the binary data, 
  6574. <termref def="dt-must"/> be greater than or equal to
  6575. <propref ref="minLength-value"/>;
  6576. </p>
  6577. </item>
  6578. </olist>
  6579. </p>
  6580. </item>
  6581. <item>
  6582. <p>
  6583. if the <propref ref="defn-variety"/> is <termref def="dt-list"/>,
  6584. then the length of the value, as measured
  6585. in list items, <termref def="dt-must"/> be greater than or equal
  6586. to <propref ref="minLength-value"/>
  6587. </p>
  6588. </item>
  6589. </olist>
  6590. </constraintnote>
  6591.  
  6592. </div4>
  6593.  
  6594. <div4 id='minLength-coss'>
  6595. <head>Constraints on minLength Schema Components</head>
  6596. <constraintnote type="cos" id="minLength-less-than-equal-to-maxLength">
  6597. <head>minLength <= maxLength</head>
  6598. <p>
  6599. If both <compref ref="dc-minLength"/> and <compref ref="dc-maxLength"/>
  6600. are members of <propref ref="defn-facets"/>, then the
  6601. <propref ref="minLength-value"/> of <compref ref="dc-minLength"/>
  6602.  <termref def="dt-must"/> be less than or equal to the
  6603. <propref ref="maxLength-value"/> of <compref ref="dc-maxLength"/>.
  6604. </p>
  6605. </constraintnote>
  6606.  
  6607. <constraintnote type="cos" id="minLength-valid-restriction">
  6608. <head>minLength valid restriction</head>
  6609. <p>
  6610. It is an <termref def="dt-error"/> if <compref ref='dc-minLength'/>
  6611. is among the members of <propref ref='defn-facets'/> of
  6612. <propref ref='defn-basetype'/> and <propref ref='minLength-value'/> is
  6613. less than the <propref ref='minLength-value'/> of the parent
  6614. <compref ref='dc-minLength'/>.
  6615. </p>
  6616. </constraintnote>
  6617. </div4>
  6618. </div3>
  6619.  
  6620. <div3 id='rf-maxLength'>
  6621. <head>maxLength</head>
  6622.  
  6623. <p>
  6624. <termdef id="dt-maxLength" term="maxLength" role='local'>
  6625. <term>maxLength</term> is
  6626. the maximum number of <emph>units of length</emph>, where
  6627. <emph>units of length</emph> varies
  6628. depending on the type that is being <termref def="dt-derived"/> from.
  6629. The value of <term>maxLength</term>
  6630.  <termref def="dt-must"/> be a <dtref ref="nonNegativeInteger"/>.
  6631. </termdef>
  6632. </p>
  6633. <p>
  6634. For <dtref ref="string"/> and datatypes <termref def="dt-derived"/> from <dtref ref="string"/>,
  6635. <term>maxLength</term> is measured in units of <xtermref href="&xmlspec;#dt-character">
  6636. character</xtermref>s as defined in <bibref ref="XML"/>.
  6637. For <dtref ref="hexBinary"/> and <dtref ref="base64Binary"/> and datatypes <termref def="dt-derived"/> from them,
  6638. <term>maxLength</term> is measured in octets (8 bits) of binary data.
  6639. For datatypes <termref def="dt-derived"/> by <termref def="dt-list"/>,
  6640. <term>maxLength</term> is measured in number of list items.
  6641. </p>
  6642. <note>
  6643. <p>
  6644. For <dtref ref="string"/> and datatypes <termref def="dt-derived"/> from <dtref ref="string"/>,
  6645. <term>maxLength</term> will not always coincide with "string length" as perceived
  6646. by some users or with the number of storage units in some digital representation.
  6647. Therefore, care should be taken when specifying a value for <term>maxLength</term>
  6648. and in attempting to infer storage requirements from a given value for
  6649. <term>maxLength</term>.
  6650. </p>
  6651. </note>
  6652.  
  6653. <p>
  6654. <termref def="dt-maxLength"/> provides for:
  6655. </p>
  6656. <ulist>
  6657. <item>
  6658. <p>
  6659. Constraining a <termref def="dt-value-space"/>
  6660. to values with at most a specific number of <emph>units of length</emph>,
  6661. where <emph>units of length</emph>
  6662. varies depending on <propref ref="defn-basetype"/>.
  6663. </p>
  6664. </item>
  6665. </ulist>
  6666.  
  6667. <note role="example">
  6668. <p>
  6669. The following is the definition of a <termref def="dt-user-derived"/>
  6670. datatype which might be used to accept form input with an upper limit
  6671. to the number of characters that are acceptable.
  6672. </p>
  6673. <eg><![CDATA[<simpleType name='form-input'>
  6674.   <restriction base='string'>
  6675.     <maxLength value='50'/>
  6676.   </restriction>
  6677. </simpleType>]]></eg>
  6678. </note>
  6679.  
  6680. <div4 id='dc-maxLength'>
  6681. <head>The maxLength Schema Component</head>
  6682. <compdef name="maxLength" ref="dt-maxLength">
  6683. <proplist>
  6684. <propdef id="maxLength-value" name="value">
  6685. A <dtref ref="nonNegativeInteger"/>.
  6686. </propdef>
  6687. <propdef id="maxLength-fixed" name="fixed">
  6688. A <dtref ref="boolean"/>.
  6689. </propdef>
  6690. <propdef id="maxLength-annotation" name="annotation">
  6691. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  6692. </propdef>
  6693. </proplist>
  6694. </compdef>
  6695.  
  6696. <p>
  6697. If <propref ref="maxLength-fixed"/> is <emph>true</emph>, then types for which
  6698. the current type is the <propref ref="defn-basetype"/> cannot specify a
  6699. value for <compref ref="dc-maxLength"/> other than <propref ref="maxLength-value"/>.
  6700. </p>
  6701.  
  6702. </div4>
  6703.  
  6704. <div4 id='xr-maxLength'>
  6705. <head>XML Representation of maxLength Schema Components</head>
  6706.  
  6707. <p>
  6708. The XML representation for a <compref ref="dc-maxLength"/> schema
  6709. component is a <eltref ref="maxLength"/> element information item. The
  6710. correspondences between the properties of the information item and
  6711. properties of the component are as follows:
  6712. </p>
  6713.  
  6714. <reprdef eltname="maxLength">
  6715. <reprelt eltname="maxLength"/>
  6716. <reprcomp abstract="maxLength" ref="dc-fractionDigits">
  6717. <propmap name="maxLength-value">
  6718. The &v-value; of the <code>value</code> &i-attribute;
  6719. </propmap>
  6720. <propmap name="maxLength-fixed">
  6721. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  6722. </propmap>
  6723. <propmap name="defn-annotation">
  6724. The annotations corresponding to all the <eltref ref="annotation"/>
  6725. element information items in the &i-children;, if any.
  6726. </propmap>
  6727. </reprcomp>
  6728. </reprdef>
  6729. </div4>
  6730.  
  6731. <div4 id='maxLength-validation-rules'>
  6732. <head>maxLength Validation Rules</head>
  6733. <constraintnote type="cvc" id="cvc-maxLength-valid">
  6734. <head>maxLength Valid</head>
  6735. <p>
  6736. A value in a <termref def="dt-value-space"/> is facet-valid with
  6737. respect to <termref def="dt-maxLength"/>, determined as follows:
  6738. </p>
  6739. <olist>
  6740. <item>
  6741. <p>
  6742. if the <propref ref="defn-variety"/> is <termref def="dt-atomic"/> then
  6743. <olist>
  6744. <item>
  6745. <p>
  6746. if <propref ref="defn-primitive"/> is <dtref ref="string"/>, then the
  6747. length of the value, as measured in <xtermref href="&xmlspec;#dt-character">
  6748. character</xtermref>s
  6749. <termref def="dt-must"/> be less than or equal to
  6750. <propref ref="maxLength-value"/>;
  6751. </p>
  6752. </item>
  6753. <item>
  6754. <p>
  6755. if <propref ref="defn-primitive"/> is <dtref ref="hexBinary"/> or <dtref ref="base64Binary"/>, then the
  6756. length of the value, as measured in octets of the binary data, 
  6757. <termref def="dt-must"/> be less than or equal to <propref ref="maxLength-value"/>;
  6758. </p>
  6759. </item>
  6760. </olist>
  6761. </p>
  6762. </item>
  6763. <item>
  6764. <p>
  6765. if the <propref ref="defn-variety"/> is <termref def="dt-list"/>,
  6766. then the length of the value, as measured
  6767. in list items, <termref def="dt-must"/> be less than or equal to
  6768. <propref ref="maxLength-value"/>
  6769. </p>
  6770. </item>
  6771. </olist>
  6772. </constraintnote>
  6773. </div4>
  6774.  
  6775. <div4 id='maxLength-coss'>
  6776. <head>Constraints on maxLength Schema Components</head>
  6777. <constraintnote type="cos" id="maxLength-valid-restriction">
  6778. <head>maxLength valid restriction</head>
  6779. <p>
  6780. It is an <termref def="dt-error"/> if <compref ref='dc-maxLength'/>
  6781. is among the members of <propref ref='defn-facets'/> of
  6782. <propref ref='defn-basetype'/> and <propref ref='maxLength-value'/> is
  6783. greater than the <propref ref='maxLength-value'/> of the parent
  6784. <compref ref='dc-maxLength'/>.
  6785. </p>
  6786. </constraintnote>
  6787. </div4>
  6788.  
  6789. </div3>
  6790.  
  6791. <div3 id='rf-pattern'>
  6792. <head>pattern</head>
  6793.  
  6794. <p>
  6795. <termdef id="dt-pattern" term="pattern" role='local'>
  6796. <term>pattern</term> is a constraint on the
  6797. <termref def="dt-value-space"/> of a datatype which is achieved by
  6798. constraining the <termref def="dt-lexical-space"/> to literals
  6799. which match a specific pattern.  The value of <term>pattern</term>
  6800.  <termref def="dt-must"/> be a <termref def="dt-regex"/>.
  6801. </termdef>
  6802. </p>
  6803.  
  6804. <p>
  6805. <termref def="dt-pattern"/> provides for:
  6806. </p>
  6807. <ulist>
  6808. <item>
  6809. <p>
  6810. Constraining a <termref def="dt-value-space"/>
  6811. to values that are denoted by literals which match a specific
  6812. <termref def="dt-regex"/>.
  6813. </p>
  6814. </item>
  6815. </ulist>
  6816.  
  6817. <note role="example">
  6818. <p>
  6819. The following is the definition of a <termref def="dt-user-derived"/>
  6820. datatype which is a better representation of postal codes in the
  6821. United States, by limiting strings to those which are matched by
  6822. a specific <termref def="dt-regex"/>.
  6823. </p>
  6824. <eg><![CDATA[<simpleType name='better-us-zipcode'>
  6825.   <restriction base='string'>
  6826.     <pattern value='[0-9]{5}(-[0-9]{4})?'/>
  6827.   </restriction>
  6828. </simpleType>]]></eg>
  6829. </note>
  6830.  
  6831. <div4 id='dc-pattern'>
  6832. <head>The pattern Schema Component</head>
  6833. <compdef name="pattern" ref="dt-pattern">
  6834. <proplist>
  6835. <propdef id="pattern-value" name="value">
  6836. A <termref def="dt-regex"/>.
  6837. </propdef>
  6838. <propdef id="pattern-annotation" name="annotation">
  6839. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  6840. </propdef>
  6841. </proplist>
  6842. </compdef>
  6843. </div4>
  6844.  
  6845. <div4 id='xr-pattern'>
  6846. <head>XML Representation of pattern Schema Components</head>
  6847. <p>
  6848. The XML representation for a <compref ref="dc-pattern"/> schema
  6849. component is a <eltref ref="pattern"/> element information item. The
  6850. correspondences between the properties of the information item and
  6851. properties of the component are as follows:
  6852. </p>
  6853.  
  6854. <reprdef eltname="pattern">
  6855. <reprelt eltname="pattern"/>
  6856. <reprcomp abstract="pattern" ref="dc-fractionDigits">
  6857. <reprdep>
  6858. <propref ref="pattern-value"/> <termref def="dt-must"/> be a valid
  6859. <termref def="dt-regex"/>.
  6860. </reprdep>
  6861. <propmap name="pattern-value">
  6862. The &v-value; of the <code>value</code> &i-attribute;
  6863. </propmap>
  6864. <propmap name="defn-annotation">
  6865. The annotations corresponding to all the <eltref ref="annotation"/>
  6866. element information items in the &i-children;, if any.
  6867. </propmap>
  6868. </reprcomp>
  6869. </reprdef>
  6870.  
  6871. </div4>
  6872.  
  6873. <div4 id='pattern-rep-constr'>
  6874. <head>Constraints on XML Representation of pattern</head>
  6875. <constraintnote type="src" id="src-multiple-patterns">
  6876. <head>Multiple patterns</head>
  6877. <p>
  6878. If multiple <eltref ref="pattern"/> element information items appear as
  6879. &i-children; of a <eltref ref="simpleType"/>, the &i-value;s should
  6880. be combined as if they appeared in a single
  6881. <termref def="dt-regex"/> as separate
  6882. <termref def="dt-branch"/>es.
  6883. </p>
  6884. </constraintnote>
  6885.  
  6886. <note>
  6887. <p>
  6888. It is a consequence of the schema representation constraint
  6889. <specref ref='src-multiple-patterns'/> and of the rules for
  6890. <termref def='dt-restriction'/> that <termref def='dt-pattern'/>
  6891. facets specified on the <emph>same</emph> step in a type
  6892. derivation are <strong>OR</strong>ed together, while <termref def='dt-pattern'/>
  6893. facets specified on <emph>different</emph> steps of a type derivation
  6894. are <strong>AND</strong>ed together.
  6895. </p>
  6896. <p>
  6897. Thus, to impose two <termref def='dt-pattern'/> constraints simultaneously,
  6898. schema authors may either write a single <termref def='dt-pattern'/> which
  6899. expresses the intersection of the two <termref def='dt-pattern'/>s they wish to
  6900. impose, or define each <termref def='dt-pattern'/> on a separate type derivation
  6901. step.
  6902. </p>
  6903. </note>
  6904. </div4>
  6905.  
  6906. <div4 id='pattern-validation-rules'>
  6907. <head>pattern Validation Rules</head>
  6908. <constraintnote type="cvc" id="cvc-pattern-valid">
  6909. <head>pattern valid</head>
  6910. <p>
  6911. A literal in a <termref def="dt-lexical-space"/> is facet-valid with
  6912. respect to <termref def="dt-pattern"/> if:
  6913. </p>
  6914. <olist>
  6915. <item>
  6916. <p>
  6917. the literal is among the set of character sequences denoted by
  6918. the <termref def="dt-regex"/> specified in <propref ref="pattern-value"/>.
  6919. </p>
  6920. </item>
  6921. </olist>
  6922. </constraintnote>
  6923. </div4>
  6924.  
  6925. </div3>
  6926.  
  6927. <div3 id='rf-enumeration'>
  6928. <head>enumeration</head>
  6929.  
  6930. <p>
  6931. <termdef id="dt-enumeration" term="enumeration" role='local'>
  6932. <term>enumeration</term> constrains the <termref def="dt-value-space"/>
  6933. to a specified set of values.
  6934. </termdef>
  6935. </p>
  6936. <p>
  6937. <term>enumeration</term> does not impose an order relation on the
  6938. <termref def="dt-value-space"/> it creates; the value of the
  6939. <termref def="dt-ordered"/> property of the <termref def="dt-derived"/>
  6940. datatype remains that of the datatype from which it is
  6941. <termref def="dt-derived"/>.
  6942. </p>
  6943.  
  6944. <p>
  6945. <termref def="dt-enumeration"/> provides for:
  6946. </p>
  6947. <ulist>
  6948. <item>
  6949. <p>
  6950. Constraining a <termref def="dt-value-space"/>
  6951. to a specified set of values.
  6952. </p>
  6953. </item>
  6954. </ulist>
  6955.  
  6956. <note role="example">
  6957. <p>
  6958. The following example is a datatype definition for a
  6959. <termref def="dt-user-derived"/> datatype which limits the values
  6960. of dates to the three US holidays enumerated. This datatype
  6961. definition would appear in a schema authored by an "end-user" and
  6962. shows how to define a datatype by enumerating the values in its
  6963. <termref def="dt-value-space"/>.  The enumerated values must be
  6964. type-valid literals for the <termref def="dt-basetype"/>.
  6965. </p>
  6966. <eg><![CDATA[<simpleType name='holidays'>
  6967.     <annotation>
  6968.         <documentation>some US holidays</documentation>
  6969.     </annotation>
  6970.     <restriction base='gMonthDay'>
  6971.       <enumeration value='--01-01'>
  6972.         <annotation>
  6973.             <documentation>New Year's day</documentation>
  6974.         </annotation>
  6975.       </enumeration>
  6976.       <enumeration value='--07-04'>
  6977.         <annotation>
  6978.             <documentation>4th of July</documentation>
  6979.         </annotation>
  6980.       </enumeration>
  6981.       <enumeration value='--12-25'>
  6982.         <annotation>
  6983.             <documentation>Christmas</documentation>
  6984.         </annotation>
  6985.       </enumeration>
  6986.     </restriction>  
  6987. </simpleType>]]></eg>
  6988. </note>
  6989.  
  6990. <div4 id='dc-enumeration'>
  6991. <head>The enumeration Schema Component</head>
  6992. <compdef name="enumeration" ref="dt-enumeration">
  6993. <proplist>
  6994. <propdef id="enumeration-value" name="value">
  6995. A set of values from the <termref def="dt-value-space"/> of the
  6996. <propref ref="defn-basetype"/>.
  6997. </propdef>
  6998. <propdef id="enumeration-annotation" name="annotation">
  6999. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  7000. </propdef>
  7001. </proplist>
  7002. </compdef>
  7003. </div4>
  7004.  
  7005. <div4 id='xr-enumeration'>
  7006. <head>XML Representation of enumeration Schema Components</head>
  7007. <p>
  7008. The XML representation for an <compref ref="dc-enumeration"/> schema
  7009. component is an <eltref ref="enumeration"/> element information item. The
  7010. correspondences between the properties of the information item and
  7011. properties of the component are as follows:
  7012. </p>
  7013.  
  7014. <reprdef eltname="enumeration">
  7015. <reprelt eltname="enumeration"/>
  7016. <reprcomp abstract="enumeration" ref="dc-enumeration">
  7017. <reprdep>
  7018. <propref ref="enumeration-value"/> <termref def="dt-must"/> be
  7019. in the <termref def='dt-value-space'/> of <propref ref="defn-basetype"/>.
  7020. </reprdep>
  7021. <propmap name="enumeration-value">
  7022. The &v-value; of the <code>value</code> &i-attribute;
  7023. </propmap>
  7024. <propmap name="defn-annotation">
  7025. The annotations corresponding to all the <eltref ref="annotation"/>
  7026. element information items in the &i-children;, if any.
  7027. </propmap>
  7028. </reprcomp>
  7029. </reprdef>
  7030. </div4>
  7031.  
  7032. <div4 id='enumeration-rep-constr'>
  7033. <head>Constraints on XML Representation of enumeration</head>
  7034. <constraintnote type="src" id="src-multiple-enumerations">
  7035. <head>Multiple enumerations</head>
  7036. <p>
  7037. If multiple <eltref ref="enumeration"/> element information items appear
  7038. as &i-children; of a <eltref ref="simpleType"/> the
  7039. <propref ref="enumeration-value"/> of the <compref ref="dc-enumeration"/>
  7040. component should be the set of all such &i-value;s.
  7041. </p>
  7042. </constraintnote>
  7043. </div4>
  7044.  
  7045. <div4 id='enumeration-validation-rules'>
  7046. <head>enumeration Validation Rules</head>
  7047. <constraintnote type="cvc" id="cvc-enumeration-valid">
  7048. <head>enumeration valid</head>
  7049. <p>
  7050. A value in a <termref def="dt-value-space"/> is facet-valid with
  7051. respect to <termref def="dt-enumeration"/> if
  7052. the value is one of the values specified in 
  7053. <propref ref='enumeration-value'/>
  7054. </p>
  7055. </constraintnote>
  7056. </div4>
  7057.  
  7058. <div4 id='enumeration-coss'>
  7059. <head>Constraints on enumeration Schema Components</head>
  7060. <constraintnote type="cos" id="enumeration-valid-restriction">
  7061. <head>enumeration valid restriction</head>
  7062. <p>
  7063. It is an <termref def='dt-error'/> if any member of <propref
  7064. ref='enumeration-value'/> is not in the <termref def='dt-value-space'/>
  7065. of <propref ref='defn-basetype'/>.
  7066. </p>
  7067. </constraintnote>
  7068. </div4>
  7069.  
  7070. </div3>
  7071.  
  7072. <div3 id='rf-whiteSpace'>
  7073. <head>whiteSpace</head>
  7074.  
  7075. <p>
  7076. <termdef id="dt-whiteSpace" term="whiteSpace" role='local'>
  7077. <term>whiteSpace</term> constrains the <termref def="dt-value-space"/>
  7078. of types <termref def="dt-derived"/> from <dtref ref="string"/> such that
  7079. the various behaviors
  7080. specified in <xspecref href="&xmlspec;#AVNormalize">Attribute Value Normalization</xspecref>
  7081. in <bibref ref="XML"/> are realized.  The value of
  7082. <term>whiteSpace</term> must be one of {preserve, replace, collapse}.
  7083. </termdef>
  7084. </p>
  7085. <glist>
  7086. <gitem>
  7087. <label>preserve</label>
  7088. <def>
  7089. <p>
  7090. No normalization is done, the value is not changed (this is the
  7091. behavior required  by <bibref ref="XML"/> for element content)
  7092. </p>
  7093. </def>
  7094. </gitem>
  7095. <gitem>
  7096. <label>replace</label>
  7097. <def>
  7098. <p>
  7099. All occurrences of #x9 (tab), #xA (line feed) and #xD (carriage return)
  7100. are replaced with #x20 (space)
  7101. </p>
  7102. </def>
  7103. </gitem>
  7104. <gitem>
  7105. <label>collapse</label>
  7106. <def>
  7107. <p>
  7108. After the processing implied by <term>replace</term>, contiguous
  7109. sequences of #x20's are collapsed to a single #x20, and leading and
  7110. trailing #x20's are removed.
  7111. </p>
  7112. </def>
  7113. </gitem>
  7114. </glist>
  7115. <note>
  7116. <p>
  7117. The notation #xA used here (and elsewhere in this specification) represents
  7118. the Universal Character Set (UCS) code point <code>hexadecimal A</code> (line feed), which is denoted by
  7119. U+000A.  This notation is to be distinguished from <code>&#xA;</code>,
  7120. which is the XML <xnt href="&xmlspec;#NT-CharRef">character reference</xnt>
  7121. to that same UCS code point.
  7122. </p>
  7123. </note>
  7124. <p>
  7125. <term>whiteSpace</term> is applicable to all <termref def="dt-atomic"/> and
  7126. <termref def="dt-list"/> datatypes.  For all <termref def="dt-atomic"/>
  7127. datatypes other than <dtref ref="string"/> (and types <termref def="dt-derived"/>
  7128. by <termref def='dt-restriction'/> from it) the value of <term>whiteSpace</term> is
  7129. <code>collapse</code> and cannot be changed by a schema author; for
  7130. <dtref ref="string"/> the value of <term>whiteSpace</term> is
  7131. <code>preserve</code>; for any type <termref def="dt-derived"/> by
  7132. <termref def='dt-restriction'/> from
  7133. <dtref ref="string"/> the value of <term>whiteSpace</term> can
  7134. be any of the three legal values.  For all datatypes
  7135. <termref def="dt-derived"/> by <termref def="dt-list"/> the
  7136. value of <term>whiteSpace</term> is <code>collapse</code> and cannot
  7137. be changed by a schema author.  For all datatypes
  7138. <termref def="dt-derived"/> by <termref def="dt-union"/>
  7139.  <term>whiteSpace</term> does not apply directly; however, the
  7140. normalization behavior of <termref def="dt-union"/> types is controlled by
  7141. the value of <term>whiteSpace</term> on that one of the
  7142. <termref def="dt-memberTypes"/> against which the <termref def="dt-union"/>
  7143. is successfully validated.
  7144. </p>
  7145. <note>
  7146. <p>
  7147. For more information on <term>whiteSpace</term>, see the
  7148. discussion on white space normalization in
  7149. <xspecref href="&xsdl;#components">Schema Component Details</xspecref>
  7150. in <bibref ref="structural-schemas"/>.
  7151. </p>
  7152. </note>
  7153.  
  7154. <p>
  7155. <termref def="dt-whiteSpace"/> provides for:
  7156. </p>
  7157. <ulist>
  7158. <item>
  7159. <p>
  7160. Constraining a <termref def="dt-value-space"/> according to
  7161. the white space normalization rules.
  7162. </p>
  7163. </item>
  7164. </ulist>
  7165.  
  7166. <note role="example">
  7167. <p>
  7168. The following example is the datatype definition for
  7169. the <dtref ref="token"/> <termref def="dt-built-in"/> 
  7170. <termref def="dt-derived"/>
  7171. datatype.
  7172. </p>
  7173. <eg><![CDATA[<simpleType name='token'>
  7174.     <restriction base='normalizedString'>
  7175.       <whiteSpace value='collapse'/>
  7176.     </restriction>  
  7177. </simpleType>]]></eg>
  7178. </note>
  7179.  
  7180. <div4 id='dc-whiteSpace'>
  7181. <head>The whiteSpace Schema Component</head>
  7182. <compdef name="whiteSpace" ref="dt-whiteSpace">
  7183. <proplist>
  7184. <propdef id="whiteSpace-value" name="value">
  7185. One of <code>{preserve, replace, collapse}</code>.
  7186. </propdef>
  7187. <propdef id="whiteSpace-fixed" name="fixed">
  7188. A <dtref ref="boolean"/>.
  7189. </propdef>
  7190. <propdef id="whiteSpace-annotation" name="annotation">
  7191. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  7192. </propdef>
  7193. </proplist>
  7194. </compdef>
  7195.  
  7196. <p>
  7197. If <propref ref="whiteSpace-fixed"/> is <emph>true</emph>, then types for which
  7198. the current type is the <propref ref="defn-basetype"/> cannot specify a
  7199. value for <compref ref="dc-whiteSpace"/> other than <propref ref="whiteSpace-value"/>.
  7200. </p>
  7201.  
  7202. </div4>
  7203.  
  7204. <div4 id='xr-whiteSpace'>
  7205. <head>XML Representation of whiteSpace Schema Components</head>
  7206.  
  7207. <p>
  7208. The XML representation for a <compref ref="dc-whiteSpace"/> schema
  7209. component is a <eltref ref="whiteSpace"/> element information item. The
  7210. correspondences between the properties of the information item and
  7211. properties of the component are as follows:
  7212. </p>
  7213.  
  7214. <reprdef eltname="whiteSpace">
  7215. <reprelt eltname="whiteSpace"/>
  7216. <reprcomp abstract="whiteSpace" ref="dc-whiteSpace">
  7217. <propmap name="whiteSpace-value">
  7218. The &v-value; of the <code>value</code> &i-attribute;
  7219. </propmap>
  7220. <propmap name="whiteSpace-fixed">
  7221. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  7222. </propmap>
  7223. <propmap name="defn-annotation">
  7224. The annotations corresponding to all the <eltref ref="annotation"/>
  7225. element information items in the &i-children;, if any.
  7226. </propmap>
  7227. </reprcomp>
  7228. </reprdef>
  7229. </div4>
  7230.  
  7231. <div4 id='whiteSpace-validation-rules'>
  7232. <head>whiteSpace Validation Rules</head>
  7233.  
  7234. <note>
  7235. <p>
  7236. There are no <termref def="dt-cvc"/>s associated <termref def="dt-whiteSpace"/>.
  7237. For more information, see the
  7238. discussion on white space normalization in
  7239. <xspecref href="&xsdl;#components">Schema Component Details</xspecref>
  7240. in <bibref ref="structural-schemas"/>.
  7241. </p>
  7242. </note>
  7243. </div4>
  7244.  
  7245. <div4 id='whiteSpace-coss'>
  7246. <head>Constraints on whiteSpace Schema Components</head>
  7247. <constraintnote type="cos" id="whiteSpace-valid-restriction">
  7248. <head>whiteSpace valid restriction</head>
  7249. <p>
  7250. It is an <termref def="dt-error"/> if <compref ref='dc-whiteSpace'/>
  7251. is among the members of <propref ref='defn-facets'/> of
  7252. <propref ref='defn-basetype'/> and any of the following conditions is
  7253. true:
  7254. </p>
  7255. <olist>
  7256. <item>
  7257. <p>
  7258. <propref ref='whiteSpace-value'/> is <emph>replace</emph> or <emph>preserve</emph>
  7259. and the <propref ref='whiteSpace-value'/> of the parent
  7260. <compref ref='dc-whiteSpace'/> is <emph>collapse</emph>
  7261. </p>
  7262. </item>
  7263. <item>
  7264. <p>
  7265. <propref ref='whiteSpace-value'/> is <emph>preserve</emph>
  7266. and the <propref ref='whiteSpace-value'/> of the parent
  7267. <compref ref='dc-whiteSpace'/> is <emph>replace</emph>
  7268. </p>
  7269. </item>
  7270. </olist>
  7271. </constraintnote>
  7272. </div4>
  7273.  
  7274. </div3>
  7275.  
  7276. <div3 id='rf-maxInclusive'>
  7277. <head>maxInclusive</head>
  7278.  
  7279. <p>
  7280. <termdef id="dt-maxInclusive" term="maxInclusive" role='local'>
  7281. <term>maxInclusive</term> is the <termref def="dt-inclusive-upper-bound"/>
  7282. of the <termref def="dt-value-space"/> for a datatype with the
  7283. <termref def="dt-ordered"/> property.  The value of
  7284. <term>maxInclusive</term> <termref def="dt-must"/> be 
  7285. in the <termref def='dt-value-space'/> of the
  7286. <termref def="dt-basetype"/>.
  7287. </termdef>
  7288. </p>
  7289.  
  7290. <p>
  7291. <termref def="dt-maxInclusive"/> provides for:
  7292. </p>
  7293. <ulist>
  7294. <item>
  7295. <p>
  7296. Constraining a <termref def="dt-value-space"/> to values
  7297. with a specific <termref def="dt-inclusive-upper-bound"/>.
  7298. </p>
  7299. </item>
  7300. </ulist>
  7301.  
  7302. <note role='example'>
  7303. <p>
  7304. The following is the definition of a <termref def="dt-user-derived"/>
  7305. datatype which limits values to integers less than or equal to
  7306. 100, using <termref def="dt-maxInclusive"/>.
  7307. </p>
  7308. <eg><![CDATA[<simpleType name='one-hundred-or-less'>
  7309.   <restriction base='integer'>
  7310.     <maxInclusive value='100'/>
  7311.   </restriction>
  7312. </simpleType>]]></eg>
  7313. </note>
  7314.  
  7315. <div4 id='dc-maxInclusive'>
  7316. <head>The maxInclusive Schema Component</head>
  7317. <compdef name="maxInclusive" ref="dt-maxInclusive">
  7318. <proplist>
  7319. <propdef id="maxInclusive-value" name="value">
  7320. A value from the <termref def="dt-value-space"/> of the
  7321. <propref ref="defn-basetype"/>.
  7322. </propdef>
  7323. <propdef id="maxInclusive-fixed" name="fixed">
  7324. A <dtref ref="boolean"/>.
  7325. </propdef>
  7326. <propdef id="maxInclusive-annotation" name="annotation">
  7327. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  7328. </propdef>
  7329. </proplist>
  7330. </compdef>
  7331.  
  7332. <p>
  7333. If <propref ref="maxInclusive-fixed"/> is <emph>true</emph>, then types for which
  7334. the current type is the <propref ref="defn-basetype"/> cannot specify a
  7335. value for <compref ref="dc-maxInclusive"/> other than <propref ref="maxInclusive-value"/>.
  7336. </p>
  7337. </div4>
  7338.  
  7339. <div4 id='xr-maxInclusive'>
  7340. <head>XML Representation of maxInclusive Schema Components</head>
  7341. <p>
  7342. The XML representation for a <compref ref="dc-maxInclusive"/> schema
  7343. component is a <eltref ref="maxInclusive"/> element information item. The
  7344. correspondences between the properties of the information item and
  7345. properties of the component are as follows:
  7346. </p>
  7347.  
  7348. <reprdef eltname="maxInclusive">
  7349. <reprelt eltname="maxInclusive"/>
  7350. <reprcomp abstract="maxInclusive" ref="dt-maxInclusive">
  7351. <reprdep>
  7352. <propref ref="maxInclusive-value"/> <termref def="dt-must"/> be
  7353. in the <termref def='dt-value-space'/> of <propref ref="defn-basetype"/>.
  7354. </reprdep>
  7355. <propmap name="maxInclusive-value">
  7356. The &v-value; of the <code>value</code> &i-attribute;
  7357. </propmap>
  7358. <propmap name="maxInclusive-fixed">
  7359. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false, if present, otherwise false
  7360. </propmap>
  7361. <propmap name="defn-annotation">
  7362. The annotations corresponding to all the <eltref ref="annotation"/>
  7363. element information items in the &i-children;, if any.
  7364. </propmap>
  7365. </reprcomp>
  7366. </reprdef>
  7367. </div4>
  7368.  
  7369. <div4 id='maxInclusive-validation-rules'>
  7370. <head>maxInclusive Validation Rules</head>
  7371. <constraintnote type="cvc" id="cvc-maxInclusive-valid">
  7372. <head>maxInclusive Valid</head>
  7373. <p>
  7374. A value in an <termref def="dt-ordered"/> <termref def="dt-value-space"/>
  7375. is facet-valid with respect to <termref def="dt-maxInclusive"/>, determined as
  7376. follows:
  7377. </p>
  7378. <olist>
  7379. <item>
  7380. <p>
  7381. if the <termref def="dt-numeric"/> property in
  7382. <propref ref="defn-fund-facets"/> is <emph>true</emph>, then the value
  7383. <termref def="dt-must"/> be numerically less than or
  7384. equal to <propref ref="maxInclusive-value"/>;
  7385. </p>
  7386. </item>
  7387. <item>
  7388. <p>
  7389. if the <termref def="dt-numeric"/> property in 
  7390. <propref ref="defn-fund-facets"/> is <emph>false</emph> (i.e.,
  7391. <propref ref="defn-basetype"/> is one of the date and time related
  7392. datatypes), then the value <termref def="dt-must"/> be chronologically
  7393. less than or equal to <propref ref="maxInclusive-value"/>;
  7394. </p>
  7395. </item>
  7396. </olist>
  7397. </constraintnote>
  7398. </div4>
  7399.  
  7400. <div4 id='maxInclusive-coss'>
  7401. <head>Constraints on maxInclusive Schema Components</head>
  7402. <constraintnote type="cos" id="minInclusive-less-than-equal-to-maxInclusive">
  7403. <head>minInclusive <= maxInclusive</head>
  7404. <p>
  7405. It is an <termref def="dt-error"/> for the value specified for
  7406. <termref def="dt-minInclusive"/> to be greater than the value
  7407. specified for <termref def="dt-maxInclusive"/> for the same datatype.
  7408. </p>
  7409. </constraintnote>
  7410.  
  7411. <constraintnote type="cos" id="maxInclusive-valid-restriction">
  7412. <head>maxInclusive valid restriction</head>
  7413. <p>
  7414. It is an <termref def="dt-error"/> if any of the following conditions
  7415. is true:
  7416. </p>
  7417. <olist>
  7418. <item>
  7419. <p>
  7420. <compref ref='dc-maxInclusive'/> is among the members of
  7421. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7422. and <propref ref='maxInclusive-value'/> is
  7423. greater than the <propref ref='maxInclusive-value'/> of the parent
  7424. <compref ref='dc-maxInclusive'/>
  7425. </p>
  7426. </item>
  7427. <item>
  7428. <p>
  7429. <compref ref='dc-maxExclusive'/> is among the members of
  7430. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7431. and <propref ref='maxInclusive-value'/> is
  7432. greater than or equal to the <propref ref='maxExclusive-value'/> of the parent
  7433. <compref ref='dc-maxExclusive'/>
  7434. </p>
  7435. </item>
  7436. <item>
  7437. <p>
  7438. <compref ref='dc-minInclusive'/> is among the members of
  7439. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7440. and <propref ref='maxInclusive-value'/> is
  7441. less than the <propref ref='minInclusive-value'/> of the parent
  7442. <compref ref='dc-minInclusive'/>
  7443. </p>
  7444. </item>
  7445. <item>
  7446. <p>
  7447. <compref ref='dc-minExclusive'/> is among the members of
  7448. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7449. and <propref ref='maxInclusive-value'/> is
  7450. less than or equal to the <propref ref='minExclusive-value'/> of the parent
  7451. <compref ref='dc-minExclusive'/>
  7452. </p>
  7453. </item>
  7454. </olist>
  7455. </constraintnote>
  7456. </div4>
  7457.  
  7458. </div3>
  7459.  
  7460. <div3 id='rf-maxExclusive'>
  7461. <head>maxExclusive</head>
  7462.  
  7463. <p>
  7464. <termdef id="dt-maxExclusive" term="maxExclusive" role='local'>
  7465. <term>maxExclusive</term> is the <termref def="dt-exclusive-upper-bound"/>
  7466. of the <termref def="dt-value-space"/> for a datatype with the
  7467. <termref def="dt-ordered"/> property.  The value of <term>maxExclusive</term>
  7468.  <termref def='dt-must'/> be in the <termref def='dt-value-space'/> of the
  7469. <termref def="dt-basetype"/>.
  7470. </termdef>
  7471. </p>
  7472.  
  7473. <p>
  7474. <termref def="dt-maxExclusive"/> provides for:
  7475. </p>
  7476. <ulist>
  7477. <item>
  7478. <p>
  7479. Constraining a <termref def="dt-value-space"/> to values
  7480. with a specific <termref def="dt-exclusive-upper-bound"/>.
  7481. </p>
  7482. </item>
  7483. </ulist>
  7484.  
  7485. <note role='example'>
  7486. <p>
  7487. The following is the definition of a <termref def="dt-user-derived"/>
  7488. datatype which limits values to integers less than or equal to
  7489. 100, using <termref def="dt-maxExclusive"/>.
  7490. </p>
  7491. <eg><![CDATA[<simpleType name='less-than-one-hundred-and-one'>
  7492.   <restriction base='integer'>
  7493.     <maxExclusive value='101'/>
  7494.   </restriction>
  7495. </simpleType>]]></eg>
  7496. <p>
  7497. Note that the
  7498. <termref def="dt-value-space"/> of this datatype is identical to
  7499. the previous one (named 'one-hundred-or-less').
  7500. </p>
  7501. </note>
  7502.  
  7503. <div4 id='dc-maxExclusive'>
  7504. <head>The maxExclusive Schema Component</head>
  7505. <compdef name="maxExclusive" ref="dt-maxExclusive">
  7506. <proplist>
  7507. <propdef id="maxExclusive-value" name="value">
  7508. A value from the <termref def="dt-value-space"/> of the
  7509. <propref ref="defn-basetype"/>.
  7510. </propdef>
  7511. <propdef id="maxExclusive-fixed" name="fixed">
  7512. A <dtref ref="boolean"/>.
  7513. </propdef>
  7514. <propdef id="maxExclusive-annotation" name="annotation">
  7515. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  7516. </propdef>
  7517. </proplist>
  7518. </compdef>
  7519.  
  7520. <p>
  7521. If <propref ref="maxExclusive-fixed"/> is <emph>true</emph>, then types for which
  7522. the current type is the <propref ref="defn-basetype"/> cannot specify a
  7523. value for <compref ref="dc-maxExclusive"/> other than <propref ref="maxExclusive-value"/>.
  7524. </p>
  7525. </div4>
  7526.  
  7527. <div4 id='xr-maxExclusive'>
  7528. <head>XML Representation of maxExclusive Schema Components</head>
  7529. <p>
  7530. The XML representation for a <compref ref="dc-maxExclusive"/> schema
  7531. component is a <eltref ref="maxExclusive"/> element information item. The
  7532. correspondences between the properties of the information item and
  7533. properties of the component are as follows:
  7534. </p>
  7535.  
  7536. <reprdef eltname="maxExclusive">
  7537. <reprelt eltname="maxExclusive"/>
  7538. <reprcomp abstract="maxExclusive" ref="dt-maxExclusive">
  7539. <reprdep>
  7540. <propref ref="maxExclusive-value"/> <termref def="dt-must"/> be
  7541. in the <termref def='dt-value-space'/> of <propref ref="defn-basetype"/>.
  7542. </reprdep>
  7543. <propmap name="maxExclusive-value">
  7544. The &v-value; of the <code>value</code> &i-attribute;
  7545. </propmap>
  7546. <propmap name="maxExclusive-fixed">
  7547. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  7548. </propmap>
  7549. <propmap name="defn-annotation">
  7550. The annotations corresponding to all the <eltref ref="annotation"/>
  7551. element information items in the &i-children;, if any.
  7552. </propmap>
  7553. </reprcomp>
  7554. </reprdef>
  7555. </div4>
  7556.  
  7557. <div4 id='maxExclusive-validation-rules'>
  7558. <head>maxExclusive Validation Rules</head>
  7559. <constraintnote type="cvc" id="cvc-maxExclusive-valid">
  7560. <head>maxExclusive Valid</head>
  7561. <p>
  7562. A value in an <termref def="dt-ordered"/> <termref def="dt-value-space"/>
  7563. is facet-valid with respect to <termref def="dt-maxExclusive"/>, determined
  7564. as follows:
  7565. </p>
  7566. <olist>
  7567. <item>
  7568. <p>
  7569. if the <termref def="dt-numeric"/> property in
  7570. <propref ref="defn-fund-facets"/> is <emph>true</emph>, then the
  7571. value <termref def="dt-must"/> be numerically less than
  7572. <propref ref="maxExclusive-value"/>;
  7573. </p>
  7574. </item>
  7575. <item>
  7576. <p>
  7577. if the <termref def="dt-numeric"/> property in 
  7578. <propref ref="defn-fund-facets"/> is <emph>false</emph> (i.e.,
  7579. <propref ref="defn-basetype"/> is one of the date and time related
  7580. datatypes), then the value <termref def="dt-must"/> be chronologically
  7581. less than <propref ref="maxExclusive-value"/>;
  7582. </p>
  7583. </item>
  7584. </olist>
  7585. </constraintnote>
  7586. </div4>
  7587.  
  7588. <div4 id='maxExclusive-coss'>
  7589. <head>Constraints on maxExclusive Schema Components</head>
  7590. <constraintnote type="cos" id="maxInclusive-maxExclusive">
  7591. <head>maxInclusive and maxExclusive</head>
  7592. <p>
  7593. It is an <termref def="dt-error"/> for both
  7594. <termref def="dt-maxInclusive"/> and <termref def="dt-maxExclusive"/>
  7595. to be specified in the same derivation step of a datatype definition.
  7596. </p>
  7597. </constraintnote>
  7598.  
  7599. <constraintnote type="cos" id="minExclusive-less-than-equal-to-maxExclusive">
  7600. <head>minExclusive <= maxExclusive</head>
  7601. <p>
  7602. It is an <termref def="dt-error"/> for the value specified for
  7603. <termref def="dt-minExclusive"/> to be greater than the value
  7604. specified for <termref def="dt-maxExclusive"/> for the same datatype.
  7605. </p>
  7606. </constraintnote>
  7607.  
  7608. <constraintnote type="cos" id="maxExclusive-valid-restriction">
  7609. <head>maxExclusive valid restriction</head>
  7610. <p>
  7611. It is an <termref def="dt-error"/> if any of the following conditions
  7612. is true:
  7613. </p>
  7614. <olist>
  7615. <item>
  7616. <p>
  7617. <compref ref='dc-maxExclusive'/> is among the members of
  7618. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7619. and <propref ref='maxExclusive-value'/> is
  7620. greater than the <propref ref='maxExclusive-value'/> of the parent
  7621. <compref ref='dc-maxExclusive'/>
  7622. </p>
  7623. </item>
  7624. <item>
  7625. <p>
  7626. <compref ref='dc-maxInclusive'/> is among the members of
  7627. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7628. and <propref ref='maxExclusive-value'/> is
  7629. greater than the <propref ref='maxInclusive-value'/> of the parent
  7630. <compref ref='dc-maxInclusive'/>
  7631. </p>
  7632. </item>
  7633. <item>
  7634. <p>
  7635. <compref ref='dc-minInclusive'/> is among the members of
  7636. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7637. and <propref ref='maxExclusive-value'/> is
  7638. less than or equal to the <propref ref='minInclusive-value'/> of the parent
  7639. <compref ref='dc-minInclusive'/>
  7640. </p>
  7641. </item>
  7642. <item>
  7643. <p>
  7644. <compref ref='dc-minExclusive'/> is among the members of
  7645. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7646. and <propref ref='maxExclusive-value'/> is
  7647. less than or equal to the <propref ref='minExclusive-value'/> of the parent
  7648. <compref ref='dc-minExclusive'/>
  7649. </p>
  7650. </item>
  7651. </olist>
  7652. </constraintnote>
  7653. </div4>
  7654.  
  7655. </div3>
  7656.  
  7657. <div3 id='rf-minExclusive'>
  7658. <head>minExclusive</head>
  7659.  
  7660. <p>
  7661. <termdef id="dt-minExclusive" term="minExclusive" role='local'>
  7662. <term>minExclusive</term> is the <termref def="dt-exclusive-lower-bound"/>
  7663. of the <termref def="dt-value-space"/> for a datatype with the
  7664. <termref def="dt-ordered"/> property.
  7665. The value of <term>minExclusive</term> <termref def="dt-must"/>
  7666. be in the <termref def='dt-value-space'/> of the
  7667. <termref def="dt-basetype"/>.
  7668. </termdef>
  7669. </p>
  7670.  
  7671. <p>
  7672. <termref def="dt-minExclusive"/> provides for:
  7673. </p>
  7674. <ulist>
  7675. <item>
  7676. <p>
  7677. Constraining a <termref def="dt-value-space"/> to values
  7678. with a specific <termref def="dt-exclusive-lower-bound"/>.
  7679. </p>
  7680. </item>
  7681. </ulist>
  7682.  
  7683. <note role='example'>
  7684. <p>
  7685. The following is the definition of a <termref def="dt-user-derived"/>
  7686. datatype which limits values to integers greater than or equal to
  7687. 100, using <termref def="dt-minExclusive"/>.
  7688. </p>
  7689. <eg><![CDATA[<simpleType name='more-than-ninety-nine'>
  7690.   <restriction base='integer'>
  7691.     <minExclusive value='99'/>
  7692.   </restriction>
  7693. </simpleType>]]></eg>
  7694. <p>
  7695. Note that the
  7696. <termref def="dt-value-space"/> of this datatype is identical to
  7697. the previous one (named 'one-hundred-or-more').
  7698. </p>
  7699. </note>
  7700.  
  7701. <div4 id='dc-minExclusive'>
  7702. <head>The minExclusive Schema Component</head>
  7703. <compdef name="minExclusive" ref="dt-minExclusive">
  7704. <proplist>
  7705. <propdef id="minExclusive-value" name="value">
  7706. A value from the <termref def="dt-value-space"/> of the
  7707. <propref ref="defn-basetype"/>.
  7708. </propdef>
  7709. <propdef id="minExclusive-fixed" name="fixed">
  7710. A <dtref ref="boolean"/>.
  7711. </propdef>
  7712. <propdef id="minExclusive-annotation" name="annotation">
  7713. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  7714. </propdef>
  7715. </proplist>
  7716. </compdef>
  7717.  
  7718. <p>
  7719. If <propref ref="minExclusive-fixed"/> is <emph>true</emph>, then types for which
  7720. the current type is the <propref ref="defn-basetype"/> cannot specify a
  7721. value for <compref ref="dc-minExclusive"/> other than <propref ref="minExclusive-value"/>.
  7722. </p>
  7723. </div4>
  7724.  
  7725. <div4 id='xr-minExclusive'>
  7726. <head>XML Representation of minExclusive Schema Components</head>
  7727.  
  7728. <p>
  7729. The XML representation for a <compref ref="dc-minExclusive"/> schema
  7730. component is a <eltref ref="minExclusive"/> element information item. The
  7731. correspondences between the properties of the information item and
  7732. properties of the component are as follows:
  7733. </p>
  7734.  
  7735. <reprdef eltname="minExclusive">
  7736. <reprelt eltname="minExclusive"/>
  7737. <reprcomp abstract="minExclusive" ref="dt-minExclusive">
  7738. <reprdep>
  7739. <propref ref="minExclusive-value"/> <termref def="dt-must"/> be
  7740. in the <termref def='dt-value-space'/> of <propref ref="defn-basetype"/>.
  7741. </reprdep>
  7742. <propmap name="minExclusive-value">
  7743. The &v-value; of the <code>value</code> &i-attribute;
  7744. </propmap>
  7745. <propmap name="minExclusive-fixed">
  7746. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  7747. </propmap>
  7748. <propmap name="defn-annotation">
  7749. The annotations corresponding to all the <eltref ref="annotation"/>
  7750. element information items in the &i-children;, if any.
  7751. </propmap>
  7752. </reprcomp>
  7753. </reprdef>
  7754. </div4>
  7755.  
  7756. <div4 id='minExclusive-validation-rules'>
  7757. <head>minExclusive Validation Rules</head>
  7758. <constraintnote type="cvc" id="cvc-minExclusive-valid">
  7759. <head>minExclusive Valid</head>
  7760. <p>
  7761. A value in an <termref def="dt-ordered"/> <termref def="dt-value-space"/>
  7762. is facet-valid with respect to <termref def="dt-minExclusive"/> if:
  7763. </p>
  7764. <olist>
  7765. <item>
  7766. <p>
  7767. if the <termref def="dt-numeric"/> property in
  7768. <propref ref="defn-fund-facets"/> is <emph>true</emph>, then the
  7769. value <termref def="dt-must"/> be numerically greater than
  7770. <propref ref="minExclusive-value"/>;
  7771. </p>
  7772. </item>
  7773. <item>
  7774. <p>
  7775. if the <termref def="dt-numeric"/> property in 
  7776. <propref ref="defn-fund-facets"/> is <emph>false</emph> (i.e.,
  7777. <propref ref="defn-basetype"/> is one of the date and time related
  7778. datatypes), then the value <termref def="dt-must"/> be chronologically
  7779. greater than <propref ref="minExclusive-value"/>;
  7780. </p>
  7781. </item>
  7782. </olist>
  7783. </constraintnote>
  7784. </div4>
  7785.  
  7786. <div4 id='minExclusive-coss'>
  7787. <head>Constraints on minExclusive Schema Components</head>
  7788. <constraintnote type="cos" id="minInclusive-minExclusive">
  7789. <head>minInclusive and minExclusive</head>
  7790. <p>
  7791. It is an <termref def="dt-error"/> for both
  7792. <termref def="dt-minInclusive"/> and <termref def="dt-minExclusive"/>
  7793. to be specified for the same datatype.
  7794. </p>
  7795. </constraintnote>
  7796.  
  7797. <constraintnote type="cos" id="minExclusive-less-than-maxInclusive">
  7798. <head>minExclusive < maxInclusive</head>
  7799. <p>
  7800. It is an <termref def="dt-error"/> for the value specified for
  7801. <termref def="dt-minExclusive"/> to be greater than or equal to the value
  7802. specified for <termref def="dt-maxInclusive"/> for the same datatype.
  7803. </p>
  7804. </constraintnote>
  7805.  
  7806. <constraintnote type="cos" id="minExclusive-valid-restriction">
  7807. <head>minExclusive valid restriction</head>
  7808. <p>
  7809. It is an <termref def="dt-error"/> if any of the following conditions
  7810. is true:
  7811. </p>
  7812. <olist>
  7813. <item>
  7814. <p>
  7815. <compref ref='dc-minExclusive'/> is among the members of
  7816. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7817. and <propref ref='minExclusive-value'/> is
  7818. less than the <propref ref='minExclusive-value'/> of the parent
  7819. <compref ref='dc-minExclusive'/>
  7820. </p>
  7821. </item>
  7822. <item>
  7823. <p>
  7824. <compref ref='dc-maxInclusive'/> is among the members of
  7825. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7826. and <propref ref='minExclusive-value'/> is
  7827. greater the <propref ref='maxInclusive-value'/> of the parent
  7828. <compref ref='dc-maxInclusive'/>
  7829. </p>
  7830. </item>
  7831. <item>
  7832. <p>
  7833. <compref ref='dc-minInclusive'/> is among the members of
  7834. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7835. and <propref ref='minExclusive-value'/> is
  7836. less than the <propref ref='minInclusive-value'/> of the parent
  7837. <compref ref='dc-minInclusive'/>
  7838. </p>
  7839. </item>
  7840. <item>
  7841. <p>
  7842. <compref ref='dc-maxExclusive'/> is among the members of
  7843. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  7844. and <propref ref='maxExclusive-value'/> is
  7845. greater than or equal to the <propref ref='maxExclusive-value'/> of the parent
  7846. <compref ref='dc-maxExclusive'/>
  7847. </p>
  7848. </item>
  7849. </olist>
  7850. </constraintnote>
  7851. </div4>
  7852.  
  7853. </div3>
  7854.  
  7855. <div3 id='rf-minInclusive'>
  7856. <head>minInclusive</head>
  7857.  
  7858. <p>
  7859. <termdef id="dt-minInclusive" term="minInclusive" role='local'>
  7860. <term>minInclusive</term> is the <termref def="dt-inclusive-lower-bound"/>
  7861. of the <termref def="dt-value-space"/> for a datatype with the
  7862. <termref def="dt-ordered"/> property.  The value of
  7863. <term>minInclusive</term>
  7864.  <termref def='dt-must'/> be in the <termref def='dt-value-space'/> of the
  7865. <termref def="dt-basetype"/>.
  7866. </termdef>
  7867. </p>
  7868.  
  7869. <p>
  7870. <termref def="dt-minInclusive"/> provides for:
  7871. </p>
  7872. <ulist>
  7873. <item>
  7874. <p>
  7875. Constraining a <termref def="dt-value-space"/> to values
  7876. with a specific <termref def="dt-inclusive-lower-bound"/>.
  7877. </p>
  7878. </item>
  7879. </ulist>
  7880.  
  7881. <note role='example'>
  7882. <p>
  7883. The following is the definition of a <termref def="dt-user-derived"/>
  7884. datatype which limits values to integers greater than or equal to
  7885. 100, using <termref def="dt-minInclusive"/>.
  7886. </p>
  7887. <eg><![CDATA[<simpleType name='one-hundred-or-more'>
  7888.   <restriction base='integer'>
  7889.     <minInclusive value='100'/>
  7890.   </restriction>
  7891. </simpleType>]]></eg>
  7892. </note>
  7893.  
  7894. <div4 id='dc-minInclusive'>
  7895. <head>The minInclusive Schema Component</head>
  7896. <compdef name="minInclusive" ref="dt-minInclusive">
  7897. <proplist>
  7898. <propdef id="minInclusive-value" name="value">
  7899. A value from the <termref def="dt-value-space"/> of the
  7900. <propref ref="defn-basetype"/>.
  7901. </propdef>
  7902. <propdef id="minInclusive-fixed" name="fixed">
  7903. A <dtref ref="boolean"/>.
  7904. </propdef>
  7905. <propdef id="minInclusive-annotation" name="annotation">
  7906. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  7907. </propdef>
  7908. </proplist>
  7909. </compdef>
  7910.  
  7911. <p>
  7912. If <propref ref="minInclusive-fixed"/> is <emph>true</emph>, then types for which
  7913. the current type is the <propref ref="defn-basetype"/> cannot specify a
  7914. value for <compref ref="dc-minInclusive"/> other than <propref ref="minInclusive-value"/>.
  7915. </p>
  7916. </div4>
  7917.  
  7918. <div4 id='xr-minInclusive'>
  7919. <head>XML Representation of minInclusive Schema Components</head>
  7920. <p>
  7921. The XML representation for a <compref ref="dc-minInclusive"/> schema
  7922. component is a <eltref ref="minInclusive"/> element information item. The
  7923. correspondences between the properties of the information item and
  7924. properties of the component are as follows:
  7925. </p>
  7926.  
  7927. <reprdef eltname="minInclusive">
  7928. <reprelt eltname="minInclusive"/>
  7929. <reprcomp abstract="minInclusive" ref="dt-minInclusive">
  7930. <reprdep>
  7931. <propref ref="minInclusive-value"/> <termref def="dt-must"/> be
  7932. in the <termref def='dt-value-space'/> of <propref ref="defn-basetype"/>.
  7933. </reprdep>
  7934. <propmap name="minInclusive-value">
  7935. The &v-value; of the <code>value</code> &i-attribute;
  7936. </propmap>
  7937. <propmap name="minInclusive-fixed">
  7938. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  7939. </propmap>
  7940. <propmap name="defn-annotation">
  7941. The annotations corresponding to all the <eltref ref="annotation"/>
  7942. element information items in the &i-children;, if any.
  7943. </propmap>
  7944. </reprcomp>
  7945. </reprdef>
  7946. </div4>
  7947.  
  7948. <div4 id='minInclusive-validation-rules'>
  7949. <head>minInclusive Validation Rules</head>
  7950. <constraintnote type="cvc" id="cvc-minInclusive-valid">
  7951. <head>minInclusive Valid</head>
  7952. <p>
  7953. A value in an <termref def="dt-ordered"/> <termref def="dt-value-space"/>
  7954. is facet-valid with respect to <termref def="dt-minInclusive"/> if:
  7955. </p>
  7956. <olist>
  7957. <item>
  7958. <p>
  7959. if the <termref def="dt-numeric"/> property in
  7960. <propref ref="defn-fund-facets"/> is <emph>true</emph>, then the
  7961. value <termref def="dt-must"/> be numerically greater than or equal to 
  7962. <propref ref="minInclusive-value"/>;
  7963. </p>
  7964. </item>
  7965. <item>
  7966. <p>
  7967. if the <termref def="dt-numeric"/> property in 
  7968. <propref ref="defn-fund-facets"/> is <emph>false</emph> (i.e.,
  7969. <propref ref="defn-basetype"/> is one of the date and time related
  7970. datatypes), then the value <termref def="dt-must"/> be chronologically
  7971. greater than or equal to <propref ref="minInclusive-value"/>;
  7972. </p>
  7973. </item>
  7974. </olist>
  7975. </constraintnote>
  7976. </div4>
  7977.  
  7978. <div4 id='minInclusive-coss'>
  7979. <head>Constraints on minInclusive Schema Components</head>
  7980. <constraintnote type="cos" id="minInclusive-less-than-maxExclusive">
  7981. <head>minInclusive < maxExclusive</head>
  7982. <p>
  7983. It is an <termref def="dt-error"/> for the value specified for
  7984. <termref def="dt-minInclusive"/> to be greater than or equal to the value
  7985. specified for <termref def="dt-maxExclusive"/> for the same datatype.
  7986. </p>
  7987. </constraintnote>
  7988.  
  7989. <constraintnote type="cos" id="minInclusive-valid-restriction">
  7990. <head>minInclusive valid restriction</head>
  7991. <p>
  7992. It is an <termref def="dt-error"/> if any of the following conditions
  7993. is true:
  7994. </p>
  7995. <olist>
  7996. <item>
  7997. <p>
  7998. <compref ref='dc-minInclusive'/> is among the members of
  7999. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  8000. and <propref ref='minInclusive-value'/> is
  8001. less than the <propref ref='minInclusive-value'/> of the parent
  8002. <compref ref='dc-minInclusive'/>
  8003. </p>
  8004. </item>
  8005. <item>
  8006. <p>
  8007. <compref ref='dc-maxInclusive'/> is among the members of
  8008. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  8009. and <propref ref='minInclusive-value'/> is
  8010. greater the <propref ref='maxInclusive-value'/> of the parent
  8011. <compref ref='dc-maxInclusive'/>
  8012. </p>
  8013. </item>
  8014. <item>
  8015. <p>
  8016. <compref ref='dc-minExclusive'/> is among the members of
  8017. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  8018. and <propref ref='minInclusive-value'/> is
  8019. less than or equal to the <propref ref='minExclusive-value'/> of the parent
  8020. <compref ref='dc-minExclusive'/>
  8021. </p>
  8022. </item>
  8023. <item>
  8024. <p>
  8025. <compref ref='dc-maxExclusive'/> is among the members of
  8026. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  8027. and <propref ref='minInclusive-value'/> is
  8028. greater than or equal to the <propref ref='maxExclusive-value'/> of the parent
  8029. <compref ref='dc-maxExclusive'/>
  8030. </p>
  8031. </item>
  8032. </olist>
  8033. </constraintnote>
  8034. </div4>
  8035.  
  8036. </div3>
  8037.  
  8038. <div3 id='rf-totalDigits'>
  8039. <head>totalDigits</head>
  8040.  
  8041. <p>
  8042. <termdef id="dt-totalDigits" term="totalDigits" role='local'>
  8043. <term>totalDigits</term>
  8044. is the maximum number of digits in values of datatypes
  8045. <termref def="dt-derived"/> from <dtref ref='decimal'/>.  The value of
  8046. <term>totalDigits</term> <termref def="dt-must"/> be a
  8047. <dtref ref="positiveInteger"/>.
  8048. </termdef>
  8049. </p>
  8050.  
  8051. <p>
  8052. <termref def="dt-totalDigits"/> provides for:
  8053. </p>
  8054. <ulist>
  8055. <item>
  8056. <p>
  8057. Constraining a <termref def="dt-value-space"/> to values
  8058. with a specific maximum number of decimal digits (#x30-#x39).
  8059. </p>
  8060. </item>
  8061. </ulist>
  8062.  
  8063. <note role="example">
  8064. <p>
  8065. The following is the definition of a <termref def="dt-user-derived"/>
  8066. datatype which could be used to represent monetary amounts, such as
  8067. in a financial management application which does not have figures
  8068. of $1M or more and only allows whole cents. This definition would appear
  8069. in a schema authored by an "end-user" and shows how to define a datatype by
  8070. specifying facet values which constrain the range of the
  8071. <termref def="dt-basetype"/> in a manner specific to the
  8072. <termref def="dt-basetype"/> (different than specifying max/min values
  8073. as before).
  8074. </p>
  8075. <eg><![CDATA[<simpleType name='amount'>
  8076.   <restriction base='decimal'>
  8077.     <totalDigits value='8'/>
  8078.     <fractionDigits value='2' fixed='true'/>
  8079.   </restriction>
  8080. </simpleType>]]></eg>
  8081. </note>
  8082.  
  8083. <div4 id='dc-totalDigits'>
  8084. <head>The totalDigits Schema Component</head>
  8085. <compdef name="totalDigits" ref="dt-totalDigits">
  8086. <proplist>
  8087. <propdef id="totalDigits-value" name="value">
  8088. A <dtref ref="positiveInteger"/>.
  8089. </propdef>
  8090. <propdef id="totalDigits-fixed" name="fixed">
  8091. A <dtref ref="boolean"/>.
  8092. </propdef>
  8093. <propdef id="totalDigits-annotation" name="annotation">
  8094. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  8095. </propdef>
  8096. </proplist>
  8097. </compdef>
  8098.  
  8099. <p>
  8100. If <propref ref="totalDigits-fixed"/> is <emph>true</emph>, then types for which
  8101. the current type is the <propref ref="defn-basetype"/> cannot specify a
  8102. value for <compref ref="dc-totalDigits"/> other than
  8103. <propref ref="totalDigits-value"/>.
  8104. </p>
  8105. </div4>
  8106.  
  8107. <div4 id='xr-totalDigits'>
  8108. <head>XML Representation of totalDigits Schema Components</head>
  8109.  
  8110. <p>
  8111. The XML representation for a <compref ref="dc-totalDigits"/> schema
  8112. component is a <eltref ref="totalDigits"/> element information item. The
  8113. correspondences between the properties of the information item and
  8114. properties of the component are as follows:
  8115. </p>
  8116.  
  8117. <reprdef eltname="totalDigits">
  8118. <reprelt eltname="totalDigits"/>
  8119. <reprcomp abstract="totalDigits" ref="dc-totalDigits">
  8120. <propmap name="totalDigits-value">
  8121. The &v-value; of the <code>value</code> &i-attribute;
  8122. </propmap>
  8123. <propmap name="totalDigits-fixed">
  8124. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  8125. </propmap>
  8126. <propmap name="defn-annotation">
  8127. The annotations corresponding to all the <eltref ref="annotation"/>
  8128. element information items in the &i-children;, if any.
  8129. </propmap>
  8130. </reprcomp>
  8131. </reprdef>
  8132. </div4>
  8133.  
  8134. <div4 id='totalDigits-validation-rules'>
  8135. <head>totalDigits Validation Rules</head>
  8136. <constraintnote type="cvc" id="cvc-totalDigits-valid">
  8137. <head>totalDigits Valid</head>
  8138. <p>
  8139. A value in a <termref def="dt-value-space"/> is facet-valid with
  8140. respect to <termref def="dt-totalDigits"/> if:
  8141. </p>
  8142. <olist>
  8143. <item>
  8144. <p>
  8145. the number of decimal digits in the value is less than or equal to
  8146. <propref ref="totalDigits-value"/>;
  8147. </p>
  8148. </item>
  8149. </olist>
  8150. </constraintnote>
  8151. </div4>
  8152.  
  8153. <div4 id='totalDigits-coss'>
  8154. <head>Constraints on totalDigits Schema Components</head>
  8155. <constraintnote type="cos" id="totalDigits-valid-restriction">
  8156. <head>totalDigits valid restriction</head>
  8157. <p>
  8158. It is an <termref def="dt-error"/> if
  8159. <compref ref='dc-totalDigits'/> is among the members of
  8160. <propref ref='defn-facets'/> of <propref ref='defn-basetype'/>
  8161. and <propref ref='totalDigits-value'/> is
  8162. greater than the <propref ref='totalDigits-value'/> of the parent
  8163. <compref ref='dc-totalDigits'/>
  8164. </p>
  8165. </constraintnote>
  8166.  
  8167. </div4>
  8168.  
  8169. </div3>
  8170.  
  8171. <div3 id='rf-fractionDigits'>
  8172. <head>fractionDigits</head>
  8173.  
  8174. <p>
  8175. <termdef id="dt-fractionDigits" term="fractionDigits" role='local'>
  8176. <term>fractionDigits</term>
  8177. is the maximum number of digits in the fractional part
  8178. of values of datatypes <termref def="dt-derived"/> from
  8179. <dtref ref='decimal'/>. The value of <term>fractionDigits</term>
  8180.  <termref def="dt-must"/> be a <dtref ref="nonNegativeInteger"/> .
  8181. </termdef>
  8182. </p>
  8183.  
  8184. <p>
  8185. <termref def="dt-fractionDigits"/> provides for:
  8186. </p>
  8187. <ulist>
  8188. <item>
  8189. <p>
  8190. Constraining a <termref def="dt-value-space"/> to values
  8191. with a specific maximum number of decimal digits in the fractional
  8192. part.
  8193. </p>
  8194. </item>
  8195. </ulist>
  8196.  
  8197. <note role="example">
  8198. <p>
  8199. The following is the definition of a <termref def="dt-user-derived"/>
  8200. datatype which could be used to represent the magnitude
  8201. of a person's body temperature on the Celsius scale.
  8202. This definition would appear in a schema authored by an "end-user"
  8203. and shows how to define a datatype by specifying facet values which
  8204. constrain the range of the <termref def="dt-basetype"/>.
  8205. </p>
  8206. <eg><![CDATA[<simpleType name='celsiusBodyTemp'>
  8207.   <restriction base='decimal'>
  8208.     <totalDigits value='4'/>
  8209.     <fractionDigits value='1'/>
  8210.     <minInclusive value='36.4'/>
  8211.     <maxInclusive value='40.5'/>
  8212.   </restriction>
  8213. </simpleType>
  8214. ]]></eg>
  8215. </note>
  8216.  
  8217. <div4 id='dc-fractionDigits'>
  8218. <head>The fractionDigits Schema Component</head>
  8219. <compdef name="fractionDigits" ref="dt-fractionDigits">
  8220. <proplist>
  8221. <propdef id="fractionDigits-value" name="value">
  8222. A <dtref ref="nonNegativeInteger"/>.
  8223. </propdef>
  8224. <propdef id="fractionDigits-fixed" name="fixed">
  8225. A <dtref ref="boolean"/>.
  8226. </propdef>
  8227. <propdef id="fractionDigits-annotation" name="annotation">
  8228. Optional.  An <xspecref href="&xsdl;#Annotation">annotation</xspecref>.
  8229. </propdef>
  8230. </proplist>
  8231. </compdef>
  8232.  
  8233. <p>
  8234. If <propref ref="fractionDigits-fixed"/> is <emph>true</emph>, then types for which
  8235. the current type is the <propref ref="defn-basetype"/> cannot specify a
  8236. value for <compref ref="dc-fractionDigits"/> other than
  8237. <propref ref="fractionDigits-value"/>.
  8238. </p>
  8239. </div4>
  8240.  
  8241. <div4 id='xr-fractionDigits'>
  8242. <head>XML Representation of fractionDigits Schema Components</head>
  8243.  
  8244. <p>
  8245. The XML representation for a <compref ref="dc-fractionDigits"/> schema
  8246. component is a <eltref ref="fractionDigits"/> element information item. The
  8247. correspondences between the properties of the information item and
  8248. properties of the component are as follows:
  8249. </p>
  8250.  
  8251. <reprdef eltname="fractionDigits">
  8252. <reprelt eltname="fractionDigits"/>
  8253. <reprcomp abstract="fractionDigits" ref="dc-fractionDigits">
  8254. <propmap name="fractionDigits-value">
  8255. The &v-value; of the <code>value</code> &i-attribute;
  8256. </propmap>
  8257. <propmap name="fractionDigits-fixed">
  8258. The &v-value; of the <code>fixed</code> &i-attribute;, if present, otherwise false
  8259. </propmap>
  8260. <propmap name="defn-annotation">
  8261. The annotations corresponding to all the <eltref ref="annotation"/>
  8262. element information items in the &i-children;, if any.
  8263. </propmap>
  8264. </reprcomp>
  8265. </reprdef>
  8266. </div4>
  8267.  
  8268. <div4 id='fractionDigits-validation-rules'>
  8269. <head>fractionDigits Validation Rules</head>
  8270. <constraintnote type="cvc" id="cvc-fractionDigits-valid">
  8271. <head>fractionDigits Valid</head>
  8272. <p>
  8273. A value in a <termref def="dt-value-space"/> is facet-valid with
  8274. respect to <termref def="dt-fractionDigits"/> if:
  8275. </p>
  8276. <olist>
  8277. <item>
  8278. <p>
  8279. the number of decimal digits in the fractional part of the
  8280. value is less than or equal to <propref ref="fractionDigits-value"/>;
  8281. </p>
  8282. </item>
  8283. </olist>
  8284. </constraintnote>
  8285. </div4>
  8286.  
  8287. <div4 id='fractionDigits-coss'>
  8288. <head>Constraints on fractionDigits Schema Components</head>
  8289. <constraintnote type="cos" id="fractionDigits-totalDigits">
  8290. <head>fractionDigits less than or equal to totalDigits</head>
  8291. <p>
  8292. It is an <termref def="dt-error"/> for <termref def="dt-fractionDigits"/> to
  8293. be greater than <termref def="dt-totalDigits"/>.
  8294. </p>
  8295. </constraintnote>
  8296. </div4>
  8297. </div3>
  8298.  
  8299. </div2>
  8300.  
  8301. </div1>
  8302.  
  8303. <div1 id="conformance">
  8304. <head>Conformance</head>
  8305. <p>
  8306. This specification describes two levels of conformance for
  8307. datatype processors.  The first is
  8308. required of all processors.  Support for the other will depend on the
  8309. application environments for which the processor is intended.
  8310. </p>
  8311. <p>
  8312. <termdef id="dt-minimally-conforming" term="minimally conforming">
  8313. <term>Minimally conforming</term> processors <termref def="dt-must"/>
  8314. completely and correctly implement the <termref def="dt-cos"/> and
  8315. <termref def="dt-cvc"/>
  8316. .
  8317. </termdef>
  8318. </p>
  8319. <p>
  8320. <termdef id="dt-interchange" term="conformance to the XML Representation
  8321. of Schemas">
  8322. Processors which accept schemas in the form of XML documents as described
  8323. in <specref ref="xr-defn"/> (and other relevant portions of
  8324. <specref ref='datatype-components'/>) are additionally said to provide
  8325. <term>conformance to the XML Representation of Schemas</term>,
  8326. and <termref def="dt-must"/>, when processing schema documents, completely and
  8327. correctly implement all
  8328. <termref def="dt-src"/>s
  8329. in this specification, and <termref def="dt-must"/> adhere exactly to the
  8330. specifications in <specref ref="xr-defn"/>  (and other relevant portions of
  8331. <specref ref='datatype-components'/>) for mapping
  8332. the contents of such
  8333. documents to <xtermref href="&xsdl;#key-component">schema components</xtermref>
  8334. for use in validation.
  8335. </termdef>
  8336. </p>
  8337. <note>
  8338. <p>
  8339. By separating the conformance requirements relating to the concrete
  8340. syntax of XML schema documents, this specification admits processors
  8341. which validate using schemas stored in optimized binary representations,
  8342. dynamically created schemas represented as programming language data
  8343. structures, or implementations in which particular schemas are compiled
  8344. into executable code such as C or Java.  Such processors can be said to
  8345. be <termref def="dt-minimally-conforming">minimally conforming</termref>
  8346. but not necessarily in <termref def="dt-interchange">conformance to
  8347. the XML Representation of Schemas</termref>.
  8348. </p>
  8349. </note>
  8350. </div1>
  8351.  
  8352. </body>
  8353. <back>
  8354. <div1 id="schema">
  8355. <head>Schema for Datatype Definitions (normative)</head>
  8356. <eg xml:space="preserve" text="http://www.w3.org/2001/05/datatypes.xsd.txt"/>
  8357. </div1>
  8358. <div1 id="dtd-for-datatypeDefs">
  8359. <head>DTD for Datatype Definitions (non-normative)</head>
  8360. <eg xml:space="preserve" text="http://www.w3.org/2001/05/datatypes.dtd.txt"/>
  8361. </div1>
  8362. <div1>
  8363. <head>Datatypes and Facets</head>
  8364. <div2 id="app-fundamental-facets">
  8365. <head>Fundamental Facets</head>
  8366. <p>
  8367. The following table shows the values of the fundamental facets
  8368. for each <termref def="dt-built-in"/> datatype.
  8369. </p>
  8370. <fundamental-facets/>
  8371. </div2>
  8372. </div1>
  8373. <div1 id="isoformats">
  8374. <head>ISO 8601 Date and Time Formats</head>
  8375. <div2 id="formatdetails">
  8376. <head>ISO 8601 Conventions</head>
  8377. <p>
  8378. The <termref def="dt-primitive"/> datatypes 
  8379. <dtref ref="duration"/>, <dtref ref="dateTime"/>, <dtref ref="time"/>,
  8380. <dtref ref="date"/>, <dtref ref="gYearMonth"/>,  <dtref ref="gMonthDay"/>, 
  8381. <dtref ref="gDay"/>, <dtref ref="gMonth"/> and <dtref ref="gYear"/>
  8382. use lexical formats inspired by
  8383. <bibref ref="ISO8601"/>.  This appendix provides more detail on the ISO
  8384. formats and discusses some deviations from them for the datatypes
  8385. defined in this specification.
  8386. </p>
  8387. <p>
  8388. <bibref ref="ISO8601"/> "specifies the representation of dates in the
  8389. proleptic Gregorian calendar and times and representations of periods of time".
  8390. The proleptic Gregorian calendar includes dates prior to 1582 (the year it came
  8391. into use as an ecclesiastical calendar).
  8392. It should be pointed out that the datatypes described in this
  8393. specification do not cover all the types of data covered by
  8394. <bibref ref="ISO8601"/>, nor do they support all the lexical
  8395. representations for those types of data.  
  8396. </p>
  8397. <p>
  8398. <bibref ref="ISO8601"/> lexical formats are described using "pictures"
  8399. in which characters are used in place of digits.  For the primitive datatypes
  8400. <dtref ref="dateTime"/>, <dtref ref="time"/>,
  8401. <dtref ref="date"/>, <dtref ref="gYearMonth"/>,  <dtref ref="gMonthDay"/>, 
  8402. <dtref ref="gDay"/>, <dtref ref="gMonth"/> and <dtref ref="gYear"/>. 
  8403. these characters have the following meanings:
  8404. </p>
  8405. <ulist>
  8406. <item>
  8407. <p>
  8408. C -- represents a digit used in the thousands and hundreds components,
  8409. the "century" component, of the time element "year". Legal values are
  8410. from 0 to 9.
  8411. </p>
  8412. </item>
  8413. <item>
  8414. <p>
  8415. Y -- represents a digit used in the tens and units components of the time
  8416. element "year".  Legal values are from 0 to 9.
  8417. </p>
  8418. </item>
  8419. <item>
  8420. <p>
  8421. M -- represents a digit used in the time element "month".  The two
  8422. digits in a MM format can have values from 1 to 12.
  8423. </p>
  8424. </item>
  8425. <item>
  8426. <p>
  8427. D -- represents a digit used in the time element "day". The two digits
  8428. in a DD format can have values from 1 to 28 if the month value equals 2,
  8429. 1 to 29 if the month value equals 2 and the year is a leap year, 1 to 30
  8430. if the month value equals 4, 6, 9 or 11, and 1 to 31 if the month value
  8431. equals 1, 3, 5, 7, 8, 10 or 12. 
  8432. </p>
  8433. </item>
  8434. <item>
  8435. <p>
  8436. h -- represents a digit used in the time element "hour". The two digits
  8437. in a hh format can have values from 0 to 23.
  8438. </p>
  8439. </item>
  8440. <item>
  8441. <p>
  8442. m -- represents a digit used in the time element "minute". The two digits
  8443. in a mm format can have values from 0 to 59.
  8444. </p>
  8445. </item>
  8446. <item>
  8447. <p>
  8448. s -- represents a digit used in the time element "second".  The two
  8449. digits in a ss format can have values from 0 to 60.  In the formats
  8450. described in this specification the whole number of seconds <termref def="dt-may"/>
  8451. be followed by decimal seconds to an arbitrary level of precision.
  8452. This is represented in the picture by "ss.sss".  A value of 60 or more is 
  8453. allowed only in the case of leap seconds.  </p>
  8454. <p>Strictly speaking, a value of
  8455. 60 or more is not sensible unless the month and day could
  8456. represent March 31, June 30, September 30, or December 31 <emph>in UTC</emph>.
  8457. Because the leap second is added or subtracted as the last second of the day 
  8458. in UTC time, the long (or short) minute could occur at other times in local
  8459. time.  In cases where the leap second is used with an inappropriate month 
  8460. and day it, and any fractional seconds, should considered as added or
  8461. subtracted from the following minute.   
  8462. </p>
  8463. </item>
  8464. </ulist>
  8465. <p>
  8466. For all the information items indicated by the above characters, leading
  8467. zeros are required where indicated.
  8468. </p>
  8469. <p>
  8470. In addition to the above, certain characters are used as designators
  8471. and appear as themselves in lexical formats.
  8472. </p>
  8473. <ulist>
  8474. <item>
  8475. <p>
  8476. T -- is used as time designator to indicate the start of the
  8477. representation of the time of day in <dtref ref="dateTime"/>.
  8478. </p>
  8479. </item>
  8480. <item>
  8481. <p>
  8482. Z -- is used as time-zone designator, immediately (without a space)
  8483. following a data element expressing the time of day in Coordinated
  8484. Universal Time (UTC) in 
  8485. <dtref ref="dateTime"/>, <dtref ref="time"/>,
  8486. <dtref ref="date"/>, <dtref ref="gYearMonth"/>,  <dtref ref="gMonthDay"/>, 
  8487. <dtref ref="gDay"/>, <dtref ref="gMonth"/>, and <dtref ref="gYear"/>.
  8488. </p>
  8489. </item>
  8490. </ulist>
  8491. <p>In the lexical format for <dtref ref="duration"/> the following
  8492. characters are also used as designators and appear as themselves in 
  8493. lexical formats:</p>
  8494. <ulist>
  8495. <item>
  8496. <p>P -- is used as the time duration designator, preceding a data element
  8497. representing a given duration of time.</p>
  8498. </item>
  8499. <item>
  8500. <p>Y -- follows the number of years in a time duration.</p></item>
  8501. <item><p>M -- follows the number of months or minutes in a time duration.</p></item>
  8502. <item><p>D -- follows the number of days in a time duration.</p></item>
  8503. <item><p>H -- follows the number of hours in a time duration.</p></item>
  8504. <item><p>S -- follows the number of seconds in a time duration.</p></item>
  8505. </ulist>  
  8506. <p>
  8507. The values of the
  8508. Year, Month, Day, Hour and Minutes components are not restricted but 
  8509. allow an arbitrary integer.  Similarly, the value of the Seconds component
  8510. allows an arbitrary decimal.  Thus, the lexical format for
  8511. <dtref ref="duration"/> and datatypes derived from it 
  8512. does not follow the alternative 
  8513. format of § 5.5.3.2.1 of <bibref ref="ISO8601"/>.</p>
  8514. </div2>
  8515. <div2 id="truncatedformats">
  8516. <head>Truncated and Reduced Formats</head>
  8517. <p>
  8518. <bibref ref="ISO8601"/> supports a variety of "truncated" formats in
  8519. which some of the characters on the left of specific formats, for example,
  8520. the
  8521. century, can be omitted.
  8522. Truncated formats are, in
  8523. general, not permitted for the datatypes defined in this specification
  8524. with three exceptions.  The <dtref ref="time"/> datatype uses
  8525. a truncated format for <dtref ref="dateTime"/>
  8526. which represents an instant of time that recurs every day.
  8527. Similarly, the <dtref ref="gMonthDay"/> and <dtref ref="gDay"/>
  8528. datatypes use left-truncated formats for <dtref ref="date"/>.
  8529. The datatype <dtref ref="gMonth"/> uses a right and left truncated format for 
  8530. <dtref ref="date"/>.
  8531. </p>
  8532. <p>
  8533. <bibref ref="ISO8601"/> also supports a variety of "reduced" or right-truncated
  8534. formats in which some of the characters to the right of specific formats,
  8535. such as the
  8536. time specification, can be omitted.  Right truncated formats are also, in
  8537. general,
  8538. not permitted for the datatypes defined in this specification
  8539. with the following exceptions:
  8540. right-truncated representations of <dtref ref="dateTime"/> are used as
  8541. lexical representations for <dtref ref="date"/>,  <dtref ref="gMonth"/>,
  8542. <dtref ref="gYear"/>.
  8543. </p>
  8544. </div2>
  8545. <div2 id="deviantformats">
  8546. <head>Deviations from ISO 8601 Formats</head>
  8547. <div3 id="signallowed">
  8548. <head>Sign Allowed</head>
  8549. <p>
  8550. An optional minus sign is allowed immediately preceding, without a space,
  8551. the lexical representations for <dtref ref="duration"/>, <dtref ref="dateTime"/>,
  8552. <dtref ref="date"/>, <dtref ref="gMonth"/>, <dtref ref="gYear"/>.
  8553. </p>
  8554. </div3>
  8555. <div3 id="noYearZero">
  8556. <head>No Year Zero</head>
  8557. <p>
  8558. The year "0000" is an illegal year value. 
  8559. </p>
  8560. </div3>
  8561. <div3 id="morethan9999years">
  8562. <head>More Than 9999 Years</head>
  8563. <p>
  8564. To accommodate year values greater than 9999, more than four digits are
  8565. allowed in the year representations of <dtref ref="dateTime"/>, 
  8566. <dtref ref="date"/>, <dtref ref="gYearMonth"/>, and <dtref ref="gYear"/>.
  8567. This follows
  8568. <bibref ref="ISO8601revision"/>.
  8569. </p>
  8570. </div3>
  8571. </div2>
  8572. </div1>
  8573.  
  8574. <div1 id="adding-durations-to-dateTimes">
  8575. <head>Adding durations to dateTimes</head>
  8576. <p>
  8577. Given a <dtref ref='dateTime'/> S and a <dtref ref='duration'/> D, this
  8578. appendix specifies how to compute a <dtref ref='dateTime'/> E where E is the
  8579. end of the time period with start S and duration D i.e. E = S + D.  Such
  8580. computations are used, for example, to determine whether a <dtref ref='dateTime'/>
  8581. is within a specific time period. This appendix also addresses the addition of
  8582. <dtref ref='duration'/>s to the datatypes <dtref ref='date'/>,
  8583. <dtref ref='gYearMonth'/>, <dtref ref='gYear'/>, <dtref ref='gDay'/> and
  8584. <dtref ref='gMonth'/>, which can be viewed as a set of <dtref ref='dateTime'/>s.
  8585. In such cases, the addition is made to the first or starting 
  8586. <dtref ref='dateTime'/> in the set.
  8587. </p>
  8588. <p> 
  8589. <emph>This is a logical explanation of the process.
  8590. Actual implementations are free to optimize as long as they produce the same
  8591. results. </emph> The calculation uses the notation S[year] to represent the year
  8592. field of S, S[month] to represent the month field, and so on. It also depends on
  8593. the following functions:</p>
  8594. <ulist>
  8595.      <item><p>
  8596.          fQuotient(a, b) = the greatest integer less than or equal to a/b
  8597.           <ulist>
  8598.           <item><p>fQuotient(-1,3) = -1</p> </item>
  8599.           <item><p>fQuotient(0,3)...fQuotient(2,3) = 0</p></item> 
  8600.           <item><p>fQuotient(3,3) = 1</p></item> 
  8601.           <item><p>fQuotient(3.123,3) = 1</p></item> 
  8602.           </ulist>
  8603.      </p>
  8604.      </item>
  8605.      <item><p>
  8606.          modulo(a, b) = a - fQuotient(a,b)*b
  8607.           <ulist>
  8608.           <item><p>modulo(-1,3) = 2</p></item> 
  8609.           <item><p>modulo(0,3)...modulo(2,3) = 0...2</p></item> 
  8610.           <item><p>modulo(3,3) = 0</p></item> 
  8611.           <item><p>modulo(3.123,3) = 0.123</p></item> 
  8612.           </ulist>
  8613.      </p>
  8614.      </item>
  8615.      <item><p>
  8616.          fQuotient(a, low, high) = fQuotient(a - low, high - low)
  8617.           <ulist>
  8618.           <item><p>fQuotient(0, 1, 13) = -1</p></item> 
  8619.           <item><p>fQuotient(1, 1, 13) ... fQuotient(12, 1, 13) = 0</p></item> 
  8620.           <item><p>fQuotient(13, 1, 13) = 1</p></item> 
  8621.           <item><p>fQuotient(13.123, 1, 13) = 1</p></item> 
  8622.           </ulist>
  8623.      </p>
  8624.      </item>
  8625.      <item><p>
  8626.          modulo(a, low, high) = modulo(a - low, high - low) + low
  8627.           <ulist>
  8628.           <item><p>modulo(0, 1, 13) = 12</p></item> 
  8629.           <item><p>modulo(1, 1, 13) ...  modulo(12, 1, 13) = 1...12 </p></item>
  8630.           <item><p>modulo(13, 1, 13) = 1</p></item> 
  8631.           <item><p>modulo(13.123, 1, 13) = 1.123</p></item> 
  8632.           </ulist>
  8633.      </p>
  8634.      </item>
  8635.      <item><p>
  8636.          maximumDayInMonthFor(yearValue, monthValue) =
  8637.           <ulist>
  8638.           <item><p>M := modulo(monthValue, 1, 13)</p></item> 
  8639.           <item><p>Y := yearValue + fQuotient(monthValue, 1, 13)</p></item> 
  8640.           <item><p>Return a value based on M and Y:</p></item> 
  8641.           </ulist>
  8642.      </p>
  8643.      </item>
  8644. </ulist>
  8645.  
  8646. <p></p>
  8647.     <table border="1">
  8648.     <tbody>
  8649.       <tr>
  8650.         <td style='background-color:#FFFF99'><strong>31</strong></td>
  8651.         <td colspan="2">M = January, March, May, July, August, October, or
  8652.           December</td>
  8653.       </tr>
  8654.       <tr>
  8655.         <td style='background-color:#FFFF99'><strong>30</strong></td>
  8656.         <td colspan="2">M = April, June, September, or November</td>
  8657.       </tr>
  8658.       <tr>
  8659.         <td style='background-color:#FFFF99'><strong>29</strong></td>
  8660.         <td>M = February AND (modulo(Y, 400) = 0 OR 
  8661.           (modulo(Y, 100) != 0) AND modulo(Y, 4) = 0)</td>
  8662.       </tr>
  8663.       <tr>
  8664.         <td style='background-color:#FFFF99'><strong>28</strong></td>
  8665.         <td>Otherwise</td>
  8666.       </tr>
  8667.     </tbody>
  8668.     </table>
  8669. <p></p>
  8670. <div2>
  8671. <head>Algorithm</head>
  8672. <p>
  8673. Essentially, this calculation is equivalent to separating D into <year,month>
  8674. and <day,hour,minute,second> fields. The <year,month> is added to S.
  8675. If the day is out of range, it is <emph>pinned</emph> to be within range. Thus April
  8676. 31 turns into April 30. Then the <day,hour,minute,second> is added. This
  8677. latter addition can cause the year and month to change.
  8678. </p>
  8679. <p>
  8680. Leap seconds are handled by the computation by treating them as overflows.
  8681. Essentially, a value of 60
  8682. seconds in S is treated as if it were a duration of 60 seconds added to S
  8683. (with a zero seconds field). All calculations
  8684. thereafter use 60 seconds per minute. 
  8685. </p>
  8686. <p>
  8687. Thus the addition of either PT1M or PT60S to any dateTime will always
  8688. produce the same result. This is a special definition of addition which
  8689. is designed to match common practice, and -- most importantly -- be stable
  8690. over time.
  8691. </p>
  8692. <p>
  8693. A definition that attempted to take leap-seconds into account would need to
  8694. be constantly updated, and could not predict the results of future
  8695. implementation's additions. The decision to introduce a leap second in UTC
  8696. is the responsibility of the <bibref ref ='IERS'/>. They make periodic
  8697. announcements as to when
  8698. leap seconds are to be added, but this is not known more than a year in
  8699. advance. For more information on leap seconds, see <bibref ref="USNavy"/>.
  8700. </p>
  8701. <p>
  8702. The following is the precise specification. These steps must be followed in
  8703. the same order. If a field in D is not specified, it is treated as if it were
  8704. zero. If a field in S is not specified, it is treated in the calculation as if
  8705. it were the minimum allowed value in that field, however, after the calculation
  8706. is concluded, the corresponding field in E is removed (set to unspecified).
  8707. </p>
  8708. <ulist>
  8709.   <item><p><emph>Months (may be modified additionally below)</emph>
  8710.     <ulist>
  8711.       <item><p>temp := S[month] + D[month]</p></item>
  8712.       <item><p>E[month] := modulo(temp, 1, 13)</p></item>
  8713.       <item><p>carry := fQuotient(temp, 1, 13)</p></item>
  8714.     </ulist>
  8715.   </p>
  8716.   </item>
  8717.   <item><p><emph>Years (may be modified additionally below)</emph>
  8718.     <ulist>
  8719.       <item><p>E[year] := S[year] + D[year] + carry</p></item>
  8720.     </ulist>
  8721.   </p>
  8722.   </item>
  8723.   <item><p><emph>Zone</emph>
  8724.     <ulist>
  8725.       <item><p>E[zone] := S[zone]</p></item>
  8726.     </ulist>
  8727.   </p>
  8728.   </item>
  8729.   <item><p><emph>Seconds</emph>
  8730.     <ulist>
  8731.       <item><p>temp := S[second] + D[second]</p></item>
  8732.       <item><p>E[second] := modulo(temp, 60)</p></item>
  8733.       <item><p>carry := fQuotient(temp, 60)</p></item>
  8734.     </ulist>
  8735.   </p>
  8736.   </item>
  8737.   <item><p><emph>Minutes</emph>
  8738.     <ulist>
  8739.       <item><p>temp := S[minute] + D[minute] + carry</p></item>
  8740.       <item><p>E[minute] := modulo(temp, 60)</p></item>
  8741.       <item><p>carry := fQuotient(temp, 60)</p></item>
  8742.     </ulist>
  8743.   </p>
  8744.   </item>
  8745.   <item><p><emph>Hours</emph>
  8746.     <ulist>
  8747.       <item><p>temp := S[hour] + D[hour] + carry</p></item>
  8748.       <item><p>E[hour] := modulo(temp, 24)</p></item>
  8749.       <item><p>carry := fQuotient(temp, 24)</p></item>
  8750.     </ulist>
  8751.   </p>
  8752.   </item>
  8753.   <item><p><emph>Days</emph>
  8754.     <ulist>
  8755.       <item><p>if S[day] > maximumDayInMonthFor(E[year], E[month])
  8756.         <ulist>
  8757.           <item><p>tempDays := maximumDayInMonthFor(E[year], E[month])</p></item>
  8758.         </ulist>
  8759.       </p>
  8760.       </item>
  8761.       <item><p>else if S[day] < 1
  8762.         <ulist>
  8763.           <item><p>tempDays := 1</p></item>
  8764.         </ulist>
  8765.       </p>
  8766.       </item>
  8767.       <item><p>else
  8768.         <ulist>
  8769.           <item><p>tempDays := S[day]</p></item>
  8770.         </ulist>
  8771.       </p>
  8772.       </item>
  8773.       <item><p>E[day] := tempDays + D[day] + carry</p></item>
  8774.       <item><p><term>START LOOP</term>
  8775.         <ulist>
  8776.           <item><p><term>IF </term>E[day] < 1
  8777.             <ulist>
  8778.               <item><p>E[day] := E[day] + maximumDayInMonthFor(E[year], E[month] - 1)</p></item>
  8779.               <item><p>carry := -1</p></item>
  8780.             </ulist>
  8781.           </p>
  8782.           </item>
  8783.           <item><p><term>ELSE IF </term>E[day] > maximumDayInMonthFor(E[year], E[month])
  8784.             <ulist>
  8785.               <item><p>E[day] := E[day] - maximumDayInMonthFor(E[year], E[month])</p></item>
  8786.               <item><p>carry := 1</p></item>
  8787.             </ulist>
  8788.           </p>
  8789.           </item>
  8790.           <item><p><term>ELSE EXIT LOOP</term></p></item>
  8791.           <item><p>temp := E[month] + carry</p></item>
  8792.           <item><p>E[month] := modulo(temp, 1, 13)</p></item>
  8793.           <item><p>E[year] := E[year] + fQuotient(temp, 1, 13)</p></item>
  8794.           <item><p><term>GOTO START LOOP</term></p></item>
  8795.         </ulist>
  8796.       </p>
  8797.       </item>
  8798.     </ulist>
  8799.   </p>
  8800.   </item>
  8801. </ulist>
  8802. <p><emph>Examples:</emph></p>
  8803.     <table border="1" cellspacing="0" cellpadding="4">
  8804.     <tbody>
  8805.       <tr>
  8806.         <th align="center" style="background-color: #FFFF99">dateTime</th>
  8807.         <th align="center" style="background-color: #FFFF99">duration</th>
  8808.         <th align="center" style="background-color: #FFFF99">result</th>
  8809.       </tr>
  8810.       <tr>
  8811.         <td align="center">2000-01-12T12:13:14Z</td>
  8812.         <td align="center">P1Y3M5DT7H10M3.3S</td>
  8813.         <td align="center">2001-04-17T19:23:17.3Z</td>
  8814.       </tr>
  8815.       <tr>
  8816.         <td align="center">2000-01</td>
  8817.         <td align="center">-P3M</td>
  8818.         <td align="center">1999-10</td>
  8819.       </tr>
  8820.       <tr>
  8821.         <td align="center">2000-01-12</td>
  8822.         <td align="center">PT33H</td>
  8823.         <td align="center">2000-01-13</td>
  8824.       </tr>
  8825.     </tbody>
  8826.     </table>
  8827.   </div2>
  8828. <div2 id = 'adding-durations-to-instants-commutativity-associativity'>
  8829. <head>Commutativity and Associativity</head>
  8830. <p>
  8831. Time durations are added by simply adding each of their fields, respectively,
  8832. without overflow.
  8833. </p>
  8834. <p>
  8835. The order of addition of durations to instants <emph>is</emph> significant.
  8836. For example, there are cases where:
  8837. </p>
  8838. <p>((dateTime + duration1) + duration2) != ((dateTime +
  8839. duration2) + duration1)</p>
  8840. <p><emph>Example:</emph></p>
  8841. <p>(2000-03-30 + P1D) + P1M = 2000-03-31 + P1M = 2001-<strong>04-30</strong></p>
  8842. <p>(2000-03-30 + P1M) + P1D = 2000-04-30 + P1D = 2000-<strong>05-01</strong></p>
  8843. </div2>
  8844. </div1>
  8845.  
  8846. <div1 id="regexs">
  8847. <head>Regular Expressions</head>
  8848. <p>
  8849. A <termref def="dt-regex"/> <emph>R</emph> is a sequence of
  8850. characters that denote a <strong>set of strings</strong>  <emph>L(R)</emph>.
  8851. When used to constrain a <termref def="dt-lexical-space"/>, a
  8852. <term>regular expression</term>  <emph>R</emph> asserts that only strings
  8853. in <emph>L(R)</emph> are valid literals for values of that type.
  8854. </p>
  8855.  
  8856. <p>
  8857. <termdef id="dt-regex" term="regular expression">A
  8858. <term>regular expression</term> is composed from zero or more
  8859. <termref def="dt-branch"/>es, separated by <code>|</code> characters.
  8860. </termdef>
  8861. </p>
  8862. <scrap>
  8863.     <head>Regular Expression</head>
  8864.     <prod id='regex'>
  8865.         <lhs id='nt-regExp'>regExp</lhs>
  8866.         <rhs>
  8867.             <nt def='nt-branch'>branch</nt>
  8868.             ( '|' <nt def='nt-branch'>branch</nt> )*
  8869.         </rhs>
  8870.     </prod>
  8871. </scrap>
  8872. <p/>
  8873. <table border="1">
  8874. <col width="50%"/>
  8875. <col width="50%"/>
  8876. <thead>
  8877. <tr>
  8878. <th>
  8879. For all <termref def="dt-branch"/>es <emph>S</emph>, and for all
  8880. <termref def="dt-regex"/>s <emph>T</emph>, valid
  8881. <termref def="dt-regex"/>s <emph>R</emph> are:
  8882. </th>
  8883. <th>
  8884. Denoting the set of strings <emph>L(R)</emph> containing:
  8885. </th>
  8886. </tr>
  8887. </thead>
  8888. <tbody>
  8889. <tr>
  8890.   <td align="center">(empty string)</td>
  8891.   <td align="center">the set containing just the empty string
  8892. </td>
  8893. </tr>
  8894. <tr>
  8895.   <td align="center"><emph>S</emph></td>
  8896.   <td align="center">all strings in <emph>L(S)</emph></td>
  8897. </tr>
  8898. <tr>
  8899.   <td align="center"><emph>S</emph>|<emph>T</emph></td>
  8900.   <td align="center">all strings in <emph>L(S)</emph> and
  8901.   all strings in <emph>L(T)</emph></td>
  8902. </tr>
  8903. </tbody>
  8904. </table>
  8905.  
  8906. <p>
  8907. <termdef id="dt-branch" term="branch" role='local'>
  8908. A <term>branch</term> consists
  8909. of zero or more <termref def="dt-piece"/>s, concatenated together.
  8910. </termdef>
  8911. </p>
  8912. <scrap>
  8913.     <head>Branch</head>
  8914.     <prod id='branch'>
  8915.         <lhs id='nt-branch'>branch</lhs>
  8916.         <rhs><nt def='nt-piece'/>*</rhs>
  8917.     </prod>
  8918. </scrap>
  8919. <p/>
  8920. <table border="1">
  8921. <col width="50%"/>
  8922. <col width="50%"/>
  8923. <thead>
  8924. <tr>
  8925. <th>
  8926. For all <termref def="dt-piece"/>s <emph>S</emph>, and for all
  8927. <termref def="dt-branch"/>es <emph>T</emph>, valid
  8928. <termref def="dt-branch"/>es <emph>R</emph> are:
  8929. </th>
  8930. <th>
  8931. Denoting the set of strings <emph>L(R)</emph> containing:
  8932. </th>
  8933. </tr>
  8934. </thead>
  8935. <tbody>
  8936. <tr>
  8937.   <td align="center"><emph>S</emph></td>
  8938.   <td align="center">all strings in <emph>L(S)</emph></td>
  8939. </tr>
  8940. <tr>
  8941.   <td align="center"><emph>S</emph><emph>T</emph></td>
  8942.   <td align="center">all strings <emph>st</emph> with <emph>s</emph> in
  8943.   <emph>L(S)</emph> and <emph>t</emph> in <emph>L(T)</emph></td>
  8944. </tr>
  8945. </tbody>
  8946. </table>
  8947.  
  8948. <p>
  8949. <termdef id="dt-piece" term="piece" role='local'>
  8950. A <term>piece</term> is an
  8951. <termref def="dt-atom"/>, possibly followed by a
  8952. <termref def="dt-quantifier"/>.
  8953. </termdef>
  8954. </p>
  8955.  
  8956. <scrap>
  8957.     <head>Piece</head>
  8958.     <prod id='piece'>
  8959.         <lhs id='nt-piece'>piece</lhs>
  8960.         <rhs><nt def='nt-atom'/> <nt def='nt-quantifier'/>?</rhs>
  8961.     </prod>
  8962. </scrap>
  8963. <p/>
  8964. <table border="1">
  8965. <col width="50%"/>
  8966. <col width="50%"/>
  8967. <thead>
  8968. <tr>
  8969. <th>
  8970. For all <termref def="dt-atom"/>s <emph>S</emph> and non-negative
  8971. integers <emph role="eq">n</emph>, <emph role="eq">m</emph> such that
  8972. <emph role="eq">n <= m</emph>, valid <termref def="dt-piece"/>s
  8973. <emph>R</emph> are:
  8974. </th>
  8975. <th>
  8976. Denoting the set of strings <emph>L(R)</emph> containing:
  8977. </th>
  8978. </tr>
  8979. </thead>
  8980. <tbody>
  8981. <tr>
  8982.   <td align="center"><emph>S</emph></td>
  8983.   <td align="center">all strings in <emph>L(S)</emph></td>
  8984. </tr>
  8985. <tr>
  8986.   <td align="center"><emph>S</emph>?</td>
  8987.   <td align="center">the empty string, and all strings in
  8988.   <emph>L(S)</emph>.</td>
  8989. </tr>
  8990. <tr>
  8991.   <td align="center"><emph>S</emph>*</td>
  8992.   <td align="center">
  8993.   All strings in <emph>L(S?)</emph> and all strings <emph>st</emph>
  8994.   with <emph>s</emph> in <emph>L(S*)</emph>
  8995.   and <emph>t</emph> in <emph>L(S)</emph>. <emph>( all concatenations
  8996.   of zero or more strings from L(S) )</emph>
  8997.   </td>
  8998. </tr>
  8999. <tr>
  9000.   <td align="center"><emph>S</emph>+</td>
  9001.   <td align="center">
  9002.   All strings <emph>st</emph> with <emph>s</emph> in <emph>L(S)</emph>
  9003.   and <emph>t</emph> in <emph>L(S*)</emph>.  <emph>( all concatenations
  9004.   of one or more strings from L(S) )</emph>
  9005.   </td>
  9006. </tr>
  9007. <tr>
  9008.   <td align="center"><emph>S</emph>{n,m}</td>
  9009.   <td align="center">
  9010.   All strings <emph>st</emph> with <emph>s</emph> in <emph>L(S)</emph>
  9011.   and <emph>t</emph> in <emph>L(S{n-1,m-1})</emph>.  <emph>( All
  9012. sequences of at least n, and at most m, strings from L(S) )</emph>
  9013.   </td>
  9014. </tr>
  9015. <tr>
  9016.   <td align="center"><emph>S</emph>{n}</td>
  9017.   <td align="center">
  9018.   All strings in <emph>L(S{n,n})</emph>.  <emph>( All
  9019. sequences of exactly n strings from L(S) )</emph>
  9020.   </td>
  9021. </tr>
  9022. <tr>
  9023.   <td align="center"><emph>S</emph>{n,}</td>
  9024.   <td align="center">
  9025.   All strings in L(S{n}S*)  <emph>( All
  9026. sequences of at least n, strings from L(S) )</emph>
  9027.   </td>
  9028. </tr>
  9029. <tr>
  9030.   <td align="center"><emph>S</emph>{0,m}</td>
  9031.   <td align="center">
  9032.   All strings <emph>st</emph> with <emph>s</emph> in <emph>L(S?)</emph>
  9033.   and <emph>t</emph> in <emph>L(S{0,m-1})</emph>.  <emph>( All
  9034. sequences of at most m, strings from L(S) )</emph>
  9035.   </td>
  9036. </tr>
  9037. <tr>
  9038.   <td align="center"><emph>S</emph>{0,0}</td>
  9039.   <td align="center">
  9040.   The set containing only the empty string
  9041.   </td>
  9042. </tr>
  9043. </tbody>
  9044. </table>
  9045. <note>
  9046. <p>
  9047. The regular expression language in the Perl Programming Language
  9048. <bibref ref="Perl"/> does not include a quantifier of the form
  9049. <code>S{,m)</code>, since it is logically equivalent to <code>S{0,m}</code>.
  9050. We have, therefore, left this logical possibility out of the regular
  9051. expression language defined by this specification.   We welcome
  9052. further input from implementors and schema authors on this issue.
  9053. </p>
  9054. </note>
  9055. <p>
  9056. <termdef id="dt-quantifier" term="quantifier" role='local'>
  9057. A <term>quantifier</term>
  9058. is one of <code>?</code>, <code>*</code>, <code>+</code>,
  9059. <code>{n,m}</code> or <code>{n,}</code>, which have the meanings
  9060. defined in the table above.
  9061. </termdef>
  9062. </p>
  9063. <scrap>
  9064.     <head>Quanitifer</head>
  9065.     <prod id='quant'>
  9066.         <lhs id='nt-quantifier'>quantifier</lhs>
  9067.         <rhs>[?*+] | ( '{' <nt def='nt-quantity'/> '}' )</rhs>
  9068.     </prod>
  9069.     <prod id='quantity'>
  9070.         <lhs id='nt-quantity'>quantity</lhs>
  9071.         <rhs><nt def='nt-quantRange'/> | 
  9072.             <nt def='nt-quantMin'/> | <nt def='nt-QuantExact'/></rhs>
  9073.     </prod>
  9074.     <prod id='quantRange'>
  9075.         <lhs id='nt-quantRange'>quantRange</lhs>
  9076.         <rhs><nt def='nt-QuantExact'/> ',' <nt def='nt-QuantExact'/></rhs>
  9077.     </prod>
  9078.     <prod id='quantMin'>
  9079.         <lhs id='nt-quantMin'>quantMin</lhs>
  9080.         <rhs><nt def='nt-QuantExact'/> ','</rhs>
  9081.     </prod>
  9082.     <prod id='quantExact'>
  9083.         <lhs id='nt-QuantExact'>QuantExact</lhs>
  9084.         <rhs>[0-9]+</rhs>
  9085.     </prod>
  9086. </scrap>
  9087. <p>
  9088. <termdef id="dt-atom" term="atom" role='local'>
  9089. An <term>atom</term> is either a
  9090. <termref def="dt-normalc"/>, a <termref def="dt-charclass"/>, or
  9091. a parenthesized <termref def="dt-regex"/>.</termdef>
  9092. </p>
  9093.  
  9094. <scrap>
  9095.     <head>Atom</head>
  9096.     <prod id='atom'>
  9097.         <lhs id='nt-atom'>atom</lhs>
  9098.         <rhs><nt def='nt-Char'/> | 
  9099.             <nt def='nt-charClass'/> | ( '('
  9100.             <nt def='nt-regExp'/> ')' )</rhs>
  9101.     </prod>
  9102. </scrap>
  9103. <p/>
  9104. <table border="1">
  9105. <col width="50%"/>
  9106. <col width="50%"/>
  9107. <thead>
  9108. <tr>
  9109. <th>
  9110. For all <termref def="dt-normalc"/>s <emph>c</emph>,
  9111. <termref def="dt-charclass"/>es <emph>C</emph>, and
  9112. <termref def="dt-regex"/>s <emph>S</emph>, valid
  9113. <termref def="dt-atom"/>s <emph>R</emph> are:
  9114. </th>
  9115. <th>
  9116. Denoting the set of strings <emph>L(R)</emph> containing:
  9117. </th>
  9118. </tr>
  9119. </thead>
  9120. <tbody>
  9121. <tr>
  9122.   <td align="center"><emph>c</emph></td>
  9123.   <td align="center">the single string consisting only of <emph>c</emph></td>
  9124. </tr>
  9125. <tr>
  9126.   <td align="center"><emph>C</emph></td>
  9127.   <td align="center">all strings in <emph>L(C)</emph></td>
  9128. </tr>
  9129. <tr>
  9130.   <td align="center">(<emph>S</emph>)</td>
  9131.   <td align="center">all strings in <emph>L(S)</emph></td>
  9132. </tr>
  9133. </tbody>
  9134. </table>
  9135.  
  9136. <p>
  9137. <termdef id="dt-metac" term="metacharacter" role='local'>
  9138. A <term>metacharacter</term>
  9139. is either <code>.</code>, <code>\</code>, <code>?</code>,
  9140. <code>*</code>, <code>+</code>, <code>{</code>, <code>}</code>
  9141. <code>(</code>, <code>)</code>, <code>[</code> or <code>]</code>.
  9142. These characters have special meanings in <termref def="dt-regex"/>s,
  9143. but can be escaped to form <termref def="dt-atom"/>s that denote the
  9144. sets of strings containing only themselves, i.e., an escaped
  9145. <termref def="dt-metac"/> behaves like a <termref def="dt-normalc"/>.
  9146. </termdef>
  9147. </p>
  9148.  
  9149. <p>
  9150. <termdef id="dt-normalc" term="normal character" role='local'>
  9151. A
  9152. <term>normal character</term> is any XML character that is not a
  9153. metacharacter.  In <termref def="dt-regex"/>s, a normal character is an
  9154. atom that denotes the singleton set of strings containing only itself.
  9155. </termdef>
  9156. </p>
  9157. <scrap>
  9158.     <head>Normal Character</head>
  9159.     <prod id='char'>
  9160.         <lhs id='nt-Char'>Char</lhs>
  9161.         <rhs>[^.\?*+()|#x5B#x5D]</rhs>
  9162.     </prod>
  9163. </scrap>
  9164.  
  9165. <p>
  9166. Note that a <termref def="dt-normalc"/> can be represented either as
  9167. itself, or with a <xspecref href="&xmlspec;#dt-charref">character
  9168. reference</xspecref>.
  9169. </p>
  9170. <div2 id="charcter-classes">
  9171. <head>Character Classes</head>
  9172. <p>
  9173. <termdef id="dt-charclass" term="character class" role='local'>
  9174. A
  9175. <term>character class</term> is an <termref def="dt-atom"/>
  9176.  <emph>R</emph> that identifies a <strong>set of characters</strong>
  9177.  <emph>C(R)</emph>.  The set of strings <emph>L(R)</emph> denoted by a
  9178. character class <emph>R</emph> contains one single-character string
  9179. "<emph>c</emph>" for each character <emph>c</emph> in <emph>C(R)</emph>.
  9180. </termdef>
  9181. </p>
  9182. <scrap>
  9183.     <head>Character Class</head>
  9184.     <prod id='charClass'>
  9185.         <lhs id='nt-charClass'>charClass</lhs>
  9186.         <rhs>
  9187.             <nt def='nt-charClassEsc'/> | <nt def='nt-charClassExpr'/>
  9188.         </rhs>
  9189.     </prod>
  9190. </scrap>
  9191. <p>
  9192. A character class is either a <termref def="dt-cces"/> or a
  9193. <termref def="dt-charexpr"/>.
  9194. </p>
  9195.  
  9196. <p>
  9197. <termdef id="dt-charexpr" term="character class expression" role='local'>
  9198. A
  9199. <term>character class expression</term> is a <termref def="dt-chargroup"/> surrounded
  9200. by <code>[</code> and <code>]</code> characters.  For all character
  9201. groups <emph>G</emph>, [<emph>G</emph>] is a valid <term>character class
  9202. expression</term>, identifying the set of characters
  9203. <emph>C</emph>([<emph>G</emph>]) = <emph>C</emph>(<emph>G</emph>).
  9204. </termdef>
  9205. </p>
  9206. <scrap>
  9207.     <head>Character Class Expression</head>
  9208.     <prod id='charClassExpr'>
  9209.         <lhs id='nt-charClassExpr'>charClassExpr</lhs>
  9210.         <rhs>'[' <nt def='nt-charGroup'/> ']'</rhs>
  9211.     </prod>
  9212. </scrap>
  9213. <p>
  9214. <termdef id="dt-chargroup" term="character group" role='local'>
  9215. A
  9216. <term>character group</term> is either a <termref def="dt-poschargroup"/>,
  9217. a <termref def="dt-negchargroup"/>, or a <termref def="dt-subchargroup"/>.
  9218. </termdef>
  9219. </p>
  9220.  
  9221. <scrap>
  9222.     <head>Character Group</head>
  9223.     <prod id='chargroup'>
  9224.         <lhs id='nt-charGroup'>charGroup</lhs>
  9225.         <rhs>
  9226.             <nt def='nt-posCharGroup'/> |
  9227.             <nt def='nt-negCharGroup'/> |
  9228.             <nt def='nt-charClassSub'/>
  9229.         </rhs>
  9230.     </prod>
  9231. </scrap>
  9232. <p>
  9233. <termdef id="dt-poschargroup" term="positive character group" role='local'>
  9234. A <term>positive character group</term> consists of one or more
  9235. <termref def="dt-charrange"/>s or <termref def="dt-cces"/>s, concatenated
  9236. together.  A <term>positive character group</term> identifies the set of
  9237. characters containing all of the characters in all of the sets identified
  9238. by its constituent ranges or escapes.
  9239. </termdef>
  9240. </p>
  9241.  
  9242. <scrap>
  9243.     <head>Positive Character Group</head>
  9244.     <prod id='poschargroup'>
  9245.         <lhs id='nt-posCharGroup'>posCharGroup</lhs>
  9246.         <rhs>
  9247.             ( 
  9248.             <nt def='nt-charRange'/> | <nt def='nt-charClassEsc'/>
  9249.             )+
  9250.         </rhs>
  9251.     </prod>
  9252. </scrap>
  9253. <p/>
  9254. <table border="1">
  9255. <col width="50%"/>
  9256. <col width="50%"/>
  9257. <thead>
  9258. <tr>
  9259. <th>
  9260. For all <termref def="dt-charrange"/>s <emph>R</emph>, all
  9261. <termref def="dt-cces"/>s <emph>E</emph>, and all
  9262. <termref def="dt-poschargroup"/>s <emph>P</emph>, valid
  9263. <termref def="dt-poschargroup"/>s <emph>G</emph> are:
  9264. </th>
  9265. <th>
  9266. Identifying the set of characters <emph>C(G)</emph> containing:
  9267. </th>
  9268. </tr>
  9269. </thead>
  9270. <tbody>
  9271. <tr>
  9272.   <td align="center"><emph>R</emph></td>
  9273.   <td align="center">all characters in <emph>C(R)</emph>.</td>
  9274. </tr>
  9275. <tr>
  9276.   <td align="center"><emph>E</emph></td>
  9277.   <td align="center">all characters in <emph>C(E)</emph>.</td>
  9278. </tr>
  9279. <tr>
  9280.   <td align="center"><emph>RP</emph></td>
  9281.   <td align="center">all characters in <emph>C(R)</emph> and all
  9282.   characters in <emph>C(P)</emph>.</td>
  9283. </tr>
  9284. <tr>
  9285.   <td align="center"><emph>EP</emph></td>
  9286.   <td align="center">all characters in <emph>C(E)</emph> and all
  9287.   characters in <emph>C(P)</emph>.</td>
  9288. </tr>
  9289. </tbody>
  9290. </table>
  9291.  
  9292. <p>
  9293. <termdef id="dt-negchargroup" term="negative character group" role='local'>
  9294. A <term>negative character group</term> is a
  9295. <termref def="dt-poschargroup"/> preceded by the <code>^</code> character.
  9296. For all <termref def="dt-poschargroup"/>s <emph>P</emph>, ^<emph>P</emph>
  9297. is a valid <term>negative character group</term>, and <emph>C(^P)</emph>
  9298. contains all XML characters that are <emph>not</emph> in <emph>C(P)</emph>.
  9299. </termdef>
  9300. </p>
  9301.  
  9302. <scrap>
  9303.     <head>Negative Character Group</head>
  9304.     <prod id='negchargroup'>
  9305.         <lhs id='nt-negCharGroup'>negCharGroup</lhs>
  9306.         <rhs>'^' <nt def='nt-posCharGroup'/></rhs>
  9307.     </prod>
  9308. </scrap>
  9309. <p>
  9310. <termdef id="dt-subchargroup" term="character class subtraction" role='local'>
  9311. A
  9312. <term>character class subtraction</term> is a <termref def="dt-charexpr"/>
  9313. subtracted from a <termref def="dt-poschargroup"/> or
  9314. <termref def="dt-negchargroup"/>, using the <code>-</code> character.
  9315. </termdef>
  9316. </p>
  9317. <scrap>
  9318.     <head>Character Class Subtraction</head>
  9319.     <prod id='charclasssub'>
  9320.         <lhs id='nt-charClassSub'>charClassSub</lhs>
  9321.         <rhs>
  9322.             ( <nt def='nt-posCharGroup'/> |
  9323.                 <nt def='nt-negCharGroup'/> ) '-'
  9324.             <nt def='nt-charClassExpr'/>
  9325.         </rhs>
  9326.     </prod>
  9327. </scrap>
  9328. <p>
  9329. For any <termref def="dt-poschargroup"/> or
  9330. <termref def="dt-negchargroup"/> <emph>G</emph>, and any
  9331. <termref def="dt-charexpr"/> <emph>C</emph>, <emph>G-C</emph> is a valid
  9332. <termref def="dt-subchargroup"/>, identifying the set of all characters in
  9333. <emph>C(G)</emph> that are not also in <emph>C(C)</emph>.
  9334. </p>
  9335.  
  9336. <p>
  9337. <termdef id="dt-charrange" term="character range" role='local'>
  9338. A
  9339. <term>character range</term> <emph>R</emph> identifies a set of
  9340. characters <emph>C(R)</emph> containing all XML characters with UCS
  9341. code points in a specified range.
  9342. </termdef>
  9343. </p>
  9344. <scrap>
  9345.     <head>Character Range</head>
  9346.     <prod id='charrange'>
  9347.         <lhs id='nt-charRange'>charRange</lhs>
  9348.         <rhs>
  9349.             <nt def='nt-seRange'/> |
  9350.             <nt def='nt-XmlCharRef'/> |
  9351.             <nt def='nt-XmlCharIncDash'/>
  9352.         </rhs>
  9353.     </prod>
  9354.     <prod id='serange'>
  9355.         <lhs id='nt-seRange'>seRange</lhs>
  9356.         <rhs><nt def='nt-charOrEsc'/> '-' <nt def='nt-charOrEsc'/></rhs>
  9357.     </prod>
  9358.     <prod id='xmlcharref'>
  9359.         <lhs id='nt-XmlCharRef'>XmlCharRef</lhs>
  9360.         <rhs>( '&#' [0-9]+ ';' ) | (' &#x' [0-9a-fA-F]+ ';' )</rhs>
  9361.     </prod>
  9362.     <prod id='charoresc'>
  9363.         <lhs id='nt-charOrEsc'>charOrEsc</lhs>
  9364.         <rhs><nt def='nt-XmlChar'/> | <nt def='nt-SingleCharEsc'/></rhs>
  9365.     </prod>
  9366.     <prod id='xmlchar'>
  9367.         <lhs id='nt-XmlChar'>XmlChar</lhs>
  9368.         <rhs>[^\#x2D#x5B#x5D]</rhs>
  9369.     </prod>
  9370.     <prod id='xmlcharincdash'>
  9371.         <lhs id='nt-XmlCharIncDash'>XmlCharIncDash</lhs>
  9372.         <rhs>[^\#x5B#x5D]</rhs>
  9373.     </prod>
  9374. </scrap>
  9375. <p>
  9376. A single XML character is a <termref def="dt-charrange"/> that identifies
  9377. the set of characters containing only itself.  All XML characters are valid
  9378. character ranges, except as follows:
  9379. </p>
  9380. <ulist>
  9381. <item>
  9382. <p>
  9383. The <code>[</code>, <code>]</code>, and <code>\</code> characters are not
  9384. valid character ranges;
  9385. </p>
  9386. </item>
  9387. <item>
  9388. <p>
  9389. The <code>^</code> character is only valid at the beginning of a
  9390. <termref def="dt-poschargroup"/> if it is part of a
  9391. <termref def="dt-negchargroup"/>; and
  9392. </p>
  9393. </item>
  9394. <item>
  9395. <p>
  9396. The <code>-</code> character is a valid character range only at the
  9397. beginning or end of a <termref def="dt-poschargroup"/>.
  9398. </p>
  9399. </item>
  9400. </ulist>
  9401. <p>
  9402. A <termref def="dt-charrange"/> <termref def="dt-may"/> also be written
  9403. in the form <emph>s-e</emph>, identifying the set that contains all XML characters
  9404. with UCS code points greater than or equal to the code point
  9405. of <emph>s</emph>, but not greater than the code point of <emph>e</emph>.
  9406. </p>
  9407. <p>
  9408. <emph>s-e</emph> is a valid character range iff:
  9409. </p>
  9410. <ulist>
  9411. <item>
  9412. <p>
  9413. <emph>s</emph> is a <termref def="dt-cces1"/>, or an XML character;
  9414. </p>
  9415. </item>
  9416. <item>
  9417. <p>
  9418. <emph>s</emph> is not <code>\</code>
  9419. </p>
  9420. </item>
  9421. <item>
  9422. <p>
  9423. If s is the first character in a <termref def="dt-charexpr"/>, then
  9424. <emph>s</emph> is not <code>^</code>
  9425. </p>
  9426. </item>
  9427. <item>
  9428. <p>
  9429. <emph>e</emph> is a <termref def="dt-cces1"/>, or an XML character;
  9430. </p>
  9431. </item>
  9432. <item>
  9433. <p>
  9434. <emph>e</emph> is not <code>\</code> or <code>[</code>; and
  9435. </p>
  9436. </item>
  9437. <item>
  9438. <p>
  9439. The code point of <emph>e</emph> is greater than or equal to the code
  9440. point of <emph>s</emph>;
  9441. </p>
  9442. </item>
  9443. </ulist>
  9444. <note>
  9445. <p>
  9446. The code point of a <termref def="dt-cces1"/> is the code point of the
  9447. single character in the set of characters that it identifies.
  9448. </p>
  9449. </note>
  9450. <div3 id="cces">
  9451. <head>Character Class Escapes</head>
  9452. <p>
  9453. <termdef id="dt-cces" term="character class escape" role='local'>
  9454. A <term>character class escape</term> is a short sequence of characters
  9455. that identifies predefined character class.  The valid character
  9456. class escapes are the <termref def="dt-cces1"/>s, the
  9457. <termref def="dt-ccesN"/>s, and the <termref def="dt-ccescat"/>s (including
  9458. the <termref def='dt-ccesblock'/>s).
  9459. </termdef>
  9460. </p>
  9461. <scrap>
  9462.     <head>Character Class Escape</head>
  9463.     <prod id='charclassesc'>
  9464.         <lhs id='nt-charClassEsc'>charClassEsc</lhs>
  9465.         <rhs>
  9466.             (
  9467.             <nt def='nt-SingleCharEsc'/> | 
  9468.             <nt def='nt-MultiCharEsc'/> |
  9469.             <nt def='nt-catEsc'/> |
  9470.             <nt def='nt-complEsc'/>
  9471.             )
  9472.         </rhs>
  9473.     </prod>
  9474. </scrap>
  9475. <p>
  9476. <termdef id="dt-cces1" term="single character escape" role='local'>
  9477. A
  9478. <term>single character escape</term> identifies a set containing a only
  9479. one character -- usually because that character is difficult or
  9480. impossible to write directly into a <termref def="dt-regex"/>.
  9481. </termdef>
  9482. </p>
  9483.  
  9484. <scrap>
  9485.     <head>Single Character Escape</head>
  9486.     <prod id='singlecharesc'>
  9487.         <lhs id='nt-SingleCharEsc'>SingleCharEsc</lhs>
  9488.         <rhs>'\' [nrt\|.?*+(){}#x2D#x5B#x5D#x5E]</rhs>
  9489.     </prod>
  9490. </scrap>
  9491. <p/>
  9492. <table border="1">
  9493. <col width="50%"/>
  9494. <col width="50%"/>
  9495. <thead>
  9496. <tr>
  9497. <th>
  9498. The valid <termref def="dt-cces1"/>s are:
  9499. </th>
  9500. <th>
  9501. Identifying the set of characters <emph>C(R)</emph> containing:
  9502. </th>
  9503. </tr>
  9504. </thead>
  9505. <tbody>
  9506. <tr>
  9507.   <td align="center"><code>\n</code></td>
  9508.   <td align="center">the newline character (#xA)</td>
  9509. </tr>
  9510. <tr>
  9511.   <td align="center"><code>\r</code></td>
  9512.   <td align="center">the return character (#xD)</td>
  9513. </tr>
  9514. <tr>
  9515.   <td align="center"><code>\t</code></td>
  9516.   <td align="center">the tab character (#x9)</td>
  9517. </tr>
  9518. <tr>
  9519.   <td align="center"><code>\\</code></td>
  9520.   <td align="center">\</td>
  9521. </tr>
  9522. <tr>
  9523.   <td align="center"><code>\|</code></td>
  9524.   <td align="center">|</td>
  9525. </tr>
  9526. <tr>
  9527.   <td align="center"><code>\.</code></td>
  9528.   <td align="center">.</td>
  9529. </tr>
  9530. <tr>
  9531.   <td align="center"><code>\-</code></td>
  9532.   <td align="center">-</td>
  9533. </tr>
  9534. <tr>
  9535.   <td align="center"><code>\^</code></td>
  9536.   <td align="center">^</td>
  9537. </tr>
  9538. <tr>
  9539.   <td align="center"><code>\?</code></td>
  9540.   <td align="center">?</td>
  9541. </tr>
  9542. <tr>
  9543.   <td align="center"><code>\*</code></td>
  9544.   <td align="center">*</td>
  9545. </tr>
  9546. <tr>
  9547.   <td align="center"><code>\+</code></td>
  9548.   <td align="center">+</td>
  9549. </tr>
  9550. <tr>
  9551.   <td align="center"><code>\{</code></td>
  9552.   <td align="center">{</td>
  9553. </tr>
  9554. <tr>
  9555.   <td align="center"><code>\}</code></td>
  9556.   <td align="center">}</td>
  9557. </tr>
  9558. <tr>
  9559.   <td align="center"><code>\(</code></td>
  9560.   <td align="center">(</td>
  9561. </tr>
  9562. <tr>
  9563.   <td align="center"><code>\)</code></td>
  9564.   <td align="center">)</td>
  9565. </tr>
  9566. <tr>
  9567.   <td align="center"><code>\[</code></td>
  9568.   <td align="center">[</td>
  9569. </tr>
  9570. <tr>
  9571.   <td align="center"><code>\]</code></td>
  9572.   <td align="center">]</td>
  9573. </tr>
  9574. </tbody>
  9575. </table>
  9576. <p>
  9577. <termdef id="dt-ccescat" term="category escape" role='local'>
  9578. <bibref ref='UnicodeDB'/> specifies a number of possible
  9579. values for the "General Category" property
  9580. and provides mappings from code points to specific character properties.
  9581. The set containing all characters that have property <code>X</code>,
  9582. can be identified with a <term>category escape</term> <code>\p{X}</code>.
  9583. The complement of this set is specified with the
  9584. <term>category escape</term> <code>\P{X}</code>.
  9585. (<code>[\P{X}]</code> = <code>[^\p{X}]</code>).
  9586. </termdef>
  9587. </p>
  9588. <scrap>
  9589.     <head>Category Escape</head>
  9590.     <prod id='catesc'>
  9591.         <lhs id='nt-catEsc'>catEsc</lhs>
  9592.         <rhs>'\p{' <nt def='nt-charProp'/> '}'</rhs>
  9593.     </prod>
  9594.     <prod id='complesc'>
  9595.         <lhs id='nt-complEsc'>complEsc</lhs>
  9596.         <rhs>'\P{' <nt def='nt-charProp'/> '}'</rhs>
  9597.     </prod>
  9598.     <prod id='charprop'>
  9599.         <lhs id='nt-charProp'>charProp</lhs>
  9600.         <rhs><nt def='nt-IsCategory'/> | <nt def='nt-IsBlock'/></rhs>
  9601.     </prod>
  9602. </scrap>
  9603. <note>
  9604. <p>
  9605. <bibref ref='UnicodeDB'/> is subject to future revision.  For example, the
  9606. mapping from code points to character properties might be updated.  
  9607. All <termref def="dt-minimally-conforming"/> processors <termref def="dt-must"/>
  9608. support the character properties defined in the version of <bibref ref='UnicodeDB'/>
  9609. that is current at the time this specification became a W3C
  9610. Recommendation.  However, implementors are encouraged to support the
  9611. character properties defined in any future version.
  9612. </p>
  9613. </note>
  9614. <p>
  9615. The following table specifies the recognized values of the
  9616. "General Category" property.
  9617. </p>
  9618.  
  9619. <table border="1" align="center">
  9620. <tbody>
  9621.     <tr>
  9622.         <th>Category</th>
  9623.         <th>Property</th>
  9624.         <th>Meaning</th>
  9625.     </tr>
  9626.     <tr>
  9627.         <td rowspan="6">Letters</td>
  9628.         <td align="center">L</td>
  9629.         <td>All Letters</td>
  9630.     </tr>
  9631.     <tr>
  9632.         <td align="center">Lu</td>
  9633.         <td>uppercase</td>
  9634.     </tr>
  9635.     <tr>
  9636.         <td align="center">Ll</td>
  9637.         <td>lowercase</td>
  9638.     </tr>
  9639.     <tr>
  9640.         <td align="center">Lt</td>
  9641.         <td>titlecase</td>
  9642.     </tr>
  9643.     <tr>
  9644.         <td align="center">Lm</td>
  9645.         <td>modifier</td>
  9646.     </tr>
  9647.     <tr>
  9648.         <td align="center">Lo</td>
  9649.         <td>other</td>
  9650.     </tr>
  9651.     <tr>
  9652.         <td colspan="3"> </td>
  9653.     </tr>
  9654.     <tr>
  9655.         <td rowspan="4">Marks</td>
  9656.         <td align="center">M</td>
  9657.         <td>All Marks</td>
  9658.     </tr>
  9659.     <tr>
  9660.         <td align="center">Mn</td>
  9661.         <td>nonspacing</td>
  9662.     </tr>
  9663.     <tr>
  9664.         <td align="center">Mc</td>
  9665.         <td>spacing combining</td>
  9666.     </tr>
  9667.     <tr>
  9668.         <td align="center">Me</td>
  9669.         <td>enclosing</td>
  9670.     </tr>
  9671.     <tr>
  9672.         <td colspan="3"> </td>
  9673.     </tr>
  9674.     <tr>
  9675.         <td rowspan="4">Numbers</td>
  9676.         <td align="center">N</td>
  9677.         <td>All Numbers</td>
  9678.     </tr>
  9679.     <tr>
  9680.         <td align="center">Nd</td>
  9681.         <td>decimal digit</td>
  9682.     </tr>
  9683.     <tr>
  9684.         <td align="center">Nl</td>
  9685.         <td>letter</td>
  9686.     </tr>
  9687.     <tr>
  9688.         <td align="center">No</td>
  9689.         <td>other</td>
  9690.     </tr>
  9691.     <tr>
  9692.         <td colspan="3"> </td>
  9693.     </tr>
  9694.     <tr>
  9695.         <td rowspan="8">Punctuation</td>
  9696.         <td align="center">P</td>
  9697.         <td>All Punctuation</td>
  9698.     </tr>
  9699.     <tr>
  9700.         <td align="center">Pc</td>
  9701.         <td>connector</td>
  9702.     </tr>
  9703.     <tr>
  9704.         <td align="center">Pd</td>
  9705.         <td>dash</td>
  9706.     </tr>
  9707.     <tr>
  9708.         <td align="center">Ps</td>
  9709.         <td>open</td>
  9710.     </tr>
  9711.     <tr>
  9712.         <td align="center">Pe</td>
  9713.         <td>close</td>
  9714.     </tr>
  9715.     <tr>
  9716.         <td align="center">Pi</td>
  9717.         <td>initial quote
  9718.             (may behave like Ps or Pe depending on usage)</td>
  9719.     </tr>
  9720.     <tr>
  9721.         <td align="center">Pf</td>
  9722.         <td>final quote
  9723.             (may behave like Ps or Pe depending on usage)</td>
  9724.     </tr>
  9725.     <tr>
  9726.         <td align="center">Po</td>
  9727.         <td>other</td>
  9728.     </tr>
  9729.     <tr>
  9730.         <td colspan="3"> </td>
  9731.     </tr>
  9732.     <tr>
  9733.         <td rowspan="4">Separators</td>
  9734.         <td align="center">Z</td>
  9735.         <td>All Separators</td>
  9736.     </tr>
  9737.     <tr>
  9738.         <td align="center">Zs</td>
  9739.         <td>space</td>
  9740.     </tr>
  9741.     <tr>
  9742.         <td align="center">Zl</td>
  9743.         <td>line</td>
  9744.     </tr>
  9745.     <tr>
  9746.         <td align="center">Zp</td>
  9747.         <td>paragraph</td>
  9748.     </tr>
  9749.     <tr>
  9750.         <td colspan="3"> </td>
  9751.     </tr>
  9752.     <tr>
  9753.         <td rowspan="5">Symbols</td>
  9754.         <td align="center">S</td>
  9755.         <td>All Symbols</td>
  9756.     </tr>
  9757.     <tr>
  9758.         <td align="center">Sm</td>
  9759.         <td>math</td>
  9760.     </tr>
  9761.     <tr>
  9762.         <td align="center">Sc</td>
  9763.         <td>currency</td>
  9764.     </tr>
  9765.     <tr>
  9766.         <td align="center">Sk</td>
  9767.         <td>modifier</td>
  9768.     </tr>
  9769.     <tr>
  9770.         <td align="center">So</td>
  9771.         <td>other</td>
  9772.     </tr>
  9773.     <tr>
  9774.         <td colspan="3"> </td>
  9775.     </tr>
  9776.     <tr>
  9777.         <td rowspan="6">Other</td>
  9778.         <td align="center">C</td>
  9779.         <td>All Others</td>
  9780.     </tr>
  9781.     <tr>
  9782.         <td align="center">Cc</td>
  9783.         <td>control</td>
  9784.     </tr>
  9785.     <tr>
  9786.         <td align="center">Cf</td>
  9787.         <td>format</td>
  9788.     </tr>
  9789.     <!--
  9790.     <tr>
  9791.         <td align="center">Cs</td>
  9792.         <td>Surrogate</td>
  9793.     </tr>
  9794.       -->
  9795.     <tr>
  9796.         <td align="center">Co</td>
  9797.         <td>private use</td>
  9798.     </tr>
  9799.     <tr>
  9800.         <td align="center">Cn</td>
  9801.         <td>not assigned</td>
  9802.     </tr>
  9803. </tbody>
  9804. </table>
  9805. <scrap>
  9806.     <head>Categories</head>
  9807.     <prod id='cats'>
  9808.         <lhs id='nt-IsCategory'>IsCategory</lhs>
  9809.         <rhs>
  9810.             <nt def='nt-Letters'/> |
  9811.             <nt def='nt-Marks'/> |
  9812.             <nt def='nt-Numbers'/> |
  9813.             <nt def='nt-Punctuation'/> |
  9814.             <nt def='nt-Separators'/> |
  9815.             <nt def='nt-Symbols'/> |
  9816.             <nt def='nt-Others'/>
  9817.         </rhs>
  9818.     </prod>
  9819.     <prod id='lets'>
  9820.         <lhs id='nt-Letters'>Letters</lhs>
  9821.         <rhs>'L' [ultmo]?</rhs>
  9822.     </prod>
  9823.     <prod id='marks'>
  9824.         <lhs id='nt-Marks'>Marks</lhs>
  9825.         <rhs>'M' [nce]?</rhs>
  9826.     </prod>
  9827.     <prod id='nums'>
  9828.         <lhs id='nt-Numbers'>Numbers</lhs>
  9829.         <rhs>'N' [dlo]?</rhs>
  9830.     </prod>
  9831.     <prod id='punc'>
  9832.         <lhs id='nt-Punctuation'>Punctuation</lhs>
  9833.         <rhs>'P' [cdseifo]?</rhs>
  9834.     </prod>
  9835.     <prod id='seps'>
  9836.         <lhs id='nt-Separators'>Separators</lhs>
  9837.         <rhs>'Z' [slp]?</rhs>
  9838.     </prod>
  9839.     <prod id='syms'>
  9840.         <lhs id='nt-Symbols'>Symbols</lhs>
  9841.         <rhs>'S' [mcko]?</rhs>
  9842.     </prod>
  9843.     <prod id='others'>
  9844.         <lhs id='nt-Others'>Others</lhs>
  9845.         <rhs>'C' [cfon]?</rhs>
  9846.     </prod>
  9847. </scrap>
  9848. <note>
  9849. <p>
  9850. The properties mentioned above exclude the <code>Cs</code> property.
  9851. The <code>Cs</code> property identifies "surrogate" characters, which do not
  9852. occur at the level of the "character abstraction" that XML instance documents
  9853. operate on.
  9854. </p>
  9855. </note>
  9856. <p>
  9857. <termdef id="dt-ccesblock" term="block escape" role='local'>
  9858. <bibref ref='UnicodeDB'/> groups code points into a number of blocks
  9859. such as Basic Latin (i.e., ASCII), Latin-1 Supplement, Hangul Jamo,
  9860. CJK Compatibility, etc.
  9861. The set containing all characters that have block name <code>X</code>
  9862. (with all white space stripped out),
  9863. can be identified with a <term>block escape</term> <code>\p{IsX}</code>.
  9864. The complement of this set is specified with the
  9865. <term>block escape</term> <code>\P{IsX}</code>.
  9866. (<code>[\P{IsX}]</code> = <code>[^\p{IsX}]</code>).
  9867. </termdef>
  9868. </p>
  9869. <scrap>
  9870.     <head>Block Escape</head>
  9871.     <prod id='blockesc'>
  9872.         <lhs id='nt-IsBlock'>IsBlock</lhs>
  9873.         <rhs>'Is' [a-zA-Z0-9#x2D]+</rhs>
  9874.     </prod>
  9875. </scrap>
  9876. <p>
  9877. The following table specifies the recognized block names (for more
  9878. information, see the "Blocks.txt" file in <bibref ref='UnicodeDB'/>).
  9879. </p>
  9880.  
  9881. <table border="1" align="center" cellpadding='5' class='ubc'>
  9882.     <tbody>
  9883.         <tr>
  9884.             <th>Start Code</th>
  9885.             <th>End Code</th>
  9886.             <th>Block Name</th>
  9887.             <th> </th>
  9888.             <th>Start Code</th>
  9889.             <th>End Code</th>
  9890.             <th>Block Name</th>
  9891.         </tr>
  9892.         <tr>
  9893.             <td>#x0000</td>
  9894.             <td>#x007F</td>
  9895.             <td>BasicLatin</td>
  9896.             <td> </td>
  9897.             <td>#x0080</td>
  9898.             <td>#x00FF</td>
  9899.             <td>Latin-1Supplement</td>
  9900.         </tr>
  9901.         <tr>
  9902.             <td>#x0100</td>
  9903.             <td>#x017F</td>
  9904.             <td>LatinExtended-A</td>
  9905.             <td> </td>
  9906.             <td>#x0180</td>
  9907.             <td>#x024F</td>
  9908.             <td>LatinExtended-B</td>
  9909.         </tr>
  9910.         <tr>
  9911.             <td>#x0250</td>
  9912.             <td>#x02AF</td>
  9913.             <td>IPAExtensions</td>
  9914.             <td> </td>
  9915.             <td>#x02B0</td>
  9916.             <td>#x02FF</td>
  9917.             <td>SpacingModifierLetters</td>
  9918.         </tr>
  9919.         <tr>
  9920.             <td>#x0300</td>
  9921.             <td>#x036F</td>
  9922.             <td>CombiningDiacriticalMarks</td>
  9923.             <td> </td>
  9924.             <td>#x0370</td>
  9925.             <td>#x03FF</td>
  9926.             <td>Greek</td>
  9927.         </tr>
  9928.         <tr>
  9929.             <td>#x0400</td>
  9930.             <td>#x04FF</td>
  9931.             <td>Cyrillic</td>
  9932.             <td> </td>
  9933.             <td>#x0530</td>
  9934.             <td>#x058F</td>
  9935.             <td>Armenian</td>
  9936.         </tr>
  9937.         <tr>
  9938.             <td>#x0590</td>
  9939.             <td>#x05FF</td>
  9940.             <td>Hebrew</td>
  9941.             <td> </td>
  9942.             <td>#x0600</td>
  9943.             <td>#x06FF</td>
  9944.             <td>Arabic</td>
  9945.         </tr>
  9946.         <tr>
  9947.             <td>#x0700</td>
  9948.             <td>#x074F</td>
  9949.             <td>Syriac</td>
  9950.             <td> </td>
  9951.             <td>#x0780</td>
  9952.             <td>#x07BF</td>
  9953.             <td>Thaana</td>
  9954.         </tr>
  9955.         <tr>
  9956.             <td>#x0900</td>
  9957.             <td>#x097F</td>
  9958.             <td>Devanagari</td>
  9959.             <td> </td>
  9960.             <td>#x0980</td>
  9961.             <td>#x09FF</td>
  9962.             <td>Bengali</td>
  9963.         </tr>
  9964.         <tr>
  9965.             <td>#x0A00</td>
  9966.             <td>#x0A7F</td>
  9967.             <td>Gurmukhi</td>
  9968.             <td> </td>
  9969.             <td>#x0A80</td>
  9970.             <td>#x0AFF</td>
  9971.             <td>Gujarati</td>
  9972.         </tr>
  9973.         <tr>
  9974.             <td>#x0B00</td>
  9975.             <td>#x0B7F</td>
  9976.             <td>Oriya</td>
  9977.             <td> </td>
  9978.             <td>#x0B80</td>
  9979.             <td>#x0BFF</td>
  9980.             <td>Tamil</td>
  9981.         </tr>
  9982.         <tr>
  9983.             <td>#x0C00</td>
  9984.             <td>#x0C7F</td>
  9985.             <td>Telugu</td>
  9986.             <td> </td>
  9987.             <td>#x0C80</td>
  9988.             <td>#x0CFF</td>
  9989.             <td>Kannada</td>
  9990.         </tr>
  9991.         <tr>
  9992.             <td>#x0D00</td>
  9993.             <td>#x0D7F</td>
  9994.             <td>Malayalam</td>
  9995.             <td> </td>
  9996.             <td>#x0D80</td>
  9997.             <td>#x0DFF</td>
  9998.             <td>Sinhala</td>
  9999.         </tr>
  10000.         <tr>
  10001.             <td>#x0E00</td>
  10002.             <td>#x0E7F</td>
  10003.             <td>Thai</td>
  10004.             <td> </td>
  10005.             <td>#x0E80</td>
  10006.             <td>#x0EFF</td>
  10007.             <td>Lao</td>
  10008.         </tr>
  10009.         <tr>
  10010.             <td>#x0F00</td>
  10011.             <td>#x0FFF</td>
  10012.             <td>Tibetan</td>
  10013.             <td> </td>
  10014.             <td>#x1000</td>
  10015.             <td>#x109F</td>
  10016.             <td>Myanmar</td>
  10017.         </tr>
  10018.         <tr>
  10019.             <td>#x10A0</td>
  10020.             <td>#x10FF</td>
  10021.             <td>Georgian</td>
  10022.             <td> </td>
  10023.             <td>#x1100</td>
  10024.             <td>#x11FF</td>
  10025.             <td>HangulJamo</td>
  10026.         </tr>
  10027.         <tr>
  10028.             <td>#x1200</td>
  10029.             <td>#x137F</td>
  10030.             <td>Ethiopic</td>
  10031.             <td> </td>
  10032.             <td>#x13A0</td>
  10033.             <td>#x13FF</td>
  10034.             <td>Cherokee</td>
  10035.         </tr>
  10036.         <tr>
  10037.             <td>#x1400</td>
  10038.             <td>#x167F</td>
  10039.             <td>UnifiedCanadianAboriginalSyllabics</td>
  10040.             <td> </td>
  10041.             <td>#x1680</td>
  10042.             <td>#x169F</td>
  10043.             <td>Ogham</td>
  10044.         </tr>
  10045.         <tr>
  10046.             <td>#x16A0</td>
  10047.             <td>#x16FF</td>
  10048.             <td>Runic</td>
  10049.             <td> </td>
  10050.             <td>#x1780</td>
  10051.             <td>#x17FF</td>
  10052.             <td>Khmer</td>
  10053.         </tr>
  10054.         <tr>
  10055.             <td>#x1800</td>
  10056.             <td>#x18AF</td>
  10057.             <td>Mongolian</td>
  10058.             <td> </td>
  10059.             <td>#x1E00</td>
  10060.             <td>#x1EFF</td>
  10061.             <td>LatinExtendedAdditional</td>
  10062.         </tr>
  10063.         <tr>
  10064.             <td>#x1F00</td>
  10065.             <td>#x1FFF</td>
  10066.             <td>GreekExtended</td>
  10067.             <td> </td>
  10068.             <td>#x2000</td>
  10069.             <td>#x206F</td>
  10070.             <td>GeneralPunctuation</td>
  10071.         </tr>
  10072.         <tr>
  10073.             <td>#x2070</td>
  10074.             <td>#x209F</td>
  10075.             <td>SuperscriptsandSubscripts</td>
  10076.             <td> </td>
  10077.             <td>#x20A0</td>
  10078.             <td>#x20CF</td>
  10079.             <td>CurrencySymbols</td>
  10080.         </tr>
  10081.         <tr>
  10082.             <td>#x20D0</td>
  10083.             <td>#x20FF</td>
  10084.             <td>CombiningMarksforSymbols</td>
  10085.             <td> </td>
  10086.             <td>#x2100</td>
  10087.             <td>#x214F</td>
  10088.             <td>LetterlikeSymbols</td>
  10089.         </tr>
  10090.         <tr>
  10091.             <td>#x2150</td>
  10092.             <td>#x218F</td>
  10093.             <td>NumberForms</td>
  10094.             <td> </td>
  10095.             <td>#x2190</td>
  10096.             <td>#x21FF</td>
  10097.             <td>Arrows</td>
  10098.         </tr>
  10099.         <tr>
  10100.             <td>#x2200</td>
  10101.             <td>#x22FF</td>
  10102.             <td>MathematicalOperators</td>
  10103.             <td> </td>
  10104.             <td>#x2300</td>
  10105.             <td>#x23FF</td>
  10106.             <td>MiscellaneousTechnical</td>
  10107.         </tr>
  10108.         <tr>
  10109.             <td>#x2400</td>
  10110.             <td>#x243F</td>
  10111.             <td>ControlPictures</td>
  10112.             <td> </td>
  10113.             <td>#x2440</td>
  10114.             <td>#x245F</td>
  10115.             <td>OpticalCharacterRecognition</td>
  10116.         </tr>
  10117.         <tr>
  10118.             <td>#x2460</td>
  10119.             <td>#x24FF</td>
  10120.             <td>EnclosedAlphanumerics</td>
  10121.             <td> </td>
  10122.             <td>#x2500</td>
  10123.             <td>#x257F</td>
  10124.             <td>BoxDrawing</td>
  10125.         </tr>
  10126.         <tr>
  10127.             <td>#x2580</td>
  10128.             <td>#x259F</td>
  10129.             <td>BlockElements</td>
  10130.             <td> </td>
  10131.             <td>#x25A0</td>
  10132.             <td>#x25FF</td>
  10133.             <td>GeometricShapes</td>
  10134.         </tr>
  10135.         <tr>
  10136.             <td>#x2600</td>
  10137.             <td>#x26FF</td>
  10138.             <td>MiscellaneousSymbols</td>
  10139.             <td> </td>
  10140.             <td>#x2700</td>
  10141.             <td>#x27BF</td>
  10142.             <td>Dingbats</td>
  10143.         </tr>
  10144.         <tr>
  10145.             <td>#x2800</td>
  10146.             <td>#x28FF</td>
  10147.             <td>BraillePatterns</td>
  10148.             <td> </td>
  10149.             <td>#x2E80</td>
  10150.             <td>#x2EFF</td>
  10151.             <td>CJKRadicalsSupplement</td>
  10152.         </tr>
  10153.         <tr>
  10154.             <td>#x2F00</td>
  10155.             <td>#x2FDF</td>
  10156.             <td>KangxiRadicals</td>
  10157.             <td> </td>
  10158.             <td>#x2FF0</td>
  10159.             <td>#x2FFF</td>
  10160.             <td>IdeographicDescriptionCharacters</td>
  10161.         </tr>
  10162.         <tr>
  10163.             <td>#x3000</td>
  10164.             <td>#x303F</td>
  10165.             <td>CJKSymbolsandPunctuation</td>
  10166.             <td> </td>
  10167.             <td>#x3040</td>
  10168.             <td>#x309F</td>
  10169.             <td>Hiragana</td>
  10170.         </tr>
  10171.         <tr>
  10172.             <td>#x30A0</td>
  10173.             <td>#x30FF</td>
  10174.             <td>Katakana</td>
  10175.             <td> </td>
  10176.             <td>#x3100</td>
  10177.             <td>#x312F</td>
  10178.             <td>Bopomofo</td>
  10179.         </tr>
  10180.         <tr>
  10181.             <td>#x3130</td>
  10182.             <td>#x318F</td>
  10183.             <td>HangulCompatibilityJamo</td>
  10184.             <td> </td>
  10185.             <td>#x3190</td>
  10186.             <td>#x319F</td>
  10187.             <td>Kanbun</td>
  10188.         </tr>
  10189.         <tr>
  10190.             <td>#x31A0</td>
  10191.             <td>#x31BF</td>
  10192.             <td>BopomofoExtended</td>
  10193.             <td> </td>
  10194.             <td>#x3200</td>
  10195.             <td>#x32FF</td>
  10196.             <td>EnclosedCJKLettersandMonths</td>
  10197.         </tr>
  10198.         <tr>
  10199.             <td>#x3300</td>
  10200.             <td>#x33FF</td>
  10201.             <td>CJKCompatibility</td>
  10202.             <td> </td>
  10203.             <td>#x3400</td>
  10204.             <td>#x4DB5</td>
  10205.             <td>CJKUnifiedIdeographsExtensionA</td>
  10206.         </tr>
  10207.         <tr>
  10208.             <td>#x4E00</td>
  10209.             <td>#x9FFF</td>
  10210.             <td>CJKUnifiedIdeographs</td>
  10211.             <td> </td>
  10212.             <td>#xA000</td>
  10213.             <td>#xA48F</td>
  10214.             <td>YiSyllables</td>
  10215.         </tr>
  10216.         <tr>
  10217.             <td>#xA490</td>
  10218.             <td>#xA4CF</td>
  10219.             <td>YiRadicals</td>
  10220.             <td> </td>
  10221.             <td>#xAC00</td>
  10222.             <td>#xD7A3</td>
  10223.             <td>HangulSyllables</td>
  10224.         </tr>
  10225.         <tr>
  10226.             <td>#xD800</td>
  10227.             <td>#xDB7F</td>
  10228.             <td>HighSurrogates</td>
  10229.             <td> </td>
  10230.             <td>#xDB80</td>
  10231.             <td>#xDBFF</td>
  10232.             <td>HighPrivateUseSurrogates</td>
  10233.         </tr>
  10234.         <tr>
  10235.             <td>#xDC00</td>
  10236.             <td>#xDFFF</td>
  10237.             <td>LowSurrogates</td>
  10238.             <td> </td>
  10239.             <td>#xE000</td>
  10240.             <td>#xF8FF</td>
  10241.             <td>PrivateUse</td>
  10242.         </tr>
  10243.         <tr>
  10244.             <td>#xF900</td>
  10245.             <td>#xFAFF</td>
  10246.             <td>CJKCompatibilityIdeographs</td>
  10247.             <td> </td>
  10248.             <td>#xFB00</td>
  10249.             <td>#xFB4F</td>
  10250.             <td>AlphabeticPresentationForms</td>
  10251.         </tr>
  10252.         <tr>
  10253.             <td>#xFB50</td>
  10254.             <td>#xFDFF</td>
  10255.             <td>ArabicPresentationForms-A</td>
  10256.             <td> </td>
  10257.             <td>#xFE20</td>
  10258.             <td>#xFE2F</td>
  10259.             <td>CombiningHalfMarks</td>
  10260.         </tr>
  10261.         <tr>
  10262.             <td>#xFE30</td>
  10263.             <td>#xFE4F</td>
  10264.             <td>CJKCompatibilityForms</td>
  10265.             <td> </td>
  10266.             <td>#xFE50</td>
  10267.             <td>#xFE6F</td>
  10268.             <td>SmallFormVariants</td>
  10269.         </tr>
  10270.         <tr>
  10271.             <td>#xFE70</td>
  10272.             <td>#xFEFE</td>
  10273.             <td>ArabicPresentationForms-B</td>
  10274.             <td> </td>
  10275.             <td>#xFEFF</td>
  10276.             <td>#xFEFF</td>
  10277.             <td>Specials</td>
  10278.         </tr>
  10279.         <tr>
  10280.             <td>#xFF00</td>
  10281.             <td>#xFFEF</td>
  10282.             <td>HalfwidthandFullwidthForms</td>
  10283.             <td> </td>
  10284.             <td>#xFFF0</td>
  10285.             <td>#xFFFD</td>
  10286.             <td>Specials</td>
  10287.         </tr>
  10288.         <tr>
  10289.             <td>#x10300</td>
  10290.             <td>#x1032F</td>
  10291.             <td>OldItalic</td>
  10292.             <td> </td>
  10293.             <td>#x10330</td>
  10294.             <td>#x1034F</td>
  10295.             <td>Gothic</td>
  10296.         </tr>
  10297.         <tr>
  10298.             <td>#x10400</td>
  10299.             <td>#x1044F</td>
  10300.             <td>Deseret</td>
  10301.             <td> </td>
  10302.             <td>#x1D000</td>
  10303.             <td>#x1D0FF</td>
  10304.             <td>ByzantineMusicalSymbols</td>
  10305.         </tr>
  10306.         <tr>
  10307.             <td>#x1D100</td>
  10308.             <td>#x1D1FF</td>
  10309.             <td>MusicalSymbols</td>
  10310.             <td> </td>
  10311.             <td>#x1D400</td>
  10312.             <td>#x1D7FF</td>
  10313.             <td>MathematicalAlphanumericSymbols</td>
  10314.         </tr>
  10315.         <tr>
  10316.             <td>#x20000</td>
  10317.             <td>#x2A6D6</td>
  10318.             <td>CJKUnifiedIdeographsExtensionB</td>
  10319.             <td> </td>
  10320.             <td>#x2F800</td>
  10321.             <td>#x2FA1F</td>
  10322.             <td>CJKCompatibilityIdeographsSupplement</td>
  10323.         </tr>
  10324.         <tr>
  10325.             <td>#xE0000</td>
  10326.             <td>#xE007F</td>
  10327.             <td>Tags</td>
  10328.             <td> </td>
  10329.             <td>#xF0000</td>
  10330.             <td>#xFFFFD</td>
  10331.             <td>PrivateUse</td>
  10332.         </tr>
  10333.         <tr>
  10334.             <td>#x100000</td>
  10335.             <td>#x10FFFD</td>
  10336.             <td>PrivateUse</td>
  10337.             <td> </td>
  10338.             <td> </td>
  10339.             <td> </td>
  10340.             <td> </td>
  10341.         </tr>
  10342.     </tbody>
  10343. </table>
  10344.  
  10345. <note>
  10346. <p>
  10347. <bibref ref='UnicodeDB'/> is subject to future revision.
  10348. For example, the
  10349. grouping of code points into blocks might be updated.  
  10350. All <termref def="dt-minimally-conforming"/> processors <termref def="dt-must"/>
  10351. support the blocks defined in the version of <bibref ref='UnicodeDB'/>
  10352. that is current at the time this specification became a W3C
  10353. Recommendation.  However, implementors are encouraged to support the
  10354. blocks defined in any future version of the Unicode Standard.
  10355. </p>
  10356. </note>
  10357. <p>
  10358. For example, the <termref def="dt-ccesblock"/> for identifying the
  10359. ASCII characters is <code>\p{IsBasicLatin}</code>.
  10360. </p>
  10361. <p>
  10362. <termdef id="dt-ccesN" term="multi-character escape" role='local'>
  10363. A
  10364. <term>multi-character escape</term> provides a simple way to identify
  10365. a commonly used set of characters:
  10366. </termdef>
  10367. </p>
  10368. <scrap>
  10369.     <head>Multi-Character Escape</head>
  10370.     <prod id='multicharesc'>
  10371.         <lhs id='nt-MultiCharEsc'>MultiCharEsc</lhs>
  10372.         <rhs>'.' | ('\' [sSiIcCdDwW])</rhs>
  10373.     </prod>
  10374. </scrap>
  10375. <p/>
  10376. <table border="1" align="center" cellpadding='5'>
  10377. <col width="33%"/>
  10378. <col width="33%"/>
  10379. <col width="33%"/>
  10380. <thead><tr>
  10381. <th>Character sequence</th>
  10382. <!--<th>Name</th>-->
  10383. <th>Equivalent <termref def="dt-charclass"/></th>
  10384. </tr>
  10385. </thead>
  10386. <tbody>
  10387.     <tr>
  10388.         <td align="center">.</td>
  10389. <!--        <td> </td>-->
  10390.         <td align="center">[^\n\r]</td>
  10391.     </tr>
  10392.     <tr>
  10393.         <td align="center">\s</td>
  10394. <!--        <td>white space</td>-->
  10395.         <td align="center">[#x20\t\n\r]</td>
  10396.     </tr>
  10397.     <tr>
  10398.         <td align="center">\S</td>
  10399. <!--        <td> </td>-->
  10400.         <td align="center">[^\s]</td>
  10401.     </tr>
  10402.     <tr>
  10403.         <td align="center">\i</td>
  10404. <!--        <td>XML initial Name character</td>-->
  10405.         <td align="center">
  10406.         <!--[\p{Ll}\p{Lu}\p{Lo}\p{Lt}\p{Nl}_:]
  10407.         <br/>
  10408.         (i.e., 
  10409.         -->the set of initial name characters, those
  10410.         <termref def='dt-match'/>ed by
  10411.         <xspecref href="&xmlspec;#NT-Letter">Letter</xspecref> | '_' | ':'</td>
  10412.     </tr>
  10413.     <tr>
  10414.         <td align="center">\I</td>
  10415. <!--        <td> </td>-->
  10416.         <td align="center">[^\i]</td>
  10417.     </tr>
  10418.     <tr>
  10419.         <td align="center">\c</td>
  10420. <!--        <td>XML Name character</td>-->
  10421.         <td align="center">
  10422. <!--
  10423.         [\i\p{Nd}\p{Mc}\p{Me}\p{Mn}\p{Lm}.#x00B7#x0387-]
  10424.         <br/>
  10425.         (i.e., 
  10426.         -->
  10427.         the set of name characters, those
  10428.         <termref def='dt-match'/>ed by
  10429.         <xspecref href="&xmlspec;#NT-NameChar">NameChar</xspecref></td> 
  10430.     </tr>
  10431.     <tr>
  10432.         <td align="center">\C</td>
  10433. <!--        <td> </td>-->
  10434.         <td align="center">[^\c]</td>
  10435.     </tr>
  10436.     <tr>
  10437.         <td align="center">\d</td>
  10438. <!--        <td>digit (includes digits outside of the 0-9)</td>-->
  10439.         <td align="center">\p{Nd}</td>
  10440.     </tr>
  10441.     <tr>
  10442.         <td align="center">\D</td>
  10443. <!--        <td> </td>-->
  10444.         <td align="center">[^\d]</td>
  10445.     </tr>
  10446.     <tr>
  10447.         <td align="center">\w</td>
  10448. <!--        <td>a "word" character</td>-->
  10449.         <td align="center">
  10450.             [#x0000-#x10FFFF]-[\p{P}\p{Z}\p{C}]
  10451.             (<emph>all characters except the set of "punctuation",
  10452.                 "separator" and "other" characters</emph>)
  10453.         </td>
  10454.     </tr>
  10455.     <tr>
  10456.         <td align="center">\W</td>
  10457. <!--        <td> </td>-->
  10458.         <td align="center">[^\w]</td>
  10459.     </tr>
  10460. </tbody>
  10461. </table>
  10462. <note>
  10463. <p>
  10464. The <termref def="dt-regex"/> language defined here does not
  10465. attempt to provide a general solution to "regular expressions" over
  10466. UCS character sequences.  In particular, it does not easily provide
  10467. for matching sequences of base characters and combining marks.
  10468. The language is targeted at support of "Level 1" features as defined in
  10469. <bibref ref="unicodeRegEx"/>.  It is hoped that future versions of this
  10470. specification will provide support for "Level 2" features.
  10471. </p>
  10472. </note>
  10473. </div3>
  10474. </div2>
  10475. </div1>
  10476. <div1 id="normative-glossary">
  10477. <head>Glossary (non-normative)</head>
  10478. <p>The listing below is for the benefit of readers of a printed version of this
  10479. document:  it collects together all the definitions which appear in the
  10480. document above.</p>
  10481. <ednote role="glossary">
  10482. <edtext>An XSL macro is used to
  10483. collect definitions from throughout the spec and gather them here for easy
  10484. reference.</edtext>
  10485. </ednote>
  10486.  
  10487. </div1>
  10488. <div1 id="biblio">
  10489. <head>References</head>
  10490. <!--
  10491.    bibls can be in any order and the stylesheet will sort them
  10492.    by the value of their key attribute
  10493.   -->
  10494. <div2 id="normative-biblio">
  10495. <head>Normative</head>
  10496. <blist>
  10497. <bibl id="ieee754" key="IEEE 754-1985">
  10498. IEEE. <emph>IEEE Standard for Binary Floating-Point Arithmetic.</emph>
  10499. See <loc href="http://standards.ieee.org/reading/ieee/std_public/description/busarch/754-1985_desc.html">
  10500. http://standards.ieee.org/reading/ieee/std_public/description/busarch/754-1985_desc.html</loc>
  10501. </bibl>
  10502. <bibl id="XLink" key="XML Linking Language">
  10503. World Wide Web Consortium.  XML Linking Language (XLink).
  10504. Available at: <loc href="&xlink;">
  10505. &xlink;</loc>
  10506. </bibl>
  10507. <bibl id="XML" key="XML 1.0 (Second Edition)">
  10508. World Wide Web Consortium. <emph>Extensible Markup Language (XML) 1.0, Second
  10509. Edition.</emph>
  10510. Available at: <loc href="&xmlspec;">&xmlspec;</loc>
  10511. </bibl>
  10512. <bibl id="structural-schemas" key="XML Schema Part 1: Structures">
  10513. XML Schema Part 1: Structures. Available at: <loc href="&xsdl;">
  10514. &xsdl;</loc>
  10515. </bibl>
  10516. <bibl id="schema-requirements" key="XML Schema Requirements">
  10517. World Wide Web Consortium.  XML Schema Requirements.  Available at:
  10518. <loc href="http://www.w3.org/TR/1999/NOTE-xml-schema-req-19990215">
  10519. http://www.w3.org/TR/1999/NOTE-xml-schema-req-19990215</loc>
  10520. </bibl>
  10521. <bibl id="XMLNS" key="Namespaces in XML">
  10522. World Wide Web Consortium.  <emph>Namespaces in XML</emph>. Available at:
  10523. <loc href="&xmlnsspec;">&xmlnsspec;</loc>
  10524. </bibl>
  10525. <bibl id="RFC2396" key="RFC 2396">
  10526. Tim Berners-Lee, et. al. <emph>RFC 2396: Uniform Resource Identifiers (URI):
  10527. Generic Syntax.</emph>. 1998.  Available at:
  10528. <loc href="http://www.ietf.org/rfc/rfc2396.txt">
  10529. http://www.ietf.org/rfc/rfc2396.txt</loc>
  10530. </bibl>
  10531. <bibl id="RFC2732" href="http://www.ietf.org/rfc/rfc2732.txt" key="RFC 2732">
  10532. <emph>RFC
  10533. 2732: Format for Literal IPv6 Addresses in URL's</emph>. 1999.
  10534. Available at:
  10535. <loc href="http://www.ietf.org/rfc/rfc2732.txt">
  10536. http://www.ietf.org/rfc/rfc2732.txt</loc>
  10537. </bibl>
  10538. <bibl id="RFC2045" key="RFC 2045">
  10539. N. Freed and N. Borenstein. <emph>RFC 2045: Multipurpose Internet Mail Extensions
  10540. (MIME) Part One: Format of Internet Message Bodies</emph>. 1996.  Available at:
  10541. <loc href="http://www.ietf.org/rfc/rfc2045.txt">
  10542. http://www.ietf.org/rfc/rfc2045.txt</loc>
  10543. </bibl>
  10544. <bibl id="RFC1766" key="RFC 1766">
  10545. H. Alvestrand, ed. <emph>RFC 1766: Tags for the Identification of Languages</emph>
  10546. 1995. Available at: <loc href="http://www.ietf.org/rfc/rfc1766.txt">
  10547. http://www.ietf.org/rfc/rfc1766.txt</loc>
  10548. </bibl>
  10549. <bibl id="clinger1990" key="Clinger, WD (1990)">
  10550. William D Clinger. <emph>How to Read Floating Point Numbers Accurately.</emph>
  10551. In <emph>Proceedings of Conference on Programming Language Design and
  10552. Implementation</emph>, pages 92-101.
  10553. Available at: <loc href="ftp://ftp.ccs.neu.edu/pub/people/will/howtoread.ps">
  10554. ftp://ftp.ccs.neu.edu/pub/people/will/howtoread.ps</loc>
  10555. </bibl>
  10556. <bibl id="UnicodeDB" key="Unicode Database">
  10557. The Unicode Consortium. <emph>The Unicode Character Database</emph>.
  10558. Available at: <loc href="http://www.unicode.org/Public/3.1-Update/UnicodeCharacterDatabase-3.1.0.html">
  10559. http://www.unicode.org/Public/3.1-Update/UnicodeCharacterDatabase-3.1.0.html</loc>
  10560. </bibl>
  10561. </blist>
  10562. </div2>
  10563. <div2 id="non-normative-biblio">
  10564. <head>Non-normative</head>
  10565. <blist>
  10566.  
  10567. <bibl id="draft-masinter-url-i18n-07" key="IETF INTERNET-DRAFT: IRIs">
  10568. L. Masinter and M. Durst.
  10569. <emph>Internationalized Resource Identifiers</emph>
  10570. 2001. Available at:
  10571. <loc href="http://www.ietf.org/internet-drafts/draft-masinter-url-i18n-07.txt">
  10572. http://www.ietf.org/internet-drafts/draft-masinter-url-i18n-07.txt</loc>
  10573. </bibl>
  10574.  
  10575. <bibl id='ruby' key='Ruby'>
  10576. World Wide Web Consortium.  Ruby Annotation.  Available at:
  10577. <loc href='http://www.w3.org/TR/2001/WD-ruby-20010216/'>
  10578. http://www.w3.org/TR/2001/WD-ruby-20010216/</loc>
  10579. </bibl>
  10580.  
  10581. <bibl id='html4' key='HTML 4.01'>
  10582. World Wide Web Consortium.  Hypertext Markup Language, version 4.01.  Available at:
  10583. <loc href='&html4;'>
  10584. &html4;</loc>
  10585. </bibl>
  10586.  
  10587. <bibl id='schema-primer' key='XML Schema Language: Part 2 Primer'>
  10588. World Wide Web Consortium.  XML Schema Language: Part 2 Primer.  Available at:
  10589. <loc href='http://www.w3.org/TR/2001/REC-xmlschema-0-20010502/'>
  10590. http://www.w3.org/TR/2001/REC-xmlschema-0-20010502/</loc>
  10591. </bibl>
  10592. <bibl id="unicodeRegEx" key="Unicode Regular Expression Guidelines">
  10593. Mark Davis.  <emph>Unicode Regular Expression Guidelines</emph>, 1988.
  10594. Available at: <loc href="http://www.unicode.org/unicode/reports/tr18/">
  10595. http://www.unicode.org/unicode/reports/tr18/</loc>
  10596. </bibl>
  10597. <bibl id="Perl" key="Perl">
  10598. The Perl Programming Language.  See <loc href="http://www.perl.com/pub/language/info/software.html">
  10599. http://www.perl.com/pub/language/info/software.html</loc>
  10600. </bibl>
  10601. <bibl id="SQL" key="SQL">
  10602. ISO (International Organization for Standardization).  <emph>ISO/IEC
  10603. 9075-2:1999, Information technology --- Database languages ---
  10604. SQL --- Part 2: Foundation (SQL/Foundation)</emph>.
  10605. [Geneva]: International Organization for Standardization, 1999.
  10606. See <loc href="http://www.iso.ch/cate/d26197.html">
  10607. http://www.iso.ch/cate/d26197.html</loc>
  10608. </bibl>
  10609. <bibl id="IERS" key="International Earth Rotation Service (IERS)">
  10610. International  Earth Rotation Service (IERS).
  10611. See <loc href="http://maia.usno.navy.mil">http://maia.usno.navy.mil</loc>
  10612. </bibl>
  10613. <bibl id="ISO8601" key="ISO 8601">
  10614. ISO (International Organization for Standardization).
  10615. <emph>Representations of dates and times, 1988-06-15.</emph>  Available at:
  10616. <loc href="http://www.iso.ch/markete/8601.pdf">
  10617. http://www.iso.ch/markete/8601.pdf</loc>  
  10618. </bibl>
  10619. <bibl id="ISO8601revision" key="ISO 8601 Draft Revision">
  10620. ISO (International Organization for Standardization).
  10621. <emph>Representations of dates and times, draft revision, 2000.</emph>
  10622. </bibl>
  10623. <bibl id="ISO11404" key="ISO 11404">
  10624. ISO (International Organization for Standardization).
  10625. <emph>Language-independent Datatypes.</emph>  See
  10626. <loc href=" http://www.iso.ch/cate/d19346.html">
  10627.  http://www.iso.ch/cate/d19346.html</loc>
  10628. </bibl>
  10629. <bibl id="RDFSchema" key="RDF Schema">
  10630. World Wide Web Consortium. <emph>RDF Schema Specification.</emph>
  10631. Available at:
  10632. <loc href="http://www.w3.org/TR/2000/CR-rdf-schema-20000327/">
  10633. http://www.w3.org/TR/2000/CR-rdf-schema-20000327/</loc>
  10634. </bibl>
  10635. <bibl id="USNavy" key="U.S. Naval Observatory Time Service Department">
  10636. <emph>Information about Leap Seconds</emph>
  10637. Available at:
  10638. <loc href="http://tycho.usno.navy.mil/leapsec.990505.html">http://tycho.usno.navy.mil/leapsec.990505.html</loc>
  10639. </bibl>
  10640. <bibl id="XSL" key="XSL">
  10641. World Wide Web Consortium.
  10642. <emph>Extensible Stylesheet Language (XSL).</emph>
  10643. Available at: <loc href="http://www.w3.org/TR/2000/CR-xsl-20001121/">
  10644. http://www.w3.org/TR/2000/CR-xsl-20001121/</loc>
  10645. </bibl>
  10646. <bibl id="CharMod" key="Character Model">
  10647. Martin J. Dürst and François Yergeau, eds.
  10648. Character Model for the World Wide Web. World Wide Web Consortium
  10649. Working Draft. 2001.
  10650. Available at:
  10651. <loc href="&charmod;">&charmod;</loc>
  10652. </bibl>
  10653. <bibl id="gay1990" key="Gay, DM (1990)">
  10654. David M. Gay.  <emph>Correctly Rounded Binary-Decimal and
  10655. Decimal-Binary Conversions.</emph> AT&T Bell Laboratories Numerical
  10656. Analysis Manuscript 90-10, November 1990.
  10657. Available at:
  10658. <loc href="http://cm.bell-labs.com/cm/cs/doc/90/4-10.ps.gz">
  10659. http://cm.bell-labs.com/cm/cs/doc/90/4-10.ps.gz</loc>
  10660. </bibl>
  10661. </blist>
  10662. </div2>
  10663. </div1>
  10664. <div1 id="acknowledgments">
  10665. <head>Acknowledgements (non-normative)</head>
  10666.  <p>The following have contributed material to this draft:</p>
  10667.  <slist>
  10668.   <sitem>Asir S. Vedamuthu, webMethods, Inc</sitem>
  10669.   <sitem>Mark Davis, IBM</sitem>
  10670.  </slist>
  10671. <p>
  10672. Co-editor Ashok Malhotra's work on this specification from March 1999 until
  10673. February 2001 was supported by IBM.
  10674. </p>
  10675. <p>
  10676. The editors acknowledge the members of the XML Schema Working Group, the members of other W3C Working Groups, and industry experts in other
  10677. forums who have contributed directly or indirectly to the process or content of
  10678. creating this document. The Working Group is particularly grateful to Lotus
  10679. Development Corp. and IBM for providing teleconferencing facilities.
  10680. </p>
  10681.  <p>The current members of the XML Schema Working Group are:</p>
  10682. <orglist>
  10683. <member>
  10684.  <name>Jim Barnette</name>
  10685.  <affiliation>Defense Information Systems Agency (DISA)</affiliation>
  10686. </member>
  10687. <member>
  10688.  <name>Paul V. Biron</name>
  10689.  <affiliation>Health Level Seven</affiliation>
  10690. </member>
  10691. <member>
  10692.  <name>Don Box</name>
  10693.  <affiliation>DevelopMentor</affiliation>
  10694. </member>
  10695. <member>
  10696.  <name>Allen Brown</name>
  10697.  <affiliation>Microsoft</affiliation>
  10698. </member>
  10699. <member>
  10700.  <name>Lee Buck</name>
  10701.  <affiliation>TIBCO Extensibility</affiliation>
  10702. </member>
  10703. <member>
  10704.  <name>Charles E. Campbell</name>
  10705.  <affiliation>Informix</affiliation>
  10706. </member>
  10707.  <member>
  10708.   <name>Wayne Carr</name>
  10709.   <affiliation>Intel</affiliation>
  10710.  </member>
  10711. <member>
  10712.  <name>Peter Chen</name>
  10713.  <affiliation>Bootstrap Alliance and LSU</affiliation>
  10714. </member>
  10715. <member>
  10716.  <name>David Cleary</name>
  10717.  <affiliation>Progress Software</affiliation>
  10718. </member>
  10719. <member>
  10720.  <name>Dan Connolly</name>
  10721.  <affiliation>W3C</affiliation>
  10722.  <role>staff contact</role>
  10723. </member>
  10724. <member>
  10725.  <name>Ugo Corda</name>
  10726.  <affiliation>Xerox</affiliation>
  10727. </member>
  10728. <member>
  10729.  <name>Roger L. Costello</name>
  10730.  <affiliation>MITRE</affiliation>
  10731. </member>
  10732.  <member>
  10733.   <name>Haavard Danielson</name>
  10734.   <affiliation>Progress Software</affiliation>
  10735.  </member>
  10736.  <member>
  10737.   <name>Josef Dietl</name>
  10738.   <affiliation>Mozquito Technologies</affiliation>
  10739.  </member>
  10740. <member>
  10741.  <name>David Ezell</name>
  10742.  <affiliation>Hewlett-Packard Company</affiliation>
  10743. </member>
  10744.  <member>
  10745.   <name>Alexander Falk</name>
  10746.   <affiliation>Altova GmbH</affiliation>
  10747.  </member>
  10748. <member>
  10749.  <name>David Fallside</name>
  10750.  <affiliation>IBM</affiliation>
  10751. </member>
  10752.  <member>
  10753.   <name>Dan Fox</name>
  10754.   <affiliation>Defense Logistics Information Service (DLIS)</affiliation>
  10755.  </member>
  10756. <member>
  10757.  <name>Matthew Fuchs</name>
  10758.  <affiliation>Commerce One</affiliation>
  10759. </member>
  10760. <member>
  10761.  <name>Andrew Goodchild</name>
  10762.  <affiliation>Distributed Systems Technology Centre (DSTC Pty Ltd)</affiliation>
  10763. </member>
  10764. <member>
  10765.  <name>Paul Grosso</name>
  10766.  <affiliation>Arbortext, Inc</affiliation>
  10767. </member>
  10768. <member>
  10769.  <name>Martin Gudgin</name>
  10770.  <affiliation>DevelopMentor</affiliation>
  10771. </member>
  10772. <member>
  10773.  <name>Dave Hollander</name>
  10774.  <affiliation>Contivo, Inc</affiliation>
  10775.  <role>co-chair</role>
  10776. </member>
  10777. <member>
  10778.  <name>Mary Holstege</name>
  10779.  <affiliation>Invited Expert</affiliation>
  10780. </member>
  10781. <member>
  10782.  <name>Jane Hunter</name>
  10783.  <affiliation>Distributed Systems Technology Centre (DSTC Pty Ltd)</affiliation>
  10784. </member>
  10785.  <member>
  10786.   <name>Rick Jelliffe</name>
  10787.   <affiliation>Academia Sinica</affiliation>
  10788.  </member>
  10789.  <member>
  10790.   <name>Simon Johnston</name>
  10791.   <affiliation>Rational Software</affiliation>
  10792.  </member>
  10793.  <member>
  10794.   <name>Bob Lojek</name>
  10795.   <affiliation>Mozquito Technologies</affiliation>
  10796.  </member>
  10797. <member>
  10798.  <name>Ashok Malhotra</name>
  10799.  <affiliation>Microsoft</affiliation>
  10800. </member>
  10801.  <member>
  10802.   <name>Lisa Martin</name>
  10803.   <affiliation>IBM</affiliation>
  10804.  </member>
  10805. <member>
  10806.  <name>Noah Mendelsohn</name>
  10807.  <affiliation>Lotus Development Corporation</affiliation>
  10808. </member>
  10809.  <member>
  10810.   <name>Adrian Michel</name>
  10811.   <affiliation>Commerce One</affiliation>
  10812.  </member>
  10813.  <member>
  10814.   <name>Alex Milowski</name>
  10815.   <affiliation>Invited Expert</affiliation>
  10816.  </member>
  10817. <member>
  10818.  <name>Don Mullen</name>
  10819.  <affiliation>TIBCO Extensibility</affiliation>
  10820. </member>
  10821.  <member>
  10822.   <name>Dave Peterson</name>
  10823.   <affiliation>Graphic Communications Association</affiliation>
  10824.  </member>
  10825. <member>
  10826.  <name>Jonathan Robie</name>
  10827.  <affiliation>Software AG</affiliation>
  10828. </member>
  10829. <member>
  10830.  <name>Eric Sedlar</name>
  10831.  <affiliation>Oracle Corp.</affiliation>
  10832. </member>
  10833. <member>
  10834.  <name>C. M. Sperberg-McQueen</name>
  10835.  <affiliation>W3C</affiliation>
  10836.  <role>co-chair</role>
  10837. </member>
  10838. <member>
  10839.  <name>Bob Streich</name>
  10840.  <affiliation>Calico Commerce</affiliation>
  10841. </member>
  10842.  <member>
  10843.   <name>William K. Stumbo</name>
  10844.   <affiliation>Xerox</affiliation>
  10845.  </member>
  10846. <member>
  10847.  <name>Henry S. Thompson</name>
  10848.  <affiliation>University of Edinburgh</affiliation>
  10849. </member>
  10850. <member>
  10851.  <name>Mark Tucker</name>
  10852.  <affiliation>Health Level Seven</affiliation>
  10853. </member>
  10854.  <member>
  10855.   <name>Asir S. Vedamuthu</name>
  10856.   <affiliation>webMethods, Inc</affiliation>
  10857.  </member>
  10858. <member>
  10859.  <name>Priscilla Walmsley</name>
  10860.  <affiliation>XMLSolutions</affiliation>
  10861. </member>
  10862. <member>
  10863.  <name>Norm Walsh</name>
  10864.  <affiliation>Sun Microsystems</affiliation>
  10865. </member>
  10866. <member>
  10867.  <name>Aki Yoshida</name>
  10868.  <affiliation>SAP AG</affiliation>
  10869. </member>
  10870.  <member>
  10871.  <name>Kongyi Zhou</name>
  10872.  <affiliation>Oracle Corp.</affiliation>
  10873. </member>
  10874. </orglist>
  10875.  <p>The XML Schema Working Group has benefited in its work from the
  10876. participation and contributions of a number of people not currently
  10877. members of the Working Group, including
  10878. in particular those named below.  Affiliations given are those current at
  10879. the time of their work with the WG.
  10880. </p>
  10881.  <orglist>
  10882. <member>
  10883.  <name>Paula Angerstein</name>
  10884.  <affiliation>Vignette Corporation</affiliation>
  10885. </member>
  10886. <member>
  10887.  <name>David Beech</name>
  10888.  <affiliation>Oracle Corp.</affiliation>
  10889. </member>
  10890.  <member>
  10891.   <name>Gabe Beged-Dov</name>
  10892.   <affiliation>Rogue Wave Software</affiliation>
  10893.  </member>
  10894. <member>
  10895.  <name>Greg Bumgardner</name>
  10896.  <affiliation>Rogue Wave Software</affiliation>
  10897. </member>
  10898. <member>
  10899.  <name>Dean Burson</name>
  10900.  <affiliation>Lotus Development Corporation</affiliation>
  10901. </member>
  10902.  <member>
  10903.   <name>Mike Cokus</name>
  10904.   <affiliation>MITRE</affiliation>
  10905.  </member>
  10906.  <member>
  10907.  <name>Andrew Eisenberg</name>
  10908.  <affiliation>Progress Software</affiliation>
  10909. </member>
  10910. <member>
  10911.  <name>Rob Ellman</name>
  10912.  <affiliation>Calico Commerce</affiliation>
  10913. </member>
  10914.  <member>
  10915.   <name>George Feinberg</name>
  10916.   <affiliation>Object Design</affiliation>
  10917.  </member>
  10918.  <member>
  10919.   <name>Charles Frankston</name>
  10920.   <affiliation>Microsoft</affiliation>
  10921.  </member>
  10922.  <member>
  10923.   <name>Ernesto Guerrieri</name>
  10924.   <affiliation>Inso</affiliation>
  10925.  </member>
  10926.  <member>
  10927.   <name>Michael Hyman</name>
  10928.   <affiliation>Microsoft</affiliation>
  10929.  </member>
  10930. <member>
  10931.  <name>Renato Iannella</name>
  10932.  <affiliation>Distributed Systems Technology Centre (DSTC Pty Ltd)</affiliation>
  10933. </member>
  10934.  <member>
  10935.   <name>Dianne Kennedy</name>
  10936.   <affiliation>Graphic Communications Association</affiliation>
  10937.  </member>
  10938. <member>
  10939.  <name>Janet Koenig</name>
  10940.  <affiliation>Sun Microsystems</affiliation>
  10941. </member>
  10942. <member>
  10943.  <name>Setrag Khoshafian</name>
  10944.  <affiliation>Technology Deployment International (TDI)</affiliation>
  10945. </member>
  10946. <member>
  10947.  <name>Ara Kullukian</name>
  10948.  <affiliation>Technology Deployment International (TDI)</affiliation>
  10949. </member>
  10950.  <member>
  10951.  <name>Andrew Layman</name>
  10952.  <affiliation>Microsoft</affiliation>
  10953. </member>
  10954. <member>
  10955.  <name>Dmitry Lenkov</name>
  10956.  <affiliation>Hewlett-Packard Company</affiliation>
  10957. </member>
  10958. <member>
  10959.  <name>John McCarthy</name>
  10960.  <affiliation>Lawrence Berkeley National Laboratory</affiliation>
  10961. </member>
  10962. <member>
  10963.  <name>Murata Makoto</name>
  10964.  <affiliation>Xerox</affiliation>
  10965. </member>
  10966. <member>
  10967.  <name>Eve Maler</name>
  10968.  <affiliation>Sun Microsystems</affiliation>
  10969. </member>
  10970. <member>
  10971.  <name>Murray Maloney</name>
  10972.  <affiliation>Muzmo Communication, acting for Commerce One</affiliation>
  10973. </member>
  10974.  <member>
  10975.   <name>Chris Olds</name>
  10976.   <affiliation>Wall Data</affiliation>
  10977.  </member>
  10978. <member>
  10979.  <name>Frank Olken</name>
  10980.  <affiliation>Lawrence Berkeley National Laboratory</affiliation>
  10981. </member>
  10982. <member>
  10983.  <name>Shriram Revankar</name>
  10984.  <affiliation>Xerox</affiliation>
  10985. </member>
  10986. <member>
  10987.  <name>Mark Reinhold</name>
  10988.  <affiliation>Sun Microsystems</affiliation>
  10989. </member>
  10990. <member>
  10991.  <name>John C. Schneider</name>
  10992.  <affiliation>MITRE</affiliation>
  10993. </member>
  10994.  <member>
  10995.   <name>Lew Shannon</name>
  10996.   <affiliation>NCR</affiliation>
  10997.  </member>
  10998.  <member>
  10999.   <name>William Shea</name>
  11000.   <affiliation>Merrill Lynch</affiliation>
  11001.  </member>
  11002.  <member>
  11003.   <name>Ralph Swick</name>
  11004.   <affiliation>W3C</affiliation>
  11005.  </member>
  11006.  <member>
  11007.   <name>Tony Stewart</name>
  11008.   <affiliation>Rivcom</affiliation>
  11009.  </member>
  11010. <member>
  11011.  <name>Matt Timmermans</name>
  11012.  <affiliation>Microstar</affiliation>
  11013. </member>
  11014.   <member>
  11015.  <name>Jim Trezzo</name>
  11016.  <affiliation>Oracle Corp.</affiliation>
  11017. </member>
  11018. <member>
  11019.  <name>Steph Tryphonas</name>
  11020.  <affiliation>Microstar</affiliation>
  11021. </member>
  11022.  </orglist>
  11023. </div1>
  11024. <!--
  11025. <div1 id='open-issues'>
  11026. <head>Open Issues</head>
  11027. <open-issues/>
  11028. </div1>
  11029. <div1 id="revisions">
  11030. <head>Revisions from Previous Draft</head>
  11031. <revisions/>
  11032. </div1>
  11033. -->
  11034. </back>
  11035. </spec>
  11036.