public class CompositePropertyIOFactory extends Object
CompositePropertyIO. | Constructor and Description |
|---|
CompositePropertyIOFactory() |
| Modifier and Type | Method and Description |
|---|---|
static CompositePropertyIO |
create(File[] files,
boolean readonly,
boolean cached,
boolean mustExists)
Constructs a CompositePropertyIO from a series of filenames.
|
static CompositePropertyIO |
create(File rootDirectory,
boolean readonly,
boolean cached)
Searches for all the properties files in directory or sub directory of rootDirectory, and returns a CompositePropertyIO with a list of FilePropertyIO.
|
static CompositePropertyIO |
create(File rootDirectory,
String[] propertyFilenames,
boolean readonly,
boolean cached)
Searches for the propertyFilenames in directory or sub directory of rootDirectory, and returns a CompositePropertyIO with a list of FilePropertyIO.
|
static CompositePropertyIO |
create(String[] fileNames,
boolean readonly,
boolean cached,
boolean mustExists)
Constructs a CompositePropertyIO from a series of filenames.
|
static org.apache.commons.logging.Log |
getLogger() |
public static CompositePropertyIO create(String[] fileNames, boolean readonly, boolean cached, boolean mustExists) throws PropertyIOException
FilePropertyIO.
This can fx. be used with String[] args from the java main method.fileNames - an array of filenames.readonly - is the CompositePropertyIO be read only.cached - is the values be cached in the PropertyIO's.mustExists - if true than all the files must exists File.exists otherwise a PropertyException.FilePropertyIO's.PropertyIOException - if any of the files do not exists and mustExists is truepublic static CompositePropertyIO create(File[] files, boolean readonly, boolean cached, boolean mustExists) throws PropertyIOException
FilePropertyIO.files - an array of File's.readonly - shall the CompositePropertyIO be read only.cached - shall the values be cached in the FilePropertyIO's.mustExists - if true than all the files must exists File.exists otherwise a PropertyException.FilePropertyIO's.PropertyIOException - if any of the files do not exists and mustExists is truepublic static CompositePropertyIO create(File rootDirectory, String[] propertyFilenames, boolean readonly, boolean cached) throws PropertyIOException
rootDirectory - the directory to start the search.propertyFilenames - the property filenames to search for.readonly - if the FilePropertyIO be read only.cached - shall the values be cached in the PropertyIO's.CompositePropertyIO with a list of FilePropertyIO loading properties from files found by their name.PropertyIOException - if one of the property filenames is not found in root directory or one of its sub directories.public static CompositePropertyIO create(File rootDirectory, boolean readonly, boolean cached) throws PropertyIOException
rootDirectory - the directory to start the search.readonly - if the FilePropertyIO be read only.cached - shall the values be cached in the PropertyIO's.CompositePropertyIO with a list of FilePropertyIO loading properties from files found by their name.PropertyIOException - construction of CompositePropertyIO.public static final org.apache.commons.logging.Log getLogger()