public class InputSource
Input source for one XML entity.
An InputSource can carry a public identifier, a system identifier, a byte stream, a character stream and an optional encoding. SAX parsers prefer the character stream, then the byte stream, then the system identifier.
import org.xml.sax
input = InputSource("file:/tmp/doc.xml")
input.setEncoding("UTF-8")| Modifier and Type | Member | Description |
|---|---|---|
| public | InputSource | Creates an empty input source. |
| public | InputSourceInputSource(byteStream as InputStream) |
Creates an input source from a byte stream. |
| public | InputSourceInputSource(characterStream as TextReader) |
Creates an input source from a character stream. |
| public | InputSourceInputSource(systemId as String) |
Creates an input source from a system identifier. |
| Modifier and Type | Member | Description |
|---|---|---|
| public | getByteStreamgetByteStream() as InputStream |
Returns the byte stream. |
| public | getCharacterStreamgetCharacterStream() as TextReader |
Returns the character stream. |
| public | getEncodinggetEncoding() as String |
Returns the byte-stream or URI encoding. |
| public | getPublicIdgetPublicId() as String |
Returns the public identifier. |
| public | getSystemIdgetSystemId() as String |
Returns the system identifier. |
| public | isEmptyisEmpty() as Boolean |
Indicates whether no input information is present. |
| public | setByteStreamsetByteStream(byteStream as InputStream) as Void |
Sets the byte stream. |
| public | setCharacterStreamsetCharacterStream(characterStream as TextReader) as Void |
Sets the character stream. |
| public | setEncodingsetEncoding(encoding as String) as Void |
Sets the byte-stream or URI encoding. |
| public | setPublicIdsetPublicId(publicId as String) as Void |
Sets the public identifier. |
| public | setSystemIdsetSystemId(systemId as String) as Void |
Sets the system identifier. |