public final class TextAccessor
extends java.lang.Object
Supplies an access to the internal name list of an enum-based element value.
CalendarText| Modifier and Type | Method and Description |
|---|---|
<V extends java.lang.Enum<V>> |
parse(java.lang.CharSequence parseable,
java.text.ParsePosition status,
java.lang.Class<V> valueType)
Interpretes given text form as enum-based element value.
|
<V extends java.lang.Enum<V>> |
parse(java.lang.CharSequence parseable,
java.text.ParsePosition status,
java.lang.Class<V> valueType,
AttributeQuery attributes)
Interpretes given text form as enum-based element value.
|
java.lang.String |
print(java.lang.Enum<?> value)
Prints the given element value as String.
|
java.lang.String |
toString()
Supports mainly debugging.
|
public java.lang.String print(java.lang.Enum<?> value)
Prints the given element value as String.
If the element value has no localized representation then this method will simply print the enum name.
value - current value of elementpublic <V extends java.lang.Enum<V>> V parse(java.lang.CharSequence parseable,
java.text.ParsePosition status,
java.lang.Class<V> valueType)
Interpretes given text form as enum-based element value.
Parsing is case-insensitive. No partial compare is performed, instead the whole element text will be evaluated.
V - generic value type of elementparseable - text to be parsedstatus - current parsing positionvalueType - value class of elementnull if not foundparse(CharSequence, ParsePosition, Class, AttributeQuery)public <V extends java.lang.Enum<V>> V parse(java.lang.CharSequence parseable,
java.text.ParsePosition status,
java.lang.Class<V> valueType,
AttributeQuery attributes)
Interpretes given text form as enum-based element value.
The attributes Attributes.PARSE_CASE_INSENSITIVE and
Attributes.PARSE_PARTIAL_COMPARE will be evaluated.
V - generic value type of elementparseable - text to be parsedstatus - current parsing positionvalueType - value class of elementattributes - format attributesnull if not foundAttributes.PARSE_CASE_INSENSITIVE,
Attributes.PARSE_PARTIAL_COMPAREpublic java.lang.String toString()
Supports mainly debugging.
toString in class java.lang.Object