Package ej.property
Interface PropertyRegistry
-
- All Superinterfaces:
PropertyLoader
- All Known Subinterfaces:
SharedPropertyRegistry
- All Known Implementing Classes:
SimplePropertyRegistry
public interface PropertyRegistry extends PropertyLoader
A property registry is a property loader that allows to add or remove properties dynamically.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.StringremoveProperty(java.lang.String key)Removes a property.java.lang.StringsetProperty(java.lang.String key, java.lang.String value)Sets a property that maps a key to a value.-
Methods inherited from interface ej.property.PropertyLoader
getProperty, getProperty
-
-
-
-
Method Detail
-
setProperty
@Nullable java.lang.String setProperty(java.lang.String key, java.lang.String value)Sets a property that maps a key to a value.- Parameters:
key- the key.value- the value.- Returns:
- the previous value of the property, or
nullif the property is not found. - Throws:
java.lang.SecurityException- if a security manager exists and does not allow the caller to set the given property.
-
removeProperty
@Nullable java.lang.String removeProperty(java.lang.String key)
Removes a property.- Parameters:
key- the key.- Returns:
- the value of the property, or
nullif the property is not found. - Throws:
java.lang.SecurityException- if a security manager exists and does not allow the caller to remove the given property.
-
-