All Packages Class Hierarchy This Package Previous Next Index
Class org.xml.sax.HandlerBase
java.lang.Object
|
+----org.xml.sax.HandlerBase
- public class HandlerBase
- extends Object
- implements EntityHandler, DocumentHandler, ErrorHandler
A simple base class for deriving SAX event handlers.
This class is part of the Java implementation of SAX,
the Simple API for XML. It is free for both commercial and
non-commercial use, and is distributed with no warrantee, real
or implied.
This class implements the default behaviour when no handler
is specified (though parsers are not actually required to use
this class).
- Author:
- David Megginson, Microstar Software Ltd.
- See Also:
- XmlException, EntityHandler, DocumentHandler, ErrorHandler
-
HandlerBase()
-
-
changeEntity(String)
- Handle an entity-change event.
-
characters(char[], int, int)
- Handle a character data event.
-
doctype(String, String, String)
- Handle a document type declaration event.
-
endDocument()
- Handle a end document event.
-
endElement(String)
- Handle an end element event.
-
fatal(String, String, int, int)
- Handle a fatal error.
-
ignorable(char[], int, int)
- Handle an ignorable whitespace event.
-
processingInstruction(String, String)
- Handle a processing instruction event.
-
resolveEntity(String, String, String)
- Resolve an external entity.
-
startDocument()
- Handle a start document event.
-
startElement(String, AttributeMap)
- Handle a start element event.
-
warning(String, String, int, int)
- Handle a non-fatal error.
HandlerBase
public HandlerBase()
resolveEntity
public String resolveEntity(String ename,
String publicID,
String systemID) throws Exception
- Resolve an external entity.
By default, simply return the system ID supplied.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- resolveEntity
changeEntity
public void changeEntity(String systemID) throws Exception
- Handle an entity-change event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- changeEntity
startDocument
public void startDocument() throws Exception
- Handle a start document event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- startDocument
endDocument
public void endDocument() throws Exception
- Handle a end document event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- endDocument
doctype
public void doctype(String name,
String publicID,
String systemID) throws Exception
- Handle a document type declaration event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- doctype
startElement
public void startElement(String name,
AttributeMap attributes) throws Exception
- Handle a start element event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- startElement
endElement
public void endElement(String name) throws Exception
- Handle an end element event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- endElement
characters
public void characters(char ch[],
int start,
int length) throws Exception
- Handle a character data event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- characters
ignorable
public void ignorable(char ch[],
int start,
int length) throws Exception
- Handle an ignorable whitespace event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- ignorable
processingInstruction
public void processingInstruction(String name,
String remainder) throws Exception
- Handle a processing instruction event.
By default, do nothing.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- processingInstruction
warning
public void warning(String message,
String systemID,
int line,
int column) throws Exception
- Handle a non-fatal error.
By default, report the warning to System.err.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- warning
fatal
public void fatal(String message,
String systemID,
int line,
int column) throws XmlException, Exception
- Handle a fatal error.
By default, throw an instance of XmlException.
- Throws: XmlException
- A fatal parsing error
has been found.
- Throws: Exception
- When you override this method,
you may throw any exception.
- See Also:
- fatal
All Packages Class Hierarchy This Package Previous Next Index