Package nu.validator.saxtree
Class TreeParser
- java.lang.Object
-
- nu.validator.saxtree.TreeParser
-
- All Implemented Interfaces:
org.xml.sax.Locator
public final class TreeParser extends java.lang.Object implements org.xml.sax.LocatorA tree visitor that replays a tree as SAX events.- Version:
- $Id$
- Author:
- hsivonen
-
-
Constructor Summary
Constructors Constructor Description TreeParser(org.xml.sax.ContentHandler contentHandler, org.xml.sax.ext.LexicalHandler lexicalHandler)The constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetColumnNumber()intgetLineNumber()java.lang.StringgetPublicId()java.lang.StringgetSystemId()voidparse(Node node)Causes SAX events for the tree rooted at the argument to be emitted.
-
-
-
Method Detail
-
parse
public void parse(Node node) throws org.xml.sax.SAXException
Causes SAX events for the tree rooted at the argument to be emitted.startDocument()andendDocument()are only emitted for aDocumentnode.- Parameters:
node- the root- Throws:
org.xml.sax.SAXException
-
getColumnNumber
public int getColumnNumber()
- Specified by:
getColumnNumberin interfaceorg.xml.sax.Locator- See Also:
Locator.getColumnNumber()
-
getLineNumber
public int getLineNumber()
- Specified by:
getLineNumberin interfaceorg.xml.sax.Locator- See Also:
Locator.getLineNumber()
-
getPublicId
public java.lang.String getPublicId()
- Specified by:
getPublicIdin interfaceorg.xml.sax.Locator- See Also:
Locator.getPublicId()
-
getSystemId
public java.lang.String getSystemId()
- Specified by:
getSystemIdin interfaceorg.xml.sax.Locator- See Also:
Locator.getSystemId()
-
-