Package org.forgerock.config.resolvers
Interface PropertyResolver
- 
- All Known Implementing Classes:
- ChainedPropertyResolver,- EnvironmentVariableResolver,- FlatFileResolver,- JsonValueResolver,- ProductPathResolver,- PropertiesResolver,- SystemPropertyResolver
 
 public interface PropertyResolverA property resolver attempt to get the value of a given config property.
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description default Optional<String>getProperty(String key)Deprecated.In favour ofgetProperty(String, boolean)Optional<String>getProperty(String key, boolean sensitive)Returns the value of the specified property.default Optional<String>getProperty(String key, String defaultValue)Deprecated.In favour ofgetProperty(String, String, boolean)default Optional<String>getProperty(String key, String defaultValue, boolean sensitive)Returns the value of the specified property.
 
- 
- 
- 
Method Detail- 
getProperty@Deprecated default Optional<String> getProperty(String key) Deprecated.In favour ofgetProperty(String, boolean)Returns the value of the specified property. The method returns an emptyOptionalif the property is not found. The resolved property is considered as sensitive and will not appear in logs.- Parameters:
- key- The name of the requested property. The key can't be null.
- Returns:
- An Optionalstring that contains the value of the requested property, or emptyOptionalif property is undefined.
- Throws:
- NullPointerException- if key is null.
 
 - 
getPropertyOptional<String> getProperty(String key, boolean sensitive) Returns the value of the specified property. The method returns an emptyOptionalif the property is not found. The resolved property has to be considered sensitive ifsensitiveistrueand implementations are required to handle it with special attention (no logs, ...).- Parameters:
- key- The name of the requested property. The key can't be null.
- sensitive-- trueis the property value has to be considered a sensitive value (such as a password).
- Returns:
- An Optionalstring that contains the value of the requested property, or emptyOptionalif property is undefined.
- Throws:
- NullPointerException- if key is null.
 
 - 
getProperty@Deprecated default Optional<String> getProperty(String key, String defaultValue) Deprecated.In favour ofgetProperty(String, String, boolean)Returns the value of the specified property. The method returns an emptyOptionalif the property is not found and there is no default value provided. The resolved property is considered as sensitive and will not appear in logs.- Parameters:
- key- The name of the requested property. The key can't be null.
- defaultValue- The default value if the property is not defined.
- Returns:
- An Optionalstring that contains the value of the requested property, or emptyOptionalif property is undefined and a default is not supplied.
- Throws:
- NullPointerException- if key is null.
 
 - 
getPropertydefault Optional<String> getProperty(String key, String defaultValue, boolean sensitive) Returns the value of the specified property. The method returns an emptyOptionalif the property is not found and there is no default value provided. The resolved property has to be considered sensitive ifsensitiveistrueand implementations are required to handle it with special attention (no logs, ...).- Parameters:
- key- The name of the requested property. The key can't be null.
- defaultValue- The default value if the property is not defined.
- sensitive-- trueis the property value has to be considered a sensitive value (such as a password).
- Returns:
- An Optionalstring that contains the value of the requested property, or emptyOptionalif property is undefined and a default is not supplied.
- Throws:
- NullPointerException- if key is null.
 
 
- 
 
-