Class DatatypeHandler
java.lang.Object
org.exolab.castor.xml.schema.util.DatatypeHandler
A class used for "guessing" the proper datatype of
an XML attribute or an XML element with simpleContent.
- Version:
- $Revision: 6944 $ $Date: 2005-03-07 01:33:49 -0700 (Mon, 07 Mar 2005) $
- Author:
- Keith Visco
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe name of the XML Schema boolean typestatic final StringThe name of the XML Schema date typestatic final StringThe name of the XML Schema dateTime typestatic final StringThe name of the XML Schema double typestatic final StringThe name of the XML Schema float typestatic final StringThe name of the XML Schema integer typestatic final StringThe name of the XML Schema long typestatic final StringThe name of the XML Schema string typestatic final StringThe name of the XML Schema time type -
Method Summary
-
Field Details
-
BOOLEAN_TYPE
-
DATE_TYPE
-
DATETIME_TYPE
-
DOUBLE_TYPE
-
FLOAT_TYPE
-
INTEGER_TYPE
-
LONG_TYPE
-
STRING_TYPE
-
TIME_TYPE
-
-
Method Details
-
guessType
Guesses the datatype for the given value. When the type cannot be determined, it simply defaults to DatatypeHandler.STRING_TYPE.
Note: This may be a slow process.- Parameters:
value- the value to determine the type for- Returns:
- the type that the value may be
-
whichType
-