XML technologies / XML Schema / Data type reference / xs:NMTOKEN
(Excerpt from “XML Schema” by Eric van der Vlist)
XML 1.0 name tokens (NMTOKEN)
Derived from: xs:token
Primitive type: xs:string
Known subtypes: xs:NMTOKENS
Facets: xs:enumeration, xs:length, xs:maxLength, xs:minLength, xs:pattern, xs:whiteSpace
Definition
<xs:simpleType name="NMTOKEN" id="NMTOKEN">
<xs:restriction base="xs:token">
<xs:pattern value="\c+"/>
</xs:restriction>
</xs:simpleType>Description
The lexical and value spaces of xs:NMTOKEN consist of XML 1.0 name tokens: tokens composed of letters, digits, ., :, - and characters defined by Unicode, such as combining or extender characters.
Restrictions
This type is usually called a token.
Example
Valid values include "Snoopy", "CMS", "1950-10-04" or "0836217462".
Invalid values include "brachte die klassische Musik in die Peanuts-Comics ein" (spaces are forbidden) or "kühn,dreist" (commas are forbidden).
Copyright © 2003 O'Reilly Verlag GmbH & Co. KG
You may print the online version for your private use.
Otherwise, this chapter from “XML Schema” is subject to the same conditions as the bound edition. The work, including all its parts, is protected by copyright. All rights reserved, including reproduction, translation, microfilming, and storage and processing in electronic systems.
O’Reilly Verlag GmbH & Co. KG, Balthasarstraße 81, 50670 Köln, kommentar(at)oreilly.de