|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.jackrabbit.rmi.value.BaseNonStreamValue
org.apache.jackrabbit.rmi.value.DateValue
public class DateValue
The DateValue class implements the committed value state for
Date values as a part of the State design pattern (Gof) used by this
package.
SerialValue,
Serialized Form| Constructor Summary | |
|---|---|
protected |
DateValue(java.util.Calendar value)
Creates an instance for the given Calendar value. |
protected |
DateValue(java.lang.String value)
Creates a new DateValue initialized to the value
represented by the specified String. |
| Method Summary | |
|---|---|
java.util.Calendar |
getDate()
Returns (a copy) of this Calendar value. |
double |
getDouble()
Returns the time represented by this instance as the number of milliseconds since the epoch (1.1.1970, 0:00, UTC). |
long |
getLong()
Returns the time represented by this instance as the number of milliseconds since the epoch (1.1.1970, 0:00, UTC). |
java.lang.String |
getString()
Returns the string represented of this DateValue value
formatted using a ISO8601-compliant date/time. |
int |
getType()
Returns PropertyType.DATE. |
| Methods inherited from class org.apache.jackrabbit.rmi.value.BaseNonStreamValue |
|---|
getBoolean, getStream, getValueFormatException |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.jcr.Value |
|---|
getBoolean, getStream |
| Constructor Detail |
|---|
protected DateValue(java.util.Calendar value)
Calendar value.
value - the calendar for this value.
protected DateValue(java.lang.String value)
throws javax.jcr.ValueFormatException
DateValue initialized to the value
represented by the specified String.
The specified String must be a ISO8601-compliant date/time
string.
value - the string to be parsed.
javax.jcr.ValueFormatException - If the String is not a valid
ISO8601-compliant date/time string.ISO8601| Method Detail |
|---|
public int getType()
PropertyType.DATE.
getType in interface javax.jcr.Valuepublic double getDouble()
getDouble in interface javax.jcr.ValuegetDouble in class BaseNonStreamValuepublic java.lang.String getString()
DateValue value
formatted using a ISO8601-compliant date/time.
getString in interface javax.jcr.Valuepublic long getLong()
getLong in interface javax.jcr.ValuegetLong in class BaseNonStreamValuepublic java.util.Calendar getDate()
Calendar value. Modifying the
returned Calendar does not change the value of this
instance.
getDate in interface javax.jcr.ValuegetDate in class BaseNonStreamValue
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||