writer2latex.base
Class ConverterBase
java.lang.Object
writer2latex.base.ConverterBase
- Converter
public abstract class ConverterBase
extends java.lang.Object
Abstract base implementation of writer2latex.api.Converter
sTargetFileName
protected String sTargetFileName
ConverterBase
public ConverterBase()
addDocument
public void addDocument(OutputFile doc)
convert
public ConverterResult convert(File source,
String sTargetFileName)
throws FileNotFoundException,
IOException
Convert a document
- convert in interface Converter
source
- a File
from which to read the source document.sTargetFileName
- the file name to use for the converted document
(if the converted document is a compound document consisting consisting
of several files, this name will be used for the master document)
- a
ConverterResult
containing the converted document
convert
public ConverterResult convert(InputStream is,
String sTargetFileName)
throws IOException
Convert a document
- convert in interface Converter
is
- an InputStream
from which to read the source document.sTargetFileName
- the file name to use for the converted document
(if the converted document is a compound document consisting consisting
of several files, this name will be used for the master document)
- a
ConverterResult
containing the converted document
convertInner
public abstract void convertInner()
throws IOException
getEmbeddedObject
public EmbeddedObject getEmbeddedObject(String sHref)
getMetaData
public MetaData getMetaData()
readTemplate
public void readTemplate(File file)
throws IOException
Read a template to use as a base for the converted document.
The format of the template depends on the Converter
implementation.
- readTemplate in interface Converter
file
- a file from which to read the template
readTemplate
public void readTemplate(InputStream is)
throws IOException
Read a template to use as a base for the converted document.
The format of the template depends on the Converter
implementation.
- readTemplate in interface Converter
is
- an InputStream
from which to read the template
setGraphicConverter
public void setGraphicConverter(GraphicConverter graphicConverter)
Define a GraphicConverter
implementation to use for
conversion of graphic files. If no converter is specified, graphic
files will not be converted into other formats.
- setGraphicConverter in interface Converter