public class JodaDateTimeFormat extends CustomXMLFormat<org.joda.time.DateTime>
DateTime, that stores the millis, chronology and
time zone as separate attributes. If the chronlogy is ISOChronology,
the attribute is omitted, thus ISOChronology is seen as default. If
the time zone is the default time zone (DateTimeZone.getDefault()),
the time zone attribute is omitted. This requires different machines to
have the same time zone settings.
The following chronologies are supported:
ISOChronologyCopticChronologyEthiopicChronologyGregorianChronologyJulianChronologyIslamicChronologyBuddhistChronologyGJChronologyAPPENDABLE_XML, BOOLEAN_XML, BYTE_XML, CHARACTER_XML, CLASS_XML, COLLECTION_XML, CONFIGURABLE_XML, DOUBLE_XML, FAST_COLLECTION_XML, FAST_COMPARATOR_XML, FAST_MAP_XML, FLOAT_XML, INDEX_XML, INTEGER_XML, LONG_XML, MAP_XML, OBJECT_ARRAY_XML, OBJECT_XML, PERSISTENT_CONTEXT_XML, QNAME_XML, SHORT_XML, STRING_XML, TEXT_XML| Constructor and Description |
|---|
JodaDateTimeFormat() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canConvert(Class<?> cls)
Used to determine if this
XMLFormat can handle the given class, both
during serialization and deserialization. |
org.joda.time.DateTime |
newInstance(Class<org.joda.time.DateTime> cls,
javolution.xml.XMLFormat.InputElement input) |
void |
read(javolution.xml.XMLFormat.InputElement input,
org.joda.time.DateTime obj) |
void |
write(org.joda.time.DateTime obj,
javolution.xml.XMLFormat.OutputElement output) |
getTargetClasspublic boolean canConvert(Class<?> cls)
XMLFormat can handle the given class, both
during serialization and deserialization.canConvert in class CustomXMLFormat<org.joda.time.DateTime>cls - the class to checktrue if this XMLFormat serializes/deserializes instances of the provided class.public org.joda.time.DateTime newInstance(Class<org.joda.time.DateTime> cls, javolution.xml.XMLFormat.InputElement input) throws javolution.xml.stream.XMLStreamException
newInstance in class javolution.xml.XMLFormat<org.joda.time.DateTime>javolution.xml.stream.XMLStreamExceptionpublic void read(javolution.xml.XMLFormat.InputElement input,
org.joda.time.DateTime obj)
throws javolution.xml.stream.XMLStreamException
read in class javolution.xml.XMLFormat<org.joda.time.DateTime>javolution.xml.stream.XMLStreamExceptionpublic void write(org.joda.time.DateTime obj,
javolution.xml.XMLFormat.OutputElement output)
throws javolution.xml.stream.XMLStreamException
write in class javolution.xml.XMLFormat<org.joda.time.DateTime>javolution.xml.stream.XMLStreamExceptionCopyright © 2009-2016. All Rights Reserved.