Skip to content

Files

Latest commit

author
James Watts
May 2, 2013
1fe860e · May 2, 2013

History

History
133 lines (115 loc) · 2.58 KB

Node.md

File metadata and controls

133 lines (115 loc) · 2.58 KB

Node

The Node object represents an element (tag) in the XML document. As the language is extensible, this object serves as a generic base for any element.

$node = $this->Xml->Node();

Object

The class inheritance for the object.

Extends

Implements

Parameters

The configuration parameters for the template.

Name Type Default Description
name string node Defines the name of the element (tag).
cdata boolean false Determines if the value of the element is wrapped in a CDATA comment.
value string Defines the value of the element.

Properties

The properties affecting object behavior.

Property Value Description
Allow parent true Determines if the object can have a parent.
Allow children true Determines if the object can have children.
Allow events false Determines if events can be added to the object.
Limit parent Defines the allowed parents for the object, or any if none specified.
Limit children Defines the allowed children for the object, or any if none specified.

Methods

The contextual methods for the object.

Method Returns Description
hasAttribute(string $name) boolean Determines if a given attribute has been set.
getAttribute(string $name) mixed Returns an attribute set on the node.
setAttribute(string $name, mixed $value = null) XmlNode Sets an attribute on the node.
removeAttribute(string $name) XmlNode Removes a previously set attribute from the node.
clearAttributes() XmlNode Removes all attributes previously set on the node.