Quantity.
Instances of this class are not required to be thread-safe. It is recommended to use separate format instances for each thread. If multiple threads
access a format concurrently, it must be synchronized externally.
Quantity
| Modifier and Type | Method and Description |
|---|---|
| public Appendable | Returns: the specifiedAppendable.the quantity to format. quantity, Appendable the appendable destination. destination)Formats the specified quantity into an |
| public String | Returns: the string representation using the settings of thisQuantityFormat.the quantity)Quantity to format, not nullFormats the specified |
| public default boolean | Returns: whether this format depends on the locale.Returns |
| public Quantity | Returns: the quantity parsed from the specified character sub-sequence.the csq, ParsePosition CharSequence to parse.a ParsePosition object holding the current parsing index and error parsing index information as described above. pos)Parses a portion of the specified |
| public Quantity | Returns: the quantity parsed from the specified character sub-sequence.the csq)CharSequence to parse.Parses the specified |
| format | back to summary |
|---|---|
| public Appendable format(Quantity<?> quantity, Appendable destination) throws IOException Formats the specified quantity into an
| |
| format | back to summary |
|---|---|
| public String format(Quantity<?> quantity) Formats the specified
| |
| isLocaleSensitive | back to summary |
|---|---|
| public default boolean isLocaleSensitive() Returns
In environments that do not support a
| |
| parse | back to summary |
|---|---|
| public Quantity Parses a portion of the specified
| |
| parse | back to summary |
|---|---|
| public Quantity Parses the specified The parse must complete normally and parse the entire text. If the parse completes without reading the entire length of the text, an exception is thrown. If any other problem occurs during parsing, an exception is thrown.
| |