|
||||||||||
PREV CLASS (src) NEXT CLASS (src) | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.util.property.FilePropertyReader
Reads properties from one or more files.
Field Summary | |
protected java.lang.String[] |
filenames
Array of filenames to load properties from |
Constructor Summary | |
FilePropertyReader(java.lang.String filename)
Construct a FilePropertyReader with a single filename to read from. |
|
FilePropertyReader(java.lang.String[] filenames)
Construct a FilePropertyReader with an array of filenames to read from. |
Method Summary | |
protected java.io.InputStream |
getInputStream(java.lang.String filename)
Get an input stream for the given filename. |
protected void |
loadProperties(java.util.Properties props,
java.lang.String filename)
Load properties from a file into a properties map. |
java.util.Map |
readProperties()
Read properties from each specified filename |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected java.lang.String[] filenames
Constructor Detail |
public FilePropertyReader(java.lang.String[] filenames)
filenames
- Filenames to load properties frompublic FilePropertyReader(java.lang.String filename)
filename
- Filename to load properties fromMethod Detail |
protected java.io.InputStream getInputStream(java.lang.String filename) throws java.io.IOException
filename
- File name to get input stream for.
java.io.IOException
- Failed to get input stream for file.protected void loadProperties(java.util.Properties props, java.lang.String filename) throws java.io.IOException
props
- Properties map to load properties into.filename
- Filename to read properties from.
java.io.IOException
- Failed to load properties from filename.
java.lang.IllegalArgumentException
- Filename is invalid.public java.util.Map readProperties() throws PropertyException (src) , java.io.IOException
readProperties
in interface PropertyReader (src)
PropertyException (src)
- Failed to read properties.
java.io.IOException
- I/O error while reading properties.
|
||||||||||
PREV CLASS (src) NEXT CLASS (src) | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |