Save This Page
Home » Xerces-J-src.2.9.1 » sax » [javadoc | source]
sax
public class: SAX2Count [javadoc | source]
java.lang.Object
   org.xml.sax.helpers.DefaultHandler
      sax.SAX2Count

All Implemented Interfaces:
    ErrorHandler, EntityResolver, ContentHandler, DTDHandler

A sample SAX2 counter. This sample program illustrates how to register a SAX2 ContentHandler and receive the callbacks in order to print information about the document.
Method from sax.SAX2Count Summary:
characters,   error,   fatalError,   ignorableWhitespace,   main,   print,   printResults,   startDocument,   startElement,   warning
Methods from org.xml.sax.helpers.DefaultHandler:
characters,   endDocument,   endElement,   endPrefixMapping,   error,   fatalError,   ignorableWhitespace,   notationDecl,   processingInstruction,   resolveEntity,   setDocumentLocator,   skippedEntity,   startDocument,   startElement,   startPrefixMapping,   unparsedEntityDecl,   warning
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from sax.SAX2Count Detail:
 public  void characters(char[] ch,
    int start,
    int length) 
    Characters.
 public  void error(SAXParseException ex) 
    Error.
 public  void fatalError(SAXParseException ex) throws SAXException 
    Fatal error.
 public  void ignorableWhitespace(char[] ch,
    int start,
    int length) 
    Ignorable whitespace.
 public static  void main(String[] argv) 
    Main program entry point.
 public static  void print(String parserName,
    String uri,
    boolean validate) 
    Prints the output from the SAX callbacks.
 public  void printResults(String uri,
    long time) 
    Prints the results.
 public  void startDocument() 
    Start document.
 public  void startElement(String uri,
    String local,
    String raw,
    Attributes attrs) 
    Start element.
 public  void warning(SAXParseException ex) 
    Warning.