class treeparser

Implements a treeparser

Description

Parse XML into a tree for maniopulation or fetch values uses XPath.

class attributes [NB. Highlighted attributes are static members]
function treeparser() - Constructor
function parseFile() - Parse an xmlfile into a tree.
function parseChunk() - Parse an xml chunk into a tree.
function xpathArray() - Retrive a string from the tree using XPath.
function toString() - Return the XML tree as a string.
function saveToFile() - Save the parser tree to a file.
function validation() - Should we validate the XML agains the DTD in the DOCTYPE element? .
function keep_blanks() - Make the parser keep all whitespace
function pedantic() - make the parser extra strict.

Functions

function treeparser Click to go up to the list
Constructor
Declaration:
    native function treeparser( )

function parseFile Click to go up to the list
Parse an xmlfile into a tree.
Declaration:
    native function parseFile( string filename )
Parameters:
    Parameter #1: string filename - the XML to parse

function parseChunk Click to go up to the list
Parse an xml chunk into a tree.
Declaration:
    native function parseChunk( string chunk )
Parameters:
    Parameter #1: string the - XML string to parse

function xpathArray Click to go up to the list
Retrive a string from the tree using XPath.
Declaration:
    native function xpathArray( string expr )
Parameters:
    Parameter #1: string the - XPath expression
Returns:
    a string containing the result.

function toString Click to go up to the list
Return the XML tree as a string.
Declaration:
    native function toString( )
Returns:
    a string containing the XML data

function saveToFile Click to go up to the list
Save the parser tree to a file.
Declaration:
    native function saveToFile( string filename )
Parameters:
    Parameter #1: string the - name of the file to save to.
Returns:
    true on success false on failure

function validation Click to go up to the list
Should we validate the XML agains the DTD in the DOCTYPE element? .
Parameters:
    Parameter #1: number bool - true for validate and false for no validation (default)

function keep_blanks Click to go up to the list
Make the parser keep all whitespace
Declaration:
    native function keep_blanks( number bool )
Parameters:
    Parameter #1: number bool - true (default) for yes and false for no

function pedantic Click to go up to the list
make the parser extra strict.
Declaration:
    native function pedantic( number bool )
Parameters:
    Parameter #1: number bool - true for yes and false for no (default)

Automatically generated at 8:45pm, Wednesday 08 January 2003 by feritedoc.