public final class TextAccessor extends Object
Supplies an access to the internal name list of an enum-based element value.
CalendarText| Modifier and Type | Method and Description |
|---|---|
<V extends Enum<V>> |
parse(CharSequence parseable,
ParsePosition status,
Class<V> valueType)
Interpretes given text form as enum-based element value.
|
<V extends Enum<V>> |
parse(CharSequence parseable,
ParsePosition status,
Class<V> valueType,
AttributeQuery attributes)
Interpretes given text form as enum-based element value.
|
String |
print(Enum<?> value)
Prints the given element value as String.
|
String |
toString()
Supports mainly debugging.
|
public String print(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 Enum<V>> V parse(CharSequence parseable, ParsePosition status, 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 Enum<V>> V parse(CharSequence parseable, ParsePosition status, 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_COMPARECopyright © 2014–2015. All rights reserved.