fileio/
mg_xmlsax_example__define.pro
includes main-level programThis class is an example of using a SAX parser to parse XML files.
Examples
Run the main-level program to see an example of using the class to parse an XML file available from the internet.
Class description for mg_xmlsax_example
Inheritance
- IDLFFXMLSAX
Properties
- _extra init
Fields
- INDENTATION 0L
Fields in IDLFFXMLSAX
- IDLFFXMLSAX_BOTTOM 0LL
- IDLFFXMLSAXVERSION 0S
- IDLFFXMLSAX_TOP 0LL
- _XML_PARSER 0LL
- HALT_PROCESSING 0S
- VALIDATION_MODE 0S
- _XML_LOCATOR 0LL
- FILENAME ''
Author information
- Author
Michael Galloy
Routines
result = mg_xmlsax_example::_getSpacing()
Returns the current indentation as a string.
mg_xmlsax_example::startElement, uri, local, name [, attname] [, attvalue]
Called by parser when an XML tag is first encountered.
mg_xmlsax_example::endElement, uri, local, name
Called by the parser when an XML tag is finished.
mg_xmlsax_example::characters, chars
Called for text content between tags.
result = mg_xmlsax_example::init( [_extra=keywords])
Initialize the XML SAX parser.
mg_xmlsax_example__define
Define instance variables for parser.
Routine details
top source mg_xmlsax_example::_getSpacingprivate
result = mg_xmlsax_example::_getSpacing()
Returns the current indentation as a string.
Return value
string
top source mg_xmlsax_example::startElement
mg_xmlsax_example::startElement, uri, local, name [, attname] [, attvalue]
Called by parser when an XML tag is first encountered.
Parameters
- uri in required type=string
namespace URI associated with element
- local in required type=string
tag name with any prefix removed
- name in required type=string
tag name
- attname in optional type=starr
attribute names, if present
- attvalue in optional type=strarr
attribute values, if present
top source mg_xmlsax_example::endElement
mg_xmlsax_example::endElement, uri, local, name
Called by the parser when an XML tag is finished.
Parameters
- uri in required type=string
namespace URI associated with element
- local in required type=string
tag name with any prefix removed
- name in required type=string
tag name
top source mg_xmlsax_example::characters
mg_xmlsax_example::characters, chars
Called for text content between tags.
This method is called frequently because *any* character data between a begin and end tag counts (i.e. linefeeds, spaces, etc.).
Parameters
- chars in required type=string
string between tags
File attributes
Modification date: | Mon Nov 29 18:34:31 2010 |
Lines: | 140 |
Docformat: | rst rst |