Powered by SmartDoc

Datatypes

In the HelloWorld example, we used the string type only. But Relaxer supports all datatypes defined by RELAX.

XML Schema 2 DataType(SimpleType)
Category Type Meaning Content Attribute Java
String string String O O String
Name XML Name O O
QName XML Qualified Name O O
NCName XML non-colonized Name O O
Number decimal Infinite accuracy number O O BigDecimal
boolean boolean value O O boolean/Boolean
float 16bit floating point number O O float/Float
double 32bit floating point number O O
integer Infinite accuracy integer O O BigInteger
nonPositiveInteger Infinite accuracy integer less than 0 O O BigInteger
negativeInteger Infinite accuracy integer less than 0 O O BigInteger
long 64bit integer O O long/Long
int 32bit integer O O int/Integer
short 16bit integer O O short/Short
byte 8bit integer O O byte/Byte
nonNegativeInteger Infinite accuracy integer more than 0 O O BigInteger
positiveInteger Infinite accuracy integer more than 1 O O BigInteger
unsignedLong Unsigned 64bit integer O O BigInteger
unsignedInt Unsigned 32bit integer O O long/Long
unsignedShort Unsigned 16bit integer O O int/Integer
unsignedByte Unsigned 8bit integer O O short/Short
Time timeInstant Date+Time O O Date
timeDuration Progress time O O -
recurringInstant O O
date Date O O -
time Time O O -
XML1.0?? ID XML1.0 ID - O -
IDREF XML1.0 IDREF - O -
ENTITY XML1.0 ENTITY - O -
NOTATION XML1.0 NOTATION - O -
IDREFS XML1.0 IDREFS - O -
ENTITIES XML 1.0 ENTITIES - O -
NMTOKEN XML 1.0 NMTOKEN - O -
NMTOKENS XML 1.0 NMTOKENS - O -
Etc. binary Binary O O byte[]
uriReference URI O O (URL)
language Language O O Locale