|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD | ||||||||
java.lang.Objectjava.lang.Enum<ODValueType>
org.jopendocument.dom.ODValueType
public enum ODValueType
A type of value, as per 16.1 "Data Types" and 6.7.1 "Variable Value Types and Values"
| Enum Constant Summary | |
|---|---|
BOOLEAN
|
|
CURRENCY
|
|
DATE
|
|
FLOAT
Parses to BigDecimal to return the exact number. |
|
PERCENTAGE
|
|
STRING
|
|
TIME
|
|
| Method Summary | |
|---|---|
boolean |
canFormat(java.lang.Class<?> toFormat)
|
abstract java.lang.String |
format(java.lang.Object o)
|
static ODValueType |
forObject(java.lang.Object o)
Try to guess the value type for the passed object. |
static ODValueType |
get(java.lang.String name)
The instance for the passed value type. |
java.lang.String |
getName()
The value for the value-type attribute. |
java.lang.String |
getValueAttribute()
The name of the value attribute for this value type. |
abstract java.lang.Object |
parse(java.lang.String s)
|
static ODValueType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. |
static ODValueType[] |
values()
Returns an array containing the constants of this enum type, in the order they are declared. |
| Methods inherited from class java.lang.Enum |
|---|
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Enum Constant Detail |
|---|
public static final ODValueType FLOAT
BigDecimal to return the exact number.
public static final ODValueType PERCENTAGE
public static final ODValueType CURRENCY
public static final ODValueType DATE
public static final ODValueType TIME
public static final ODValueType BOOLEAN
public static final ODValueType STRING
| Method Detail |
|---|
public static ODValueType[] values()
for (ODValueType c : ODValueType.values()) System.out.println(c);
public static ODValueType valueOf(java.lang.String name)
name - the name of the enum constant to be returned.
java.lang.IllegalArgumentException - if this enum type has no constant
with the specified name
java.lang.NullPointerException - if the argument is nullpublic final java.lang.String getValueAttribute()
public boolean canFormat(java.lang.Class<?> toFormat)
public abstract java.lang.String format(java.lang.Object o)
public abstract java.lang.Object parse(java.lang.String s)
public final java.lang.String getName()
public static ODValueType get(java.lang.String name)
name - the value of the value-type attribute, e.g. "date".
null, e.g. DATE.
java.lang.IllegalArgumentException - if name isn't a valid type.
public static ODValueType forObject(java.lang.Object o)
throws java.lang.NullPointerException
o - the object.
o or null.
java.lang.NullPointerException - if o is null.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD | ||||||||