|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.exoplatform.services.jcr.rmi.api.value.BaseNonStreamValue
org.exoplatform.services.jcr.rmi.api.value.LongValue
public class LongValue
The LongValue class implements the committed value state for Long values as a part
of the State design pattern (Gof) used by this package.
SerialValue,
Serialized Form| Field Summary |
|---|
| Fields inherited from class org.exoplatform.services.jcr.rmi.api.value.BaseNonStreamValue |
|---|
orderNumber |
| Constructor Summary | |
|---|---|
protected |
LongValue(long value)
Creates an instance for the given long value. |
protected |
LongValue(java.lang.String value)
Creates an instance for the given string representation of a long. |
| Method Summary | |
|---|---|
java.util.Calendar |
getDate()
Returns a Calendar instance interpreting the long as the time in milliseconds
since the epoch (1.1.1970, 0:00, UTC). |
double |
getDouble()
Returns the value converted to a double. |
long |
getLength()
|
long |
getLong()
Returns the double value. |
int |
getOrderNumber()
|
java.lang.String |
getString()
Returns the long as a string converted by the Long.toString(long). |
int |
getType()
Returns PropertyType.LONG. |
protected static long |
toLong(java.lang.String value)
Returns the long value represented by the string value. |
| Methods inherited from class org.exoplatform.services.jcr.rmi.api.value.BaseNonStreamValue |
|---|
getBoolean, getReference, getStream, getValueFormatException, setOrderNumber |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.exoplatform.services.jcr.core.value.ExtendedValue |
|---|
getReference, setOrderNumber |
| Methods inherited from interface javax.jcr.Value |
|---|
getBoolean, getStream |
| Constructor Detail |
|---|
protected LongValue(long value)
value.
protected LongValue(java.lang.String value)
throws javax.jcr.ValueFormatException
This implementation uses the Long.valueOf(String) method to convert the string to
a long.
javax.jcr.ValueFormatException - if the string value cannot be parsed to long.| Method Detail |
|---|
protected static long toLong(java.lang.String value)
throws javax.jcr.ValueFormatException
value.
javax.jcr.ValueFormatException - if the string value cannot be parsed to long.public int getType()
PropertyType.LONG.
getType in interface javax.jcr.Valuepublic java.util.Calendar getDate()
Calendar instance interpreting the long as the time in milliseconds
since the epoch (1.1.1970, 0:00, UTC).
getDate in interface javax.jcr.ValuegetDate in class BaseNonStreamValuepublic long getLong()
getLong in interface javax.jcr.ValuegetLong in class BaseNonStreamValuepublic java.lang.String getString()
Long.toString(long).
getString in interface javax.jcr.Valuepublic double getDouble()
getDouble in interface javax.jcr.ValuegetDouble in class BaseNonStreamValuepublic long getLength()
getLength in interface ExtendedValuepublic int getOrderNumber()
getOrderNumber in interface ExtendedValuegetOrderNumber in class BaseNonStreamValue
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||