Package writer2latex.api
Interface Config
- All Known Implementing Classes:
ConfigBase
,LaTeXConfig
,XhtmlConfig
public interface Config
-
Method Summary
Modifier and TypeMethodDescriptiongetComplexOption
(String sName) Get a complex optionGet a named optionvoid
Read a configuration (file based version)void
read
(InputStream is) Read a configuration (stream based version)void
readDefaultConfig
(String sName) Read a default configuration: The available configurations depend on theConverter
implementationvoid
Set a name/value option.void
Write the configuration (file based version)void
write
(OutputStream os) Write the configuration (stream based version)
-
Method Details
-
readDefaultConfig
Read a default configuration: The available configurations depend on theConverter
implementation- Parameters:
sName
- the name of the configuration- Throws:
IllegalArgumentException
- if the configuration does not exist
-
read
Read a configuration (stream based version)- Parameters:
is
- theInputStream
to read from- Throws:
IOException
- if an error occurs reading the stream, or the data is not in the right format
-
read
Read a configuration (file based version)- Parameters:
file
- theFile
to read from- Throws:
IOException
- if the file does not exist, an error occurs reading the file, or the data is not in the right format
-
write
Write the configuration (stream based version)- Parameters:
os
- theOutputStream
to write to- Throws:
IOException
- if an error occurs writing to the stream
-
write
Write the configuration (file based version)- Parameters:
file
- theFile
to write to- Throws:
IOException
- if an error occurs writing to the file
-
setOption
Set a name/value option. Options that are not defined by theConverter
implementation as well as null values are silently ignored- Parameters:
sName
- the name of the optionsValue
- the value of the option
-
getOption
Get a named option- Parameters:
sName
- the name of the option- Returns:
- the value of the option, or
null
if the option does not exist or the given name is null
-
getComplexOption
Get a complex option- Parameters:
sName
- the name of the complex option- Returns:
- the option
-