|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.edustructures.sifworks.SIFSimpleType<java.util.Calendar>
com.edustructures.sifworks.SIFDate
public class SIFDate
Wraps a Java SIFSimpleType to
represent properties in SIF data objects
| Constructor Summary | |
|---|---|
SIFDate(java.util.Calendar value)
Creates an instance of SIFDate that wraps the specified Calendar value |
|
SIFDate(java.util.Date value)
|
|
SIFDate(java.lang.String value)
Deprecated. Since dates can be represented as strings in different formats across SIF Versions, please use SIFFormatter to create dates from strings and use the SIFDate(Calendar) constructor. |
|
| Method Summary | |
|---|---|
java.util.Date |
getDate()
Gets the date as a java.util.Date object |
SIFTypeConverter<java.util.Calendar> |
getTypeConverter()
Returns a type converter that can be used to create an instance of the datatype from a string |
static java.util.Calendar |
parseSIF1xDate(java.lang.String yyyyMMdd)
Parse a SIFDate string into a Calendar instance |
static java.util.Calendar |
parseSIFDateString(java.lang.String value,
SIFVersion version)
Parse a SIFDate string, using the appropriate format for the specified version of SIF |
| Methods inherited from class com.edustructures.sifworks.SIFSimpleType |
|---|
createField, equals, getDataType, getSQLType, getValue, hashCode, isDoNotEncode, toString, toString, toString |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SIFDate(java.util.Calendar value)
value - The Calendar value to wrap in this instancepublic SIFDate(java.util.Date value)
value - The Date value to wrap. This value will be converted
and stored as a calendarpublic SIFDate(java.lang.String value)
SIFDate(Calendar) constructor.
value - The SIF 1.5 formatted date to wrap in the format "yyyyMMdd"
java.lang.NumberFormatException - if the value being set cannot be parsed into
the datatype being stored for this field| Method Detail |
|---|
public java.util.Date getDate()
java.util.Date object
public static java.util.Calendar parseSIF1xDate(java.lang.String yyyyMMdd)
yyyyMMdd - The string representation of the date in the format "yyyyMMdd"
java.lang.NumberFormatException - If the date cannot be parsed
public static java.util.Calendar parseSIFDateString(java.lang.String value,
SIFVersion version)
value - The string value to parse into a dateversion - The SIFVersion to use for parsing the string
java.lang.NumberFormatException - If the date cannot be parsedpublic SIFTypeConverter<java.util.Calendar> getTypeConverter()
SIFSimpleType
getTypeConverter in class SIFSimpleType<java.util.Calendar>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||