public interface Configurations
Modifier and Type | Method and Description |
---|---|
void |
addConfiguration(DynConfiguration dynConf)
Add a dynamic configuration on the configuration file.
|
void |
addProperties(String name,
String value,
String compId,
String compName)
Add a component property name and value on stored and base
configurations.
|
void |
deleteConfiguration(Element conf)
Delete a configuration element from the configuration file.
|
Element |
findConfiguration(String name)
Find the first configuration element with given name.
|
DynConfiguration |
getActiveConfiguration()
Get current dynamic configuration from configuration file.
|
List<Element> |
getAllConfigurations()
Get all configuration elements.
|
Element |
getBaseConfiguration()
Get the base configuration from configuration.
|
Node |
getKeyElement(Element prop)
Get the key element of a property element.
|
Element |
getProperty(String configuration,
String property)
Get a property element from a configuration with some name.
|
Node |
getValueElement(Element prop)
Get the value element of a property element.
|
DynComponent |
parseComponent(Element comp,
String name)
Parse a component element to a dynamic component.
|
DynConfiguration |
parseConfiguration(Element conf,
String property)
Parse a configuration element to a dynamic configuration.
|
DynProperty |
parseProperty(Element prop)
Parse a property element to a dynamic property.
|
void |
saveConfiguration(Element elem)
Save the document of an element on the configuration file.
|
void |
setActiveConfiguration(String name)
Set the active configuration on the configuration file.
|
DynProperty |
updateProperty(String configuration,
String property,
String value)
Set a value on a configuration property.
|
void addConfiguration(DynConfiguration dynConf)
configs
- Dynamic configuration to store at configuration filevoid deleteConfiguration(Element conf)
conf
- Configuration element to deleteDynConfiguration parseConfiguration(Element conf, String property)
All configuration component properties will be processed if name is null. If name not null, only specified property name will be processed.
conf
- Configuration elementproperty
- Property name to parse or all if nullDynComponent parseComponent(Element comp, String name)
All component properties will be processed if name is null. If name not null, only specified property name will be processed.
comp
- Component elementname
- Property name to parse or all if nullDynProperty parseProperty(Element prop)
prop
- Property elementvoid saveConfiguration(Element elem)
conf
- Element of the document to saveElement findConfiguration(String name)
name
- Configuration element nameElement getBaseConfiguration()
List<Element> getAllConfigurations()
Element getProperty(String configuration, String property)
configuration
- Configuration nameproperty
- Property nameDynConfiguration getActiveConfiguration()
If no dynamic configuration active, null will be returned.
void setActiveConfiguration(String name)
name
- Configuration namevoid addProperties(String name, String value, String compId, String compName)
name
- Property namevalue
- Property valuecompId
- Component idcompName
- Component nameNode getKeyElement(Element prop)
prop
- Property elementNode getValueElement(Element prop)
prop
- Property elementDynProperty updateProperty(String configuration, String property, String value)
If null value, value element no written.
configuration
- Configuration name to updateproperty
- Property name to updatevalue
- Value to setCopyright © 2010–2015 General Directorate for Information Technologies (DGTI) of the Regional Ministry of Finance and Public Administration of the Generalitat Valenciana.. All rights reserved.