org.bounce.text.xml
Class XMLInputReader
java.lang.Object
java.io.Reader
java.io.FilterReader
org.bounce.text.xml.XMLInputReader
- All Implemented Interfaces:
- Closeable, Readable
public class XMLInputReader
- extends FilterReader
A Reader for XML input, which can handle escape characters.
Note: The XML Editor package is based on the JavaEditorKit example as
described in the article 'Customizing a Text Editor' by Timothy
Prinzing . See:
http://java.sun.com/products/jfc/tsc/articles/text/editor_kit/
|
Constructor Summary |
XMLInputReader(org.bounce.text.xml.XMLInputStream inputstream)
Constructs the new input stream reader out of the Xml input strem. |
|
Method Summary |
int |
getLastChar()
Returns the last read character. |
int |
read()
Reads one character from the stream and increases the index. |
void |
setRange(int start,
int end)
Sets the scan range of the reader. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XMLInputReader
public XMLInputReader(org.bounce.text.xml.XMLInputStream inputstream)
- Constructs the new input stream reader out of the Xml input strem.
- Parameters:
inputstream - the XML input stream.
- Throws:
UnsupportedEncodingException
setRange
public void setRange(int start,
int end)
- Sets the scan range of the reader.
- Parameters:
start - the start position.end - the end position.
read
public int read()
throws IOException
- Reads one character from the stream and increases the index.
- Overrides:
read in class FilterReader
- Returns:
- the character or -1 for an eof.
- Throws:
IOException
getLastChar
public int getLastChar()
- Returns the last read character.
- Returns:
- the last read character or -1 for an eof.
Copyright © 2002 - 2007 Edwin Dankert. All Rights Reserved.