RELAX NG by Eric van der Vlist will be published by O'Reilly & Associates (ISBN: 0596004214)

You are welcome to use our annotation system to give your feedback.


When to use string datatypes

It's amazing to think that despite all the complex applications that have been made possible by SGML and XML, whitespace processing, which seems as if it should be simple, has remained a nightmare for users and programmers. The string datatype will expose you to all the issues related to whitespace handling. A huge number of users and applications will modify whitespace in your documents to meet their expectations. They can make documents become invalid.

The token datatype keeps this nightmare from creating problems, and that is why RELAX NG uses token as its default datatype. Keep in mind that you shouldn't use the string datatype unless you have a good reason to do so. If whitespace is genuinely significant to your information, use the string type. Otherwise, don't.


You are welcome to use our annotation system to give your feedback.
[Annotations for this page]
All text is copyright Eric van der Vlist, Dyomedea. During development, I give permission for non-commercial copying for educational and review purposes. After publication, all text will be released under the Free Software Foundation GFDL.