Skip Headers

Oracle® XML API Reference
10g Release 1 (10.1)
Part No. B10789-01
  Go To Documentation Library
Home
Go To Product List
Solution Area
Go To Table Of Contents
Contents

Previous Next  

SAXParser Interface

Table 18-6 summarizes the methods of available through the SAXParser interface.

Table 18-6 Summary of SAXParser Methods; Parser Package

Function Summary
getContext
Returns parser's XML context (allocation and encodings).
getParserId
Returns parser Id.
parse
Parse the document.
parseDTD
Parse the DTD.
setSAXHandler
Set SAX handler.


getContext

Each parser object is allocated and executed in a particular Oracle XML context. This member function returns a pointer to this context.


Syntax
virtual Context* getContext() const = 0;


Returns

(Context*) pointer to parser's context


getParserId

Returns the parser id.


Syntax
virtual SAXParserIdType getParserId() const = 0;


Returns

(SAXParserIdType) Parser Id


parse

Parses a document.


Syntax
virtual void parse( 
   InputSource* src_ptr,
   boolean DTDvalidate = FALSE,
   SAXHandlerRoot* hdlr_ptr = NULL)
throw (ParserException) = 0;

Parameter Description
src_ptr
input source
DTDValidate
TRUE if validate with DTD
hdlr_ptr
SAX handler pointer


parseDTD

Parses a DTD.


Syntax
virtual void parseDTD( 
   InputSource* src_ptr,
   SAXHandlerRoot* hdlr_ptr = NULL)
throw (ParserException) = 0;

Parameter Description
src_ptr
input source
hdlr_ptr
SAX handler pointer


setSAXHandler

Sets SAX handler for all parser invocations except when another SAX handler is specified in the parser call.


Syntax
virtual void setSAXHandler(
   SAXHandlerRoot* hdlr_ptr) = 0;

Parameter Description
hdlr_ptr
SAX handler pointer