Class XML

Description

DOM Wrapper class

This class extends the DOMDocument interface with additional functionality like schema validation using the internal schemas and a static XPath instance.

Located in /phpsatk-lib/core/01.xml.php (line 37)

DOMDocument
   |
   --XML
Direct descendents
Class Description
XMLFile XML Wrapper for files
XMLString XML Wrapper for xml data in strings
XMLSubtree Generates a new XML document out of a node
Class Constant Summary
 DEFAULT_ENCODING = 'utf-8'
 DEFAULT_VERSION = '1.0'
Method Summary
XML __construct ([string $version = XML::DEFAULT_VERSION], [string $encoding = XML::DEFAULT_ENCODING])
DOMXPath getXPath ()
void schemaValidate (string $filename, [boolean $internal = true])
Methods
Constructor __construct (line 65)

Initializes a new document

Basically creates a new DOMDocument

  • access: public
XML __construct ([string $version = XML::DEFAULT_VERSION], [string $encoding = XML::DEFAULT_ENCODING])
  • string $version: XML version
  • string $encoding: XML encoding

Redefined in descendants as:
getXPath (line 74)

Gets the static XPath instance for this document

  • access: public
DOMXPath getXPath ()
schemaValidate (line 90)

Validate by using a XML schema definition file

If used in internal mode, filenames will be relative to <GLOBAL>/data/schema.

  • access: public
void schemaValidate (string $filename, [boolean $internal = true])
  • string $filename: Path to XSD file
  • boolean $internal: Interal mode on/off
Class Constants
DEFAULT_ENCODING = 'utf-8' (line 48)

Default encoding to be used in all documents

DEFAULT_VERSION = '1.0' (line 42)

Default XML version used in all documents

Documentation generated on Mon, 21 May 2007 10:34:33 +0200 by phpDocumentor 1.3.0RC5