Titanium.XML

Submodule of Titanium.
Platform Since
Android 0.9
iPhone 0.9
iPad 0.9
Mobile Web 0.9

Summary

The top level XML module. The XML module is used parsing and processing XML-based content.

Objects

Name Summary
Titanium.XML.Attr

Proxy representing an attribute of an Element, as defined in the DOM Level 2 specification. (Android, iPhone, iPad only.)

Titanium.XML.CharacterData

An interface extending Titanium.XML.Node with a set of attributes and methods for accessing character data in the DOM. This conforms to the DOM Level 2 defintion of a DOM CharacterData. Unlike the DOM, for reasons of compatibility with the javascript engine, text is represented by UTF-8 instead of UTF-16. (Android, iPhone, iPad only.)

Titanium.XML.DOMImplementation

The Titanium.XML.DOMImplementation interface provides a number of methods for performing operations that are independent of any particular instance of the document object model. This conforms to the DOM Level 2 defintion of a DOM DOMImplementation. (Android, iPhone, iPad only.)

Titanium.XML.Document

The DOM Document returned from Titanium.XML.parseString or Titanium.XML.parse. Implements the DOM Level 2 API. (Android, iPhone, iPad only.)

Titanium.XML.DocumentType

Each Titanium.XML.Document has a doctype attribute whose value is either 'null' or a Titanium.XML.DocumentType object. (Android, iPhone, iPad only.)

Titanium.XML.Element

Represents an element in a DOM document, a Titanium.XML.Node defined by a start-tag and end-tag (or an empty tag). Elements may have attributes associated with them. This conforms to the DOM Level 2 definition of a DOM Element. (Android, iPhone, iPad only.)

Titanium.XML.Entity

This interface represents an entity, either parsed or unparsed, in an XML document. Note that this models the entity itself not the entity declaration. The nodeName attribute that is inherited from Node contains the name of the entity. An Entity node does not have any parent. This conforms to the DOM Level 2 defintion of a DOM Entity. (Android, iPhone, iPad only.)

Titanium.XML.NamedNodeMap

A key-value paired map that maps String objects to Titanium.XML.Node objects. This conforms to the DOM Level 2 defintion of a DOM NamedNodeMap. (Android, iPhone, iPad only.)

Titanium.XML.Node

A single node in the [Document|Titanium.XML.Document] tree. For full property and method description, see the [DOM Level 2 API|http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1950641247]. (Android, iPhone, iPad only.)

Titanium.XML.NodeList

A list of Titanium.XML.Node objects. This conforms to the DOM Level 2 definition of a DOM NodeList. (Android, iPhone, iPad only.)

Titanium.XML.Notation

represents a notation declared in the DTD. See DOM Level 2 Spec (Android, iPhone, iPad only.)

Titanium.XML.ProcessingInstruction

a way to keep processor-specific information in the text of the document. See DOM Level 2 Spec (Android, iPhone, iPad only.)

Titanium.XML.Text

Represents the textual content of an Titanium.XML.Element or Titanium.XML.Attr This conforms to the DOM Level 2 defintion of a DOM Text. (Android, iPhone, iPad only.)

Methods

Name Summary
addEventListener

Adds the specified callback as an event listener for the named event.

fireEvent

Fires a synthesized event to any registered listeners.

parseString

Parses an XML string into a Titanium.XML.Document object. Throws an exception if the string is unable to be parsed into a valid document.

removeEventListener

Removes the specified callback as an event listener for the named event.

serializeToString

Serializes a Titanium.XML.Document object into a string.

Properties

This type has no properties.

Events

This type has no events.