public class XMLScanner extends SyntaxHighlightingScanner
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 and Description |
---|
XMLScanner(javax.swing.text.Document document)
Constructs a scanner for the Document.
|
Modifier and Type | Method and Description |
---|---|
int |
getEventType() |
int |
getNextTag() |
long |
scan()
Scans the Xml Stream for XML specific tokens.
|
void |
setRange(int start,
int end)
Sets the scanning range.
|
getEndOffset, getStartOffset, isError, isValid, setValid
public XMLScanner(javax.swing.text.Document document) throws java.io.IOException
document
- the document containing the XML content.java.io.IOException
public int getEventType()
public int getNextTag() throws java.io.IOException
java.io.IOException
public void setRange(int start, int end) throws java.io.IOException
setRange
in class SyntaxHighlightingScanner
start
- the start of the range.end
- the end of the range.java.io.IOException
public long scan() throws java.io.IOException
scan
in class SyntaxHighlightingScanner
java.io.IOException