| Modifier and Type | Field and Description |
|---|---|
| private volatile ConfigurableConversionService | |
| private boolean | |
| protected final Log | |
| private PropertyPlaceholderHelper | |
| private String | |
| private String | |
| private final Set | |
| private PropertyPlaceholderHelper | |
| private String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | containsProperty(String key)
Implements org. Return whether the given property key is available for resolution,
i.e. if the value for the given key is not |
| protected <T> T | Returns: the converted value, or the original value if no conversion is necessarythe original property value value, Class<T> the specified target type for property retrieval targetType)Convert the given value to the specified target type, if necessary. |
| private PropertyPlaceholderHelper | |
| private String | |
| public ConfigurableConversionService | getConversionService()
Implements org. Return the |
| public String | getProperty(String
the property name to resolve key)Implements org. Return the property value associated with the given key,
or |
| public String | getProperty(String
the property name to resolve key, String the default value to return if no value is found defaultValue)Implements org. Return the property value associated with the given key, or
|
| public <T> T | getProperty(String
the property name to resolve key, Class<T> the expected type of the property value targetType, T the default value to return if no value is found defaultValue)Implements org. Return the property value associated with the given key,
or |
| protected abstract String | Returns: the property value ornull if none foundthe property name to resolve key)Retrieve the specified property as a raw String, i.e. without resolution of nested placeholders. |
| public String | getRequiredProperty(String key)
Implements org. Return the property value associated with the given key (never |
| public <T> T | getRequiredProperty(String key, Class<T> valueType)
Implements org. Return the property value associated with the given key, converted to the given
targetType (never |
| protected String | resolveNestedPlaceholders(String value)
Resolve placeholders within the given string, deferring to the value of
|
| public String | resolvePlaceholders(String
the String to resolve text)Implements org. Resolve ${...} placeholders in the given text, replacing them with corresponding
property values as resolved by |
| public String | resolveRequiredPlaceholders(String text)
Implements org. Resolve ${...} placeholders in the given text, replacing them with corresponding
property values as resolved by |
| public void | setConversionService(ConfigurableConversionService conversionService)
Implements org. Set the |
| public void | setIgnoreUnresolvableNestedPlaceholders(boolean ignoreUnresolvableNestedPlaceholders)
Implements org. Set whether to throw an exception when encountering an unresolvable placeholder nested within the value of a given property. |
| public void | setPlaceholderPrefix(String placeholderPrefix)
Implements org. Set the prefix that placeholders replaced by this resolver must begin with. |
| public void | setPlaceholderSuffix(String placeholderSuffix)
Implements org. Set the suffix that placeholders replaced by this resolver must end with. |
| public void | setRequiredProperties(String... requiredProperties)
Implements org. Specify which properties must be present, to be verified by
|
| public void | setValueSeparator(String valueSeparator)
Implements org. Specify the separating character between the placeholders replaced by this
resolver and their associated default value, or |
| public void | validateRequiredProperties()
Implements org. Validate that each of the properties specified by
|
| conversionService | back to summary |
|---|---|
| private volatile ConfigurableConversionService conversionService
| |
| ignoreUnresolvableNestedPlaceholders | back to summary |
|---|---|
| private boolean ignoreUnresolvableNestedPlaceholders | |
| logger | back to summary |
|---|---|
| protected final Log logger | |
| nonStrictHelper | back to summary |
|---|---|
| private PropertyPlaceholderHelper nonStrictHelper
| |
| placeholderPrefix | back to summary |
|---|---|
| private String placeholderPrefix | |
| placeholderSuffix | back to summary |
|---|---|
| private String placeholderSuffix | |
| requiredProperties | back to summary |
|---|---|
| private final Set<String> requiredProperties | |
| strictHelper | back to summary |
|---|---|
| private PropertyPlaceholderHelper strictHelper
| |
| valueSeparator | back to summary |
|---|---|
| private String valueSeparator
| |
| AbstractPropertyResolver | back to summary |
|---|---|
| public AbstractPropertyResolver() | |
| containsProperty | back to summary |
|---|---|
| public boolean containsProperty(String key) Implements org. Doc from org. Return whether the given property key is available for resolution,
i.e. if the value for the given key is not
| |
| convertValueIfNecessary | back to summary |
|---|---|
| protected <T> T convertValueIfNecessary(Object value, Class<T> targetType) Convert the given value to the specified target type, if necessary.
| |
| createPlaceholderHelper | back to summary |
|---|---|
| private PropertyPlaceholderHelper createPlaceholderHelper(boolean ignoreUnresolvablePlaceholders) | |
| doResolvePlaceholders | back to summary |
|---|---|
| private String doResolvePlaceholders(String text, PropertyPlaceholderHelper helper) | |
| getConversionService | back to summary |
|---|---|
| public ConfigurableConversionService getConversionService() Implements org. Doc from org. Return the The configurable nature of the returned conversion service allows for
the convenient addition and removal of individual ConfigurableConversionService cs = env.getConversionService(); cs.addConverter(new FooConverter());
| |
| getProperty | back to summary |
|---|---|
| public String getProperty(String key) Implements org. Doc from org. Return the property value associated with the given key,
or | |
| getProperty | back to summary |
|---|---|
| public String getProperty(String key, String defaultValue) Implements org. Doc from org. Return the property value associated with the given key, or
| |
| getProperty | back to summary |
|---|---|
| public <T> T getProperty(String key, Class<T> targetType, T defaultValue) Implements org. Doc from org. Return the property value associated with the given key,
or | |
| getPropertyAsRawString | back to summary |
|---|---|
| protected abstract String getPropertyAsRawString(String key) Retrieve the specified property as a raw String, i.e. without resolution of nested placeholders. | |
| getRequiredProperty | back to summary |
|---|---|
| public String getRequiredProperty(String key) throws IllegalStateException Implements org. Doc from org. Return the property value associated with the given key (never
| |
| getRequiredProperty | back to summary |
|---|---|
| public <T> T getRequiredProperty(String key, Class<T> valueType) throws IllegalStateException Implements org. Doc from org. Return the property value associated with the given key, converted to the given
targetType (never
| |
| resolveNestedPlaceholders | back to summary |
|---|---|
| protected String resolveNestedPlaceholders(String value) Resolve placeholders within the given string, deferring to the value of
Invoked from
| |
| resolvePlaceholders | back to summary |
|---|---|
| public String resolvePlaceholders(String text) Implements org. Doc from org. Resolve ${...} placeholders in the given text, replacing them with corresponding
property values as resolved by | |
| resolveRequiredPlaceholders | back to summary |
|---|---|
| public String resolveRequiredPlaceholders(String text) throws IllegalArgumentException Implements org. Doc from org. Resolve ${...} placeholders in the given text, replacing them with corresponding
property values as resolved by
| |
| setConversionService | back to summary |
|---|---|
| public void setConversionService(ConfigurableConversionService conversionService) Implements org. Doc from org. Set the Note as an alternative to fully replacing the
| |
| setIgnoreUnresolvableNestedPlaceholders | back to summary |
|---|---|
| public void setIgnoreUnresolvableNestedPlaceholders(boolean ignoreUnresolvableNestedPlaceholders) Implements org. Set whether to throw an exception when encountering an unresolvable placeholder
nested within the value of a given property. A The default is
| |
| setPlaceholderPrefix | back to summary |
|---|---|
| public void setPlaceholderPrefix(String placeholderPrefix) Implements org. Set the prefix that placeholders replaced by this resolver must begin with. The default is "${".
| |
| setPlaceholderSuffix | back to summary |
|---|---|
| public void setPlaceholderSuffix(String placeholderSuffix) Implements org. Set the suffix that placeholders replaced by this resolver must end with. The default is "}".
| |
| setRequiredProperties | back to summary |
|---|---|
| public void setRequiredProperties(String... requiredProperties) Implements org. Doc from org. Specify which properties must be present, to be verified by
| |
| setValueSeparator | back to summary |
|---|---|
| public void setValueSeparator(String valueSeparator) Implements org. Specify the separating character between the placeholders replaced by this
resolver and their associated default value, or The default is ":".
| |
| validateRequiredProperties | back to summary |
|---|---|
| public void validateRequiredProperties() Implements org. Doc from org. Validate that each of the properties specified by
| |