public interface PropertySource
PropertiesPropertySource| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
get(java.lang.String key)
Get the value of a property or null if not found
|
<T> T |
get(java.lang.String key,
java.lang.Class<T> type)
Get a property value of a specific type
|
<T> T |
get(java.lang.String key,
java.lang.Class<T> type,
T defaultValue)
Get a property value of a specific type while returning a
default value if the property is not set.
|
java.lang.String |
get(java.lang.String key,
java.lang.String defaultValue)
Get the value of a property or default if not found
|
boolean |
hasProperty(java.lang.String key)
Determine if the PropertySource contains the specified property key
|
java.lang.String get(java.lang.String key)
key - Name of property to fetchjava.lang.String get(java.lang.String key,
java.lang.String defaultValue)
key - Name of property to fetchdefaultValue - <T> T get(java.lang.String key,
java.lang.Class<T> type)
key - Name of property to fetchtype - Type of value requested<T> T get(java.lang.String key,
java.lang.Class<T> type,
T defaultValue)
key - Name of property to fetchtype - Type of value requesteddefaultValue - Default value to return if key not foundboolean hasProperty(java.lang.String key)