org.apache.commons.configuration.plist
Class PropertyListConfiguration
java.lang.Object
org.apache.commons.configuration.event.EventSource
org.apache.commons.configuration.AbstractConfiguration
org.apache.commons.configuration.HierarchicalConfiguration
org.apache.commons.configuration.AbstractHierarchicalFileConfiguration
org.apache.commons.configuration.plist.PropertyListConfiguration
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Cloneable, Configuration, ConfigurationListener, FileConfiguration
public class PropertyListConfiguration
- extends AbstractHierarchicalFileConfiguration
NeXT / OpenStep style configuration.
(http://developer.apple.com/documentation/Cocoa/Conceptual/PropertyLists/Concepts/OldStylePListsConcept.html)
Example:
{
foo = "bar";
array = ( value1, value2, value3 );
data = <4f3e0145ab>;
nested =
{
key1 = value1;
key2 = value;
nested =
{
foo = bar
}
}
}
- Since:
- 1.2
- Version:
- $Revision: 492216 $, $Date: 2007-01-03 17:51:24 +0100 (Mi, 03 Jan 2007) $
- Author:
- Emmanuel Bourg
- See Also:
- Serialized Form
Method Summary |
void |
load(java.io.Reader in)
Load the configuration from the specified reader. |
void |
save(java.io.Writer out)
Save the configuration to the specified writer. |
Methods inherited from class org.apache.commons.configuration.AbstractHierarchicalFileConfiguration |
addPropertyDirect, clearProperty, clearTree, configurationChanged, containsKey, createDelegate, fetchNodeList, getBasePath, getDelegate, getEncoding, getFile, getFileName, getKeys, getProperty, getReloadingStrategy, getURL, isAutoSave, isEmpty, load, load, load, load, load, load, reload, save, save, save, save, save, save, setAutoSave, setBasePath, setDelegate, setEncoding, setFile, setFileName, setProperty, setReloadingStrategy, setURL |
Methods inherited from class org.apache.commons.configuration.HierarchicalConfiguration |
addNodes, clearNode, clearNode, clearReferences, clone, configurationAt, configurationsAt, createAddPath, createNode, createSubnodeConfiguration, fetchAddNode, findLastPathNode, findPropertyNodes, getDefaultExpressionEngine, getExpressionEngine, getKeys, getMaxIndex, getRoot, getRootNode, nodeDefined, nodeDefined, removeNode, removeNode, setDefaultExpressionEngine, setExpressionEngine, setRoot, setRootNode, subset |
Methods inherited from class org.apache.commons.configuration.AbstractConfiguration |
addErrorLogListener, addProperty, clear, clearPropertyDirect, createInterpolator, getBigDecimal, getBigDecimal, getBigInteger, getBigInteger, getBoolean, getBoolean, getBoolean, getByte, getByte, getByte, getDefaultListDelimiter, getDelimiter, getDouble, getDouble, getDouble, getFloat, getFloat, getFloat, getInt, getInt, getInteger, getInterpolator, getList, getList, getListDelimiter, getLogger, getLong, getLong, getLong, getProperties, getProperties, getShort, getShort, getShort, getString, getString, getStringArray, getSubstitutor, interpolate, interpolate, interpolateHelper, isDelimiterParsingDisabled, isThrowExceptionOnMissing, resolveContainerStore, setDefaultListDelimiter, setDelimiter, setDelimiterParsingDisabled, setListDelimiter, setLogger, setThrowExceptionOnMissing |
Methods inherited from class org.apache.commons.configuration.event.EventSource |
addConfigurationListener, addErrorListener, clearConfigurationListeners, clearErrorListeners, createErrorEvent, createEvent, fireError, fireEvent, getConfigurationListeners, getErrorListeners, isDetailEvents, removeConfigurationListener, removeErrorListener, setDetailEvents |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.commons.configuration.Configuration |
addProperty, clear, getBigDecimal, getBigDecimal, getBigInteger, getBigInteger, getBoolean, getBoolean, getBoolean, getByte, getByte, getByte, getDouble, getDouble, getDouble, getFloat, getFloat, getFloat, getInt, getInt, getInteger, getKeys, getList, getList, getLong, getLong, getLong, getProperties, getShort, getShort, getShort, getString, getString, getStringArray, subset |
PropertyListConfiguration
public PropertyListConfiguration()
- Creates an empty PropertyListConfiguration object which can be
used to synthesize a new plist file by adding values and
then saving().
PropertyListConfiguration
public PropertyListConfiguration(HierarchicalConfiguration c)
- Creates a new instance of
PropertyListConfiguration
and
copies the content of the specified configuration into this object.
- Parameters:
c
- the configuration to copy- Since:
- 1.4
PropertyListConfiguration
public PropertyListConfiguration(java.lang.String fileName)
throws ConfigurationException
- Creates and loads the property list from the specified file.
- Parameters:
fileName
- The name of the plist file to load.
- Throws:
ConfigurationException
- Error while loading the plist file
PropertyListConfiguration
public PropertyListConfiguration(java.io.File file)
throws ConfigurationException
- Creates and loads the property list from the specified file.
- Parameters:
file
- The plist file to load.
- Throws:
ConfigurationException
- Error while loading the plist file
PropertyListConfiguration
public PropertyListConfiguration(java.net.URL url)
throws ConfigurationException
- Creates and loads the property list from the specified URL.
- Parameters:
url
- The location of the plist file to load.
- Throws:
ConfigurationException
- Error while loading the plist file
load
public void load(java.io.Reader in)
throws ConfigurationException
- Description copied from interface:
FileConfiguration
- Load the configuration from the specified reader.
- Parameters:
in
- the reader
- Throws:
ConfigurationException
- if an error occurs during the load operation
save
public void save(java.io.Writer out)
throws ConfigurationException
- Description copied from interface:
FileConfiguration
- Save the configuration to the specified writer.
- Parameters:
out
- the writer
- Throws:
ConfigurationException
- if an error occurs during the save operation
Copyright © 2001-2008 Apache Software Foundation. All Rights Reserved.