public class PropertyManager extends Object implements IPropertyManager
| Modifier and Type | Field and Description |
|---|---|
static String |
STORAGE_KEY
The name for the Persistent storage utility name
|
| Constructor and Description |
|---|
PropertyManager()
Constructor for this PropertyManager
|
| Modifier and Type | Method and Description |
|---|---|
static IPropertyManager |
__() |
void |
addRules(IPropertyRules rules)
Adds a set of rules to be used by this PropertyManager.
|
boolean |
checkPropertyAllowed(String propertyName)
Checks that a property is permitted to exist by any of the existing rules sets
|
boolean |
checkValueAllowed(String propertyName,
String propertyValue)
Checks that a property is allowed to store a certain value.
|
List<String> |
getProperty(String propertyName)
Retrieves the property specified, as long as it exists in one of the current rulesets
|
List<IPropertyRules> |
getRules()
Retrieves the set of rules being used by this property manager if any exist.
|
String |
getSingularProperty(String propertyName)
Retrieves the singular property specified, as long as it exists in one of the current rulesets
|
List<String> |
getValue(String name) |
static void |
initDefaultPropertyManager() |
void |
setProperty(String propertyName,
List<String> propertyValue)
Sets the given property to the given vector value, if both are allowed by any existing ruleset
|
void |
setProperty(String propertyName,
String propertyValue)
Sets the given property to the given string value, if both are allowed by any existing ruleset
|
static void |
setPropertyManager(IPropertyManager pm) |
void |
setRules(IPropertyRules rules)
Sets the rules that should be used by this PropertyManager, removing any other
existing rules sets.
|
void |
writeValue(String propertyName,
List<String> value) |
public static final String STORAGE_KEY
public static void setPropertyManager(IPropertyManager pm)
public static void initDefaultPropertyManager()
public static IPropertyManager __()
public String getSingularProperty(String propertyName)
getSingularProperty in interface IPropertyManagerpropertyName - the name of the property being retrievedpublic List<String> getProperty(String propertyName)
getProperty in interface IPropertyManagerpropertyName - the name of the property being retrievedpublic void setProperty(String propertyName, String propertyValue)
setProperty in interface IPropertyManagerpropertyName - The property to be setpropertyValue - The value that the property will be set topublic void setProperty(String propertyName, List<String> propertyValue)
setProperty in interface IPropertyManagerpropertyName - The property to be setpropertyValue - The value that the property will be set topublic List<IPropertyRules> getRules()
getRules in interface IPropertyManagerpublic void setRules(IPropertyRules rules)
rules - The rules to be used.public void addRules(IPropertyRules rules)
addRules in interface IPropertyManagerrules - The set of rules to be added to the permitted listpublic boolean checkPropertyAllowed(String propertyName)
propertyName - The name of the property to be setpublic boolean checkValueAllowed(String propertyName, String propertyValue)
propertyName - The name of the property to be setpropertyValue - The value to be stored in the given propertyCopyright © 2023. All rights reserved.