Objective Systems, Inc.  
Home
About ASN.1
Products
Free Software
Open Source
Documents
Services
Resources
Resellers
Customers
Careers
About Us
Contact Us
 

Google


Objective Systems, Inc.

OSXMLContentHandler Class Reference

#include <saxParser.h>

Inheritance diagram for OSXMLContentHandler:

ASN1XERSAXDecodeHandler List of all members.

Detailed Description

Receive notification of general document events.

This is the main interface that most SAX2 applications implement: if the application needs to be informed of basic parsing events, it implements this interface and registers an instance with the SAX2 parser using the setDocumentHandler method. The parser uses the instance to report basic document-related events like the start and end of elements and character data.

The order of events in this interface is very important, and mirrors the order of information in the document itself. For example, all of an element's content (character data, processing instructions, and/or subelements) will appear, in order, between the startElement event and the corresponding endElement event.


Public Member Functions

The virtual document handler interface
virtual void characters (const XMLCHAR *const chars, const unsigned int length)=0
virtual void endElement (const XMLCHAR *const uri, const XMLCHAR *const localname, const XMLCHAR *const qname)=0
virtual void startElement (const XMLCHAR *const uri, const XMLCHAR *const localname, const XMLCHAR *const qname, const XMLCHAR *const *attrs)=0


Member Function Documentation

virtual void OSXMLContentHandler::characters const XMLCHAR *const   chars,
const unsigned int  length
[pure virtual]
 

Receive notification of character data.

The Parser will call this method to report each chunk of character data. SAX parsers may return all contiguous character data in a single chunk, or they may split it into several chunks; however, all of the characters in any single event must come from the same external entity, so that the Locator provides useful information.

The application must not attempt to read from the array outside of the specified range.

Note that some parsers will report whitespace using the ignorableWhitespace() method rather than this one (validating parsers must do so).

Parameters:
chars The characters from the XML document.
length The number of characters to read from the array.

Implemented in ASN1XERSAXDecodeHandler.

virtual void OSXMLContentHandler::endElement const XMLCHAR *const   uri,
const XMLCHAR *const   localname,
const XMLCHAR *const   qname
[pure virtual]
 

Receive notification of the end of an element.

The SAX parser will invoke this method at the end of every element in the XML document; there will be a corresponding startElement() event for every endElement() event (even when the element is empty).

Parameters:
uri The URI of the asscioated namespace for this element
localname The local part of the element name
qname The QName of this element

Implemented in ASN1XERSAXDecodeHandler.

virtual void OSXMLContentHandler::startElement const XMLCHAR *const   uri,
const XMLCHAR *const   localname,
const XMLCHAR *const   qname,
const XMLCHAR *const *  attrs
[pure virtual]
 

Receive notification of the beginning of an element.

The Parser will invoke this method at the beginning of every element in the XML document; there will be a corresponding endElement() event for every startElement() event (even when the element is empty). All of the element's content will be reported, in order, before the corresponding endElement() event.

Note that the attribute list provided will contain only attributes with explicit values (specified or defaulted): IMPLIED attributes will be omitted.

Parameters:
uri The URI of the asscioated namespace for this element
localname The local part of the element name
qname The QName of this element
attrs The attributes attached to the element, if any.

Implemented in ASN1XERSAXDecodeHandler.


The documentation for this class was generated from the following file:

Copyright © 1997-2005 Objective Systems,Inc.
All Rights Reserved.
This document may be distributed in any form, electronic
or otherwise, provided that it is distributed in its entirety
and that the copyright and this notice are included.

This file was last modified on 8 Sep 2005.
ASN1C XER Runtime, ASN1C v5.8x