public interface FileBased
Definition of an interface to be implemented by objects which know how to read and write themselves from or to a character stream.
This interface is implemented by special implementations of the
Configuration
interface which are associated with a file. It demands
only basic methods for doing I/O based on character stream objects. Based on
these methods it is possible to implement other methods which operate on
files, file names, URLs, etc.
Modifier and Type | Method and Description |
---|---|
void |
read(Reader in)
Reads the content of this object from the given reader.
|
void |
write(Writer out)
Writes the content of this object to the given writer.
|
void read(Reader in) throws ConfigurationException, IOException
in
- the readerIOException
- if an I/O error occursConfigurationException
- if a non-I/O related problem occurs, e.g.
the data read does not have the expected formatvoid write(Writer out) throws ConfigurationException, IOException
out
- the writerIOException
- if an I/O error occursConfigurationException
- if a non-I/O related problem occurs, e.g.
the data read does not have the expected formatCopyright © 2001–2019 The Apache Software Foundation. All rights reserved.