DefaultHandler
class in package klyn.io.xml.sax

    public class DefaultHandler extends Object implements EntityResolver, DTDHandler, ContentHandler, ErrorHandler:

Object
└ DefaultHandler
All Implemented Interfaces: EntityResolver, DTDHandler, ContentHandler, ErrorHandler

No-op SAX handler covering the common SAX callback interfaces.

Applications can extend this class and override only the callbacks they need. The default error callbacks do not throw, matching the standard SAX helper behavior.

Example

    import klyn.io.xml.sax

    handler = DefaultHandler()
    handler.startDocument()

Inherited Properties
property Inherited Properties from Object: type
Constructors

Modifier and Type | Member | Description
--- | --- | ---
public | DefaultHandler `DefaultHandler():` | Creates a no-op handler.

Methods

Modifier and Type | Member | Description
--- | --- | ---
public | characters `characters(ch as Array<Char>, start as Int, length as Int) as Void throws SAXException:` | Receives character data.
public | declaration `declaration(version as String, encoding as String, standalone as String) as Void throws SAXException:` | Receives the XML declaration pseudo-attributes.
public | endDocument `endDocument() as Void throws SAXException:` | Receives the end of a document.
public | endElement `endElement(uri as String, localName as String, qName as String) as Void throws SAXException:` | Receives the end of an element.
public | endPrefixMapping `endPrefixMapping(prefix as String) as Void throws SAXException:` | Receives the end of a Namespace prefix scope.
public | error `error(exception as SAXParseException) as Void throws SAXException:` | Receives a recoverable error.
public | fatalError `fatalError(exception as SAXParseException) as Void throws SAXException:` | Receives a fatal error.
public | ignorableWhitespace `ignorableWhitespace(ch as Array<Char>, start as Int, length as Int) as Void throws SAXException:` | Receives ignorable whitespace.
public | notationDecl `notationDecl(name as String, publicId as String, systemId as String) as Void throws SAXException:` | Receives notation declarations.
public | processingInstruction `processingInstruction(target as String, data as String) as Void throws SAXException:` | Receives a processing instruction.
public | resolveEntity `resolveEntity(publicId as String, systemId as String) as InputSource throws SAXException, IOException:` | Resolves an external entity.
public | setDocumentLocator `setDocumentLocator(locator as Locator) as Void:` | Receives the parser locator.
public | skippedEntity `skippedEntity(name as String) as Void throws SAXException:` | Receives notification of a skipped entity.
public | startDocument `startDocument() as Void throws SAXException:` | Receives the beginning of a document.
public | startElement `startElement(uri as String, localName as String, qName as String, atts as Attributes) as Void throws SAXException:` | Receives the beginning of an element.
public | startPrefixMapping `startPrefixMapping(prefix as String, uri as String) as Void throws SAXException:` | Receives the beginning of a Namespace prefix scope.
public | unparsedEntityDecl `unparsedEntityDecl(name as String, publicId as String, systemId as String, notationName as String) as Void throws SAXException:` | Receives unparsed entity declarations.
public | warning `warning(exception as SAXParseException) as Void throws SAXException:` | Receives a recoverable warning.

Inherited Methods
method Inherited Methods from Object: deepCopy, fromJson, toDict, toJson, toString, toXml
method Inherited Methods from EntityResolver: resolveEntity
method Inherited Methods from DTDHandler: notationDecl, unparsedEntityDecl
method Inherited Methods from ContentHandler: characters, declaration, endDocument, endElement, endPrefixMapping, ignorableWhitespace, processingInstruction, setDocumentLocator, skippedEntity, startDocument, startElement, startPrefixMapping
method Inherited Methods from ErrorHandler: error, fatalError, warning