All Packages Class Hierarchy This Package Previous Next Index
Class com.microstar.xml.SAXDriver
java.lang.Object
|
+----com.microstar.xml.SAXDriver
- public class SAXDriver
- extends Object
- implements XmlHandler, Locator, AttributeList, Parser
A SAX driver for Microstar's Ælfred XML parser.
This driver acts as a front-end for Ælfred, and
translates Ælfred's events into SAX events. It
implements the SAX parser interface, and you can use it without
directly calling Ælfred at all:
org.xml.sax.Parser parser = new com.microstar.xml.SAXDriver();
When you are using SAX, you do not need to use the
XmlParser
or XmlHandler
classes at
all: this class is your entry point.
This driver is based on the 1.0gamma version of SAX,
available from http://www.megginson.com/SAX/
- Version:
- 1.1
- Author:
- Copyright (c) 1998 by Microstar Software Ltd., written by David Megginson <dmeggins@microstar.com>
- See Also:
- Parser, XmlParser
-
SAXDriver()
-
-
attribute(String, String, boolean)
- Implement com.microstar.xml.XmlHandler#attribute.
-
charData(char[], int, int)
- Implement com.microstar.xml.XmlHandler#charData.
-
doctypeDecl(String, String, String)
- Implement com.microstar.xml.XmlHandler#doctypeDecl.
-
endDocument()
- Implement com.microstar.xml.XmlHandler#endDocument.
-
endElement(String)
- Implement com.microstar.xml.XmlHandler#endElement.
-
endExternalEntity(String)
- Implement com.microstar.xml.XmlHandler#endExternalEntity.
-
error(String, String, int, int)
- Implement com.microstar.xml.XmlHandler#error.
-
getColumnNumber()
-
-
getLength()
-
-
getLineNumber()
-
-
getName(int)
-
-
getPublicId()
-
-
getSystemId()
-
-
getType(int)
-
-
getType(String)
-
-
getValue(int)
-
-
getValue(String)
-
-
ignorableWhitespace(char[], int, int)
- Implement com.microstar.xml.XmlHandler#ignorableWhitespace.
-
parse(InputSource)
- Parse a document.
-
parse(String)
- Parse an XML document from a system identifier (URI).
-
processingInstruction(String, String)
- Implement com.microstar.xml.XmlHandler#processingInstruction.
-
resolveEntity(String, String)
- Implement com.microstar.xml.XmlHandler.resolveSystemId
Translate to the SAX interface.
-
setDocumentHandler(DocumentHandler)
- Set the document handler for this parser.
-
setDTDHandler(DTDHandler)
- Set the DTD handler for this parser.
-
setEntityResolver(EntityResolver)
- Set the entity resolver for this parser.
-
setErrorHandler(ErrorHandler)
- Set the error handler for this parser.
-
setLocale(Locale)
- Set the locale.
-
startDocument()
- Implement com.microstar.xml.XmlHandler#startDocument.
-
startElement(String)
- Implement com.microstar.xml.XmlHandler#startElement.
-
startExternalEntity(String)
- Implement com.microstar.xml.XmlHandler#startExternalEntity.
SAXDriver
public SAXDriver()
setLocale
public void setLocale(Locale locale) throws SAXException
- Set the locale.
- See Also:
- setLocale
setEntityResolver
public void setEntityResolver(EntityResolver resolver)
- Set the entity resolver for this parser.
- Parameters:
- handler - The object to receive entity events.
- See Also:
- setEntityResolver
setDTDHandler
public void setDTDHandler(DTDHandler handler)
- Set the DTD handler for this parser.
- Parameters:
- handler - The object to receive DTD events.
- See Also:
- setDTDHandler
setDocumentHandler
public void setDocumentHandler(DocumentHandler handler)
- Set the document handler for this parser.
- Parameters:
- handler - The object to receive document events.
- See Also:
- setDocumentHandler
setErrorHandler
public void setErrorHandler(ErrorHandler handler)
- Set the error handler for this parser.
- Parameters:
- handler - The object to receive error events.
- See Also:
- setErrorHandler
parse
public void parse(InputSource source) throws SAXException
- Parse a document.
If you want anything useful to happen, you should set
at least one type of handler.
- Parameters:
- source - The XML input source.
- Throws: SAXException
- The handlers may throw any exception.
- See Also:
- parse, setEntityResolver, setDTDHandler, setDocumentHandler, setErrorHandler
parse
public void parse(String systemId) throws SAXException
- Parse an XML document from a system identifier (URI).
- See Also:
- parse
startDocument
public void startDocument() throws SAXException
- Implement com.microstar.xml.XmlHandler#startDocument.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- startDocument
endDocument
public void endDocument() throws SAXException
- Implement com.microstar.xml.XmlHandler#endDocument.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- endDocument
resolveEntity
public Object resolveEntity(String publicId,
String systemId) throws SAXException
- Implement com.microstar.xml.XmlHandler.resolveSystemId
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- resolveEntity
startExternalEntity
public void startExternalEntity(String systemId) throws SAXException
- Implement com.microstar.xml.XmlHandler#startExternalEntity.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- startExternalEntity
endExternalEntity
public void endExternalEntity(String systemId) throws SAXException
- Implement com.microstar.xml.XmlHandler#endExternalEntity.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- endExternalEntity
doctypeDecl
public void doctypeDecl(String name,
String publicId,
String systemId) throws SAXException
- Implement com.microstar.xml.XmlHandler#doctypeDecl.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- doctypeDecl
attribute
public void attribute(String aname,
String value,
boolean isSpecified) throws SAXException
- Implement com.microstar.xml.XmlHandler#attribute.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- attribute
startElement
public void startElement(String elname) throws SAXException
- Implement com.microstar.xml.XmlHandler#startElement.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- startElement
endElement
public void endElement(String elname) throws SAXException
- Implement com.microstar.xml.XmlHandler#endElement.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- endElement
charData
public void charData(char ch[],
int start,
int length) throws SAXException
- Implement com.microstar.xml.XmlHandler#charData.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- charData
ignorableWhitespace
public void ignorableWhitespace(char ch[],
int start,
int length) throws SAXException
- Implement com.microstar.xml.XmlHandler#ignorableWhitespace.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- ignorableWhitespace
processingInstruction
public void processingInstruction(String target,
String data) throws SAXException
- Implement com.microstar.xml.XmlHandler#processingInstruction.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- processingInstruction
error
public void error(String message,
String url,
int line,
int column) throws SAXException
- Implement com.microstar.xml.XmlHandler#error.
Translate to the SAX interface.
Users should never invoke this method directly.
- Throws: SAXException
- May throw any exception.
- See Also:
- error
getLength
public int getLength()
getName
public String getName(int i)
getType
public String getType(int i)
getValue
public String getValue(int i)
getType
public String getType(String name)
getValue
public String getValue(String name)
getPublicId
public String getPublicId()
getSystemId
public String getSystemId()
getLineNumber
public int getLineNumber()
getColumnNumber
public int getColumnNumber()
All Packages Class Hierarchy This Package Previous Next Index