org.arch4j.property
Class XMLPropertyWriter
java.lang.Object
|
+--org.arch4j.property.XMLPropertyWriter
- All Implemented Interfaces:
- PropertyConstants
- public class XMLPropertyWriter
- extends Object
- implements PropertyConstants
This class is used to modify (add to, update, or delete from) an XML property file.
It will also re-write the property file to disk whenever a change is made.
- Version:
- $Revision: 1.7 $
- Author:
- Ross E. Greinke
Fields inherited from interface org.arch4j.property.PropertyConstants |
ADD_STRING, BOOLEAN_CHAR, BOOLEAN_NAME, CHAR_CHAR, CHAR_NAME, DEFAULT_DOMAIN_NAME, DOMAIN_CHAR, DOMAIN_TAG_NAME, DOUBLE_CHAR, DOUBLE_NAME, EMPTY_STRING, FALSE_STRING, FLOAT_CHAR, FLOAT_NAME, INT_CHAR, INT_NAME, KEY_CHAR, KEY_TAG_NAME, LONG_CHAR, LONG_NAME, NAME_CHAR, NAME_TAG_NAME, PROPERTY_CHAR, PROPERTY_TAG_NAME, STRING_CHAR, STRING_NAME, TOP_LEVEL_CHAR, TOP_LEVEL_TAG_NAME, TRUE_STRING, TYPE_CHAR, TYPE_TAG_NAME, VALUE_CHAR, VALUE_TAG_NAME, XML_DECLARATION |
Constructor Summary |
XMLPropertyWriter(Map properties,
File propertyFile)
Constructs a XMLPropertyWriter , which will be used to modify
and store XML properties. |
Method Summary |
void |
add(String domainName,
Property property)
Add the given Property object to the property map identified by the given domain name. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XMLPropertyWriter
public XMLPropertyWriter(Map properties,
File propertyFile)
- Constructs a
XMLPropertyWriter
, which will be used to modify
and store XML properties.
- Parameters:
properties
- The property map to fill in.propertyFile
- The XML property file to parse.
add
public void add(String domainName,
Property property)
- Add the given Property object to the property map identified by the given domain name.
If the add was successful, the property file is re-written with the new data.
- Parameters:
domainName
- The domain name key to use to find the correct property map.property
- The property to add.
Copyright © 2000-2004 SpiderLogic, a service of Wipfli Ullrich Bertelson LLP.