|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
A persistent configuration loaded and saved to a file.
| Method Summary | |
String |
getBasePath()
Return the base path. |
File |
getFile()
Return the file where the configuration is stored. |
String |
getFileName()
Return the name of the file. |
URL |
getURL()
Return the URL where the configuration is stored. |
void |
load()
Load the configuration from the underlying URL. |
void |
load(File file)
Load the configuration from the specified file. |
void |
load(InputStream in)
Load the configuration from the specified stream, using the default platform specific encoding. |
void |
load(InputStream in,
String encoding)
Load the configuration from the specified stream, using the specified encoding. |
void |
load(Reader in)
Load the configuration from the specified reader. |
void |
load(String fileName)
Locate the specified file and load the configuration. |
void |
load(URL url)
Load the configuration from the specified URL. |
void |
save()
Save the configuration. |
void |
save(File file)
Save the configuration to the specified file. |
void |
save(OutputStream out)
Save the configuration to the specified stream. |
void |
save(OutputStream out,
String encoding)
Save the configuration to the specified stream, using the specified encoding. |
void |
save(String fileName)
Save the configuration to the specified file. |
void |
save(URL url)
Save the configuration to the specified URL if it's a file URL. |
void |
save(Writer out)
Save the configuration to the specified writer. |
void |
setBasePath(String basePath)
Set the base path. |
void |
setFile(File file)
Set the file where the configuration is stored. |
void |
setFileName(String fileName)
Set the name of the file. |
void |
setURL(URL url)
The URL where the configuration is stored. |
| Methods inherited from interface org.apache.commons.configuration.Configuration |
addProperty, clearProperty, containsKey, getBigDecimal, getBigDecimal, getBigInteger, getBigInteger, getBoolean, getBoolean, getBoolean, getByte, getByte, getByte, getDouble, getDouble, getDouble, getFloat, getFloat, getFloat, getInt, getInt, getInteger, getKeys, getKeys, getList, getList, getLong, getLong, getLong, getProperties, getProperty, getShort, getShort, getShort, getString, getString, getStringArray, getVector, getVector, isEmpty, setProperty, subset |
| Method Detail |
public void load()
throws ConfigurationException
ConfigurationException
public void load(String fileName)
throws ConfigurationException
fileName - the name of the file loaded
ConfigurationException
public void load(File file)
throws ConfigurationException
file - the loaded file
ConfigurationException
public void load(URL url)
throws ConfigurationException
url - the URL of the file loaded
ConfigurationException
public void load(InputStream in)
throws ConfigurationException
in - the input stream
ConfigurationException
public void load(InputStream in,
String encoding)
throws ConfigurationException
in - the input streamencoding - the encoding used. null to use the default encoding
ConfigurationException
public void load(Reader in)
throws ConfigurationException
in - the reader
ConfigurationException
public void save()
throws ConfigurationException
ConfigurationException
public void save(String fileName)
throws ConfigurationException
fileName -
ConfigurationException
public void save(File file)
throws ConfigurationException
file -
ConfigurationException
public void save(URL url)
throws ConfigurationException
url -
ConfigurationException
public void save(OutputStream out)
throws ConfigurationException
out -
ConfigurationException
public void save(OutputStream out,
String encoding)
throws ConfigurationException
out - encoding -
ConfigurationException
public void save(Writer out)
throws ConfigurationException
out - the writer
ConfigurationExceptionpublic String getFileName()
public void setFileName(String fileName)
fileName - the name of the filepublic String getBasePath()
public void setBasePath(String basePath)
basePath - the base path.public File getFile()
public void setFile(File file)
file - public URL getURL()
public void setURL(URL url)
url -
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||