@FunctionalInterface public interface StringValuePresenter
String.| Modifier and Type | Field and Description |
|---|---|
static ConfigProperty<Integer> |
DECIMAL_POSITIONS
Presentation parameter to specify the decimal positions to use to present numeric type values
|
static ConfigProperty<Boolean> |
DISABLE_GROUPING
Presentation parameter to disable the use of grouping symbol for numeric type values
|
static ConfigProperty<Boolean> |
HIDE_DECIMALS_WHEN_ALL_ZERO
Presentation parameter to hide number decimals when all decimal positions (if any) are equal to zero
|
static ConfigProperty<Integer> |
MAX_LENGTH
Presentation parameter to limit the max length of the presented String
|
static ConfigProperty<String> |
MULTIPLE_VALUES_SEPARATOR
Presentation parameter to set the separator to use when presenting multiple values (Arrays and Collections)
|
static ConfigProperty<Boolean> |
PERCENT_STYLE
Presentation parameter to use percent-style format for numeric decimal values
|
static String |
PRESENTATION_PARAMETERS_PREFIX |
static ConfigProperty<TemporalType> |
TEMPORAL_TYPE
|
| Modifier and Type | Method and Description |
|---|---|
static StringValuePresenter |
getDefault()
Get the default
StringValuePresenter, using the LocalizationContext, if available as
Context resource, to format dates and numbers and to localize any Localizable message. |
<T,V extends T> |
present(Class<? extends T> valueType,
V value,
ParameterSet parameters)
Present given
value of given valueType as a String. |
default <T,V extends T> |
present(Class<T> valueType,
V value)
Present given
value of given valueType as a String. |
default String |
present(Object value)
Present given
value as a String. |
default String |
present(Object value,
ParameterSet parameters)
Present given
value as a String using given presentation parameters. |
static final String PRESENTATION_PARAMETERS_PREFIX
static final ConfigProperty<String> MULTIPLE_VALUES_SEPARATOR
static final ConfigProperty<Integer> MAX_LENGTH
static final ConfigProperty<Integer> DECIMAL_POSITIONS
static final ConfigProperty<Boolean> DISABLE_GROUPING
static final ConfigProperty<Boolean> HIDE_DECIMALS_WHEN_ALL_ZERO
static final ConfigProperty<Boolean> PERCENT_STYLE
static final ConfigProperty<TemporalType> TEMPORAL_TYPE
<T,V extends T> String present(Class<? extends T> valueType, V value, ParameterSet parameters)
value of given valueType as a String. Presentation parameters may be
specified passing a ParameterSet.T - Type of the value to presentV - Actual value typevalueType - Value typevalue - Value to presentparameters - Optional presentation parametersdefault <T,V extends T> String present(Class<T> valueType, V value)
value of given valueType as a String.T - Type of the value to presentV - Actual value typevalueType - Value typevalue - Value to presentdefault String present(Object value, ParameterSet parameters)
value as a String using given presentation parameters.value - Value to presentparameters - Optional presentation parametersdefault String present(Object value)
value as a String.value - Value to presentstatic StringValuePresenter getDefault()
StringValuePresenter, using the LocalizationContext, if available as
Context resource, to format dates and numbers and to localize any Localizable message.StringValuePresenterCopyright © 2019 The Holon Platform. All rights reserved.