V - generic type of element valuespublic interface TextElement<V> extends ChronoElement<V>
A chronological element which can be formatted as text or can be parsed from a text.
| Modifier and Type | Method and Description |
|---|---|
V |
parse(java.lang.CharSequence text,
java.text.ParsePosition status,
AttributeQuery attributes)
Interpretes the given text as element value.
|
void |
print(ChronoDisplay context,
java.lang.Appendable buffer,
AttributeQuery attributes)
Converts the element value in given context to a formatted text.
|
compare, getDefaultMaximum, getDefaultMinimum, getSymbol, getType, isDateElement, isLenient, isTimeElement, namevoid print(ChronoDisplay context, java.lang.Appendable buffer, AttributeQuery attributes) throws java.io.IOException
Converts the element value in given context to a formatted text.
Implementation note: The concrete element value is obtainable by the
expression context.get(this).
context - time context with the value of this elementbuffer - format buffer any text output will be sent toattributes - query for control attributesjava.io.IOException - if writing to buffer failsV parse(java.lang.CharSequence text, java.text.ParsePosition status, AttributeQuery attributes)
Interpretes the given text as element value.
Implementation note: Any implementation will start first at the
position status.getIndex() and
either set the new position after successful parsing or return
null in case of error.
text - text to be parsedstatus - current parsing positionattributes - query for control attributesnull if parsing
was not successful