Package org.apache.batik.transcoder
Class TranscoderInput
- java.lang.Object
-
- org.apache.batik.transcoder.TranscoderInput
-
public class TranscoderInput extends java.lang.ObjectThis class represents a generic input of aTranscoder.- Version:
- $Id: TranscoderInput.java 1733416 2016-03-03 07:07:13Z gadams $
-
-
Field Summary
Fields Modifier and Type Field Description protected org.w3c.dom.DocumentdocumentThe optional input as XML Document.protected java.io.InputStreamistreamThe optional input has a byte stream.protected java.io.ReaderreaderThe optional input as a character stream.protected java.lang.StringuriThe optional input as a URI.protected org.xml.sax.XMLReaderxmlReaderThe optional XML reader to receive SAX events.
-
Constructor Summary
Constructors Constructor Description TranscoderInput()Constructs a new emptyTranscoderInput.TranscoderInput(java.io.InputStream istream)Constructs a newTranscoderInputwith the specified byte stream input.TranscoderInput(java.io.Reader reader)Constructs a newTranscoderInputwith the specified character stream.TranscoderInput(java.lang.String uri)Constructs a newTranscoderInputwith the specified uri.TranscoderInput(org.w3c.dom.Document document)Constructs a newTranscoderInputwith the specified Document.TranscoderInput(org.xml.sax.XMLReader xmlReader)Constructs a newTranscoderInputwith the specified XML reader.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.w3c.dom.DocumentgetDocument()Returns the input of this transcoder as a document or null if none was supplied.java.io.InputStreamgetInputStream()Returns the input of this transcoder as a byte stream or null if none was supplied.java.io.ReadergetReader()Returns the input of this transcoder as a character stream or null if none was supplied.java.lang.StringgetURI()Returns the input of this transcoder as a URI or null if none was supplied.org.xml.sax.XMLReadergetXMLReader()Returns the XML reader of this transcoder or null if none was supplied.voidsetDocument(org.w3c.dom.Document document)Sets the input of this transcoder input with the specified document.voidsetInputStream(java.io.InputStream istream)Sets the input of this transcoder input with the specified byte stream.voidsetReader(java.io.Reader reader)Sets the input of this transcoder input with the specified character stream.voidsetURI(java.lang.String uri)Sets the input of this transcoder input with the specified URI.voidsetXMLReader(org.xml.sax.XMLReader xmlReader)Sets the input of this transcoder input with the specified XML reader.
-
-
-
Field Detail
-
xmlReader
protected org.xml.sax.XMLReader xmlReader
The optional XML reader to receive SAX events.
-
istream
protected java.io.InputStream istream
The optional input has a byte stream.
-
reader
protected java.io.Reader reader
The optional input as a character stream.
-
document
protected org.w3c.dom.Document document
The optional input as XML Document.
-
uri
protected java.lang.String uri
The optional input as a URI.
-
-
Constructor Detail
-
TranscoderInput
public TranscoderInput()
Constructs a new emptyTranscoderInput.
-
TranscoderInput
public TranscoderInput(org.xml.sax.XMLReader xmlReader)
Constructs a newTranscoderInputwith the specified XML reader.- Parameters:
xmlReader- the XML reader of this transcoder input
-
TranscoderInput
public TranscoderInput(java.io.InputStream istream)
Constructs a newTranscoderInputwith the specified byte stream input.- Parameters:
istream- the byte stream of this transcoder input
-
TranscoderInput
public TranscoderInput(java.io.Reader reader)
Constructs a newTranscoderInputwith the specified character stream.- Parameters:
reader- the character stream of this transcoder input
-
TranscoderInput
public TranscoderInput(org.w3c.dom.Document document)
Constructs a newTranscoderInputwith the specified Document.- Parameters:
document- the Document of this transcoder input
-
TranscoderInput
public TranscoderInput(java.lang.String uri)
Constructs a newTranscoderInputwith the specified uri.- Parameters:
uri- the URI of this transcoder input
-
-
Method Detail
-
setXMLReader
public void setXMLReader(org.xml.sax.XMLReader xmlReader)
Sets the input of this transcoder input with the specified XML reader.- Parameters:
xmlReader- the XML reader of this transcoder input
-
getXMLReader
public org.xml.sax.XMLReader getXMLReader()
Returns the XML reader of this transcoder or null if none was supplied.
-
setInputStream
public void setInputStream(java.io.InputStream istream)
Sets the input of this transcoder input with the specified byte stream.- Parameters:
istream- the byte stream of this transcoder input
-
getInputStream
public java.io.InputStream getInputStream()
Returns the input of this transcoder as a byte stream or null if none was supplied.
-
setReader
public void setReader(java.io.Reader reader)
Sets the input of this transcoder input with the specified character stream.- Parameters:
reader- the character stream of this transcoder input
-
getReader
public java.io.Reader getReader()
Returns the input of this transcoder as a character stream or null if none was supplied.
-
setDocument
public void setDocument(org.w3c.dom.Document document)
Sets the input of this transcoder input with the specified document.- Parameters:
document- the document of this transcoder input
-
getDocument
public org.w3c.dom.Document getDocument()
Returns the input of this transcoder as a document or null if none was supplied.
-
setURI
public void setURI(java.lang.String uri)
Sets the input of this transcoder input with the specified URI.- Parameters:
uri- the URI of this transcoder input
-
getURI
public java.lang.String getURI()
Returns the input of this transcoder as a URI or null if none was supplied.
-
-