Child pages
  • XML

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

padding0px
width80px

...

Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Property Summary
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
ignoreComments
If set to true, then comments in the XML are ignored when constructing new XML objects.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
ignoreProcessingInstructions
If set to true, then processing instructions are ignored when constructing new XML objects.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
ignoreWhitespace
If set to true, then whitespace in the XML is ignored when constructing new XML objects.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
prettyIndent
The amount of positions used when indenting child nodes are relative to their parent
if prettyPrinting is enabled.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
prettyPrinting
If set to true, then toString() and toXMLString() methods will normalize the output
to achieve a uniform appearance.

...

padding0px
width80px

...

Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Method Summary
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
addNamespace(namespaceToAdd)
Takes one argument which can be a string with a namespace URI or a Namespace object and adds the
argument to the in scope namespaces of this XML object.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
appendChild(childToAppend)
Appends a new child at the end of this XML object's properties, the changed XML object is then returned.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
attribute(attributeName)
Takes a single argument with the attribute name and returns an XMLList with attributes
matching the argument.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
attributes()
Returns an XMLList with the attributes of this XML object which are in no namespace.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
child(propertyName)
Returns an XMLList with children matching the property name.
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
childIndex()
If the XML object has no parent then the special number NaN is returned, otherwise the ordinal
position the object has in the context of its parent is returned.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
children()
Returns an XMLList with the child nodes of this XML object.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
comments()
Returns an XMLList with the comment nodes which are children of this XML object.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
contains(value)
Calling xmlObject.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
copy()
Returns a deep copy of the XML object it is called on where the internal parent property is set to null
Table Row (tr)
Table Cell (td)
Object
Table Cell (td)
defaultSettings()
Returns an object containing the default XML settings.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
descendants()
Returns an XMLList with the descendants matching the passed name argument or with all descendants
if no argument is passed.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
descendants(name)
Returns an XMLList with the descendants matching the passed name argument or with all descendants
if no argument is passed.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
elements()
Takes one optional argument, the name of elements you are looking for, and returns an XMLList with
all matching child elements.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
elements(name)
Takes one optional argument, the name of elements you are looking for, and returns an XMLList with
all matching child elements.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
hasComplexContent()
Returns false for XML objects of node kind 'text', 'attribute', 'comment', and 'processing-instruction'.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
hasOwnProperty(propertyName)
Returns true if the XML object the method is called on has a property of that name.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
hasSimpleContent()
Returns true for XML objects of node kind text or attribute.
Table Row (tr)
Table Cell (td)
Array
Table Cell (td)
inScopeNamespaces()
Returns an array of Namespace objects representing the namespace that are in scope for this XML object.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
insertChildAfter(childToInserAfter, childToInsert)
Takes two arguments, an existing child to insert after and the new child to be inserted.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
insertChildBefore(childToInsertBefore, childToInsert)
Takes two arguments, an existing child to insert before and the new child to be inserted.
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
length()
This always returns 1.
Table Row (tr)
Table Cell (td)
String
Table Cell (td)
localName()
returns the local name part if the XML object has a name.
Table Row (tr)
Table Cell (td)
QName
Table Cell (td)
name()
Returns the qualified name (a QName object) of the XML object it is called
Table Row (tr)
Table Cell (td)
Namespace
Table Cell (td)
namespace()
If no argument is passed to the method then it returns the namespace associated with the qualified
name of this XML object.
Table Row (tr)
Table Cell (td)
Namespace
Table Cell (td)
namespace(prefix)
If no argument is passed to the method then it returns the namespace associated with the qualified
name of this XML object.
Table Row (tr)
Table Cell (td)
Array
Table Cell (td)
namespaceDeclarations()
Returns an array with the namespace declarations associated with the XML object it is called on.
Table Row (tr)
Table Cell (td)
String
Table Cell (td)
nodeKind()
Returns a string denoting the kind of node this XML object represents.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
normalize()
Returns this XML object after normalizing all text content.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
parent()
Returns the parent XML object of this XML object or null if there is no parent.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
prependChild(childToPrepend)
Iinserts the given value as the first child of the XML object and returns the XML object.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
processingInstructions()
If no argument is passed in then the method returns an XMLList with all the children of the XML
object which are processing instructions.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
processingInstructions(name)
If no argument is passed in then the method returns an XMLList with all the children of the XML
object which are processing instructions.
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
propertyIsEnumerable(propertyName)
Returns true if the property name is '0' and false otherwise.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
removeNamespace(namespace)
Removes the namespace from the in scope namespaces of this XML object if the namespace
is not used for the qualified name of the object or its attributes.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
replace(propertyName, replacementValue)
Takes two arguments, the property name of the property / properties to be replaced, and the
value to replace the properties.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
setChildren(value)
Replaces all children of the XML object with this value.
Table Row (tr)
Table Cell (td)
void
Table Cell (td)
setLocalName(name)
Changes the local name of this XML object to the name passed in.
Table Row (tr)
Table Cell (td)
void
Table Cell (td)
setName(name)
Replaces the name of this XML object with the name passed in.
Table Row (tr)
Table Cell (td)
void
Table Cell (td)
setNamespace(namespace)
Changes the namespace associated with the name of this XML object to the new namespace.
Table Row (tr)
Table Cell (td)
void
Table Cell (td)
setSettings()
Allows the global XML settings to be adjusted or restored to their default values.
Table Row (tr)
Table Cell (td)
void
Table Cell (td)
setSettings(settings)
Allows the global XML settings to be adjusted or restored to their default values.
Table Row (tr)
Table Cell (td)
Object
Table Cell (td)
settings()
Returns an object containing the global XML settings.
Table Row (tr)
Table Cell (td)
XMLList
Table Cell (td)
text()
Returns an XMLList with all the children of this XML object that represent text nodes.
Table Row (tr)
Table Cell (td)
String
Table Cell (td)
toString()
Returns a convenient string value of this XML object.
Table Row (tr)
Table Cell (td)
String
Table Cell (td)
toXMLString()
Returns a string with the serialized XML markup for this XML object.
Table Row (tr)
Table Cell (td)
XML
Table Cell (td)
valueOf()
The method simply returns the XML object it is called on.

...

idproperty
classservoy sDetail

...

padding0px
width100%
Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan1
Property Details

...

idignoreComments
Table Row (tr)
idname
Table Cell (td)
ignoreComments
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If set to true, then comments in the XML are ignored when constructing new XML objects.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var element = <foo><!-- my comment --><bar/></foo>;
application.output(element.comments().length());
application.output(element.toXMLString());

XML.ignoreComments = false;

element = <foo><!-- my comment --><bar/></foo>;
application.output(element.comments().length());
application.output(element.toXMLString());

...

classlastDetailRow

...

idignoreProcessingInstructions
Table Row (tr)
idname
Table Cell (td)
ignoreProcessingInstructions
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If set to true, then processing instructions are ignored when constructing new XML objects.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
XML.ignoreProcessingInstructions=false;
var xmlElement = <publishing><?process author="yes"?><author type="leadership">John C. Maxwell</author></publishing>;
application.output(" Element = "+ xmlElement.toXMLString());

...

classlastDetailRow

...

idignoreWhitespace
Table Row (tr)
idname
Table Cell (td)
ignoreWhitespace
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If set to true, then whitespace in the XML is ignored when constructing new XML objects.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
XML.ignoreWhitespace = false;
 var xmlElement =
 <publishing>
 	<author>John C. Maxwell</author>
 </publishing>;
 application.output(xmlElement.toString());

...

classlastDetailRow

...

idprettyIndent
Table Row (tr)
idname
Table Cell (td)
prettyIndent
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The amount of positions used when indenting child nodes are relative to their parent
if prettyPrinting is enabled.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var xmlElement = <publishing><author>Tom DeMarco</author><author>Roger S. Pressman</author></publishing>;
application.output(xmlElement.toXMLString());
XML.prettyPrinting = true;
XML.prettyIndent = 4;
xmlElement = <publishing><author>Tom DeMarco</author><author>Roger S. Pressman</author></publishing>;
application.output(xmlElement.toXMLString());

...

classlastDetailRow

...

idprettyPrinting
Table Row (tr)
idname
Table Cell (td)
prettyPrinting
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If set to true, then toString() and toXMLString() methods will normalize the output
to achieve a uniform appearance.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
var xmlElement = <publishing><author>Tom DeMarco</author><author>Roger S. Pressman</author></publishing>;
application.output(xmlElement.toXMLString());
XML.prettyPrinting = true;
XML.prettyIndent = 4;
xmlElement = <publishing><author>Tom DeMarco</author><author>Roger S. Pressman</author></publishing>;
application.output(xmlElement.toXMLString());

...

classlastDetailRow

...

idfunction
classservoy sDetail

...

padding0px
width100%
Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan1
Method Details

...

idaddNamespace-String
Table Row (tr)
idname
Table Cell (td)
addNamespace
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
addNamespace
Span
(namespaceToAdd)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Takes one argument which can be a string with a namespace URI or a Namespace object and adds the
argument to the in scope namespaces of this XML object.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} namespaceToAdd
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.addNamespace(namespaceToAdd)

...

classlastDetailRow

...

idappendChild-XML
Table Row (tr)
idname
Table Cell (td)
appendChild
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
appendChild
Span
(childToAppend)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Appends a new child at the end of this XML object's properties, the changed XML object is then returned.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{XML} childToAppend
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.appendChild(childToAppend)

...

classlastDetailRow

...

idattribute-String
Table Row (tr)
idname
Table Cell (td)
attribute
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
attribute
Span
(attributeName)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Takes a single argument with the attribute name and returns an XMLList with attributes
matching the argument.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} attributeName
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.attribute(attributeName)

...

classlastDetailRow

...

idattributes
Table Row (tr)
idname
Table Cell (td)
attributes
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
attributes
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an XMLList with the attributes of this XML object which are in no namespace.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.attributes()

...

classlastDetailRow

...

idchild-String
Table Row (tr)
idname
Table Cell (td)
child
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
child
Span
(propertyName)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an XMLList with children matching the property name.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} propertyName
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.child(childPropertyName)

...

classlastDetailRow

...

idchildIndex
Table Row (tr)
idname
Table Cell (td)
childIndex
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
childIndex
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If the XML object has no parent then the special number NaN is returned, otherwise the ordinal
position the object has in the context of its parent is returned.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.childIndex()

...

classlastDetailRow

...

idchildren
Table Row (tr)
idname
Table Cell (td)
children
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
children
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an XMLList with the child nodes of this XML object.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.children()

...

classlastDetailRow

...

idcomments
Table Row (tr)
idname
Table Cell (td)
comments
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
comments
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an XMLList with the comment nodes which are children of this XML object.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.comments()

...

classlastDetailRow

...

idcontains-Object
Table Row (tr)
idname
Table Cell (td)
contains
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
contains
Span
(value)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Calling xmlObject.contains(value) yields the same result as the equality comparison xmlObject == value
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.contains(value)

...

classlastDetailRow

...

idcopy
Table Row (tr)
idname
Table Cell (td)
copy
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
copy
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns a deep copy of the XML object it is called on where the internal parent property is set to null
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.copy()

...

classlastDetailRow

...

iddefaultSettings
Table Row (tr)
idname
Table Cell (td)
defaultSettings
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Object
Span
stylefont-weight: bold;
defaultSettings
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an object containing the default XML settings.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Object
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.defaultSettings()

...

classlastDetailRow

...

iddescendants
Table Row (tr)
idname
Table Cell (td)
descendants
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
descendants
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an XMLList with the descendants matching the passed name argument or with all descendants
if no argument is passed.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.descendants([name])

...

classlastDetailRow

...

iddescendants-String
Table Row (tr)
idname
Table Cell (td)
descendants
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
descendants
Span
(name)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an XMLList with the descendants matching the passed name argument or with all descendants
if no argument is passed.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} name
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.descendants([name])

...

classlastDetailRow

...

idelements
Table Row (tr)
idname
Table Cell (td)
elements
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
elements
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Takes one optional argument, the name of elements you are looking for, and returns an XMLList with
all matching child elements.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.elements([name])

...

classlastDetailRow

...

idelements-String
Table Row (tr)
idname
Table Cell (td)
elements
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
elements
Span
(name)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Takes one optional argument, the name of elements you are looking for, and returns an XMLList with
all matching child elements.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} name
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.elements([name])

...

classlastDetailRow

...

idhasComplexContent
Table Row (tr)
idname
Table Cell (td)
hasComplexContent
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
hasComplexContent
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns false for XML objects of node kind 'text', 'attribute', 'comment', and 'processing-instruction'.
For objects of kind 'element' it checks whether the element has at least one child element.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.hasComplexContent()

...

classlastDetailRow

...

idhasOwnProperty-String
Table Row (tr)
idname
Table Cell (td)
hasOwnProperty
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
hasOwnProperty
Span
(propertyName)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns true if the XML object the method is called on has a property of that name.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} propertyName
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.hasOwnProperty(propertyName)

...

classlastDetailRow

...

idhasSimpleContent
Table Row (tr)
idname
Table Cell (td)
hasSimpleContent
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
hasSimpleContent
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns true for XML objects of node kind text or attribute. For XML objects of node kind
element it returns true if the element has no child elements and false otherwise.
For other node kinds (comment, processing instruction) the method always returns false.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.hasSimpleContent()

...

classlastDetailRow

...

idinScopeNamespaces
Table Row (tr)
idname
Table Cell (td)
inScopeNamespaces
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
inScopeNamespaces
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an array of Namespace objects representing the namespace that are in scope for this XML object.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.inScopeNamespaces()

...

classlastDetailRow

...

idinsertChildAfter-XML_XML
Table Row (tr)
idname
Table Cell (td)
insertChildAfter
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
insertChildAfter
Span
(childToInserAfter, childToInsert)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Takes two arguments, an existing child to insert after and the new child to be inserted.
If the first argument is null then the second argument is inserted as the first child of this XML.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{XML} childToInserAfter
{XML} childToInsert
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.insertChildAfter(childToInsertAfter, childToInsert)

...

classlastDetailRow

...

idinsertChildBefore-XML_XML
Table Row (tr)
idname
Table Cell (td)
insertChildBefore
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
insertChildBefore
Span
(childToInsertBefore, childToInsert)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Takes two arguments, an existing child to insert before and the new child to be inserted.
If the first argument is null then the child is inserted as the last child.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{XML} childToInsertBefore
{XML} childToInsert
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.insertChildBefore(childToInsertBefore, childToInsert)

...

classlastDetailRow

...

idlength
Table Row (tr)
idname
Table Cell (td)
length
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
length
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
This always returns 1. This is done to blur the distinction between an XML object and an XMLList
containing exactly one value.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.length()

...

classlastDetailRow

...

idlocalName
Table Row (tr)
idname
Table Cell (td)
localName
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
String
Span
stylefont-weight: bold;
localName
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
returns the local name part if the XML object has a name.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
String
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.localName()

...

classlastDetailRow

...

idname
Table Row (tr)
idname
Table Cell (td)
name
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
QName
Span
stylefont-weight: bold;
name
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns the qualified name (a QName object) of the XML object it is called
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
QName
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.name()

...

classlastDetailRow

...

idnamespace
Table Row (tr)
idname
Table Cell (td)
namespace
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Namespace
Span
stylefont-weight: bold;
namespace
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If no argument is passed to the method then it returns the namespace associated with the qualified
name of this XML object. If a prefix is passed to the method then it looks for a matching namespace
in the in scope namespace of this XML object and returns it when found, otherwise undefined is returned.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Namespace
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.namespace([prefix])

...

classlastDetailRow

...

idnamespace-String
Table Row (tr)
idname
Table Cell (td)
namespace
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Namespace
Span
stylefont-weight: bold;
namespace
Span
(prefix)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If no argument is passed to the method then it returns the namespace associated with the qualified
name of this XML object. If a prefix is passed to the method then it looks for a matching namespace
in the in scope namespace of this XML object and returns it when found, otherwise undefined is returned.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} prefix
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Namespace
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.namespace([prefix])

...

classlastDetailRow

...

idnamespaceDeclarations
Table Row (tr)
idname
Table Cell (td)
namespaceDeclarations
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Array
Span
stylefont-weight: bold;
namespaceDeclarations
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an array with the namespace declarations associated with the XML object it is called on.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Array
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.namespaceDeclarations()

...

classlastDetailRow

...

idnodeKind
Table Row (tr)
idname
Table Cell (td)
nodeKind
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
String
Span
stylefont-weight: bold;
nodeKind
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns a string denoting the kind of node this XML object represents. Possible values: 'element',
'attribute', 'text', 'comment', 'processing-instruction'.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
String
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.nodeKind()

...

classlastDetailRow

...

idnormalize
Table Row (tr)
idname
Table Cell (td)
normalize
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
normalize
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns this XML object after normalizing all text content.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.normalize()

...

classlastDetailRow

...

idparent
Table Row (tr)
idname
Table Cell (td)
parent
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
parent
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns the parent XML object of this XML object or null if there is no parent.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.parent()

...

classlastDetailRow

...

idprependChild-XML
Table Row (tr)
idname
Table Cell (td)
prependChild
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
prependChild
Span
(childToPrepend)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Iinserts the given value as the first child of the XML object and returns the XML object.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{XML} childToPrepend
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.prependChild(childToPrepend)

...

classlastDetailRow

...

idprocessingInstructions
Table Row (tr)
idname
Table Cell (td)
processingInstructions
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
processingInstructions
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If no argument is passed in then the method returns an XMLList with all the children of the XML
object which are processing instructions. If an argument is passed in then the method returns an
XMLList with all children of the XML object which are processing instructions where the name
matches the argument.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.processingInstructions([name])

...

classlastDetailRow

...

idprocessingInstructions-String
Table Row (tr)
idname
Table Cell (td)
processingInstructions
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
processingInstructions
Span
(name)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
If no argument is passed in then the method returns an XMLList with all the children of the XML
object which are processing instructions. If an argument is passed in then the method returns an
XMLList with all children of the XML object which are processing instructions where the name
matches the argument.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} name
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.processingInstructions([name])

...

classlastDetailRow

...

idpropertyIsEnumerable-String
Table Row (tr)
idname
Table Cell (td)
propertyIsEnumerable
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
propertyIsEnumerable
Span
(propertyName)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns true if the property name is '0' and false otherwise.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} propertyName
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.propertyIsEnumerable(propertyName)

...

classlastDetailRow

...

idremoveNamespace-Namespace
Table Row (tr)
idname
Table Cell (td)
removeNamespace
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
removeNamespace
Span
(namespace)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Removes the namespace from the in scope namespaces of this XML object if the namespace
is not used for the qualified name of the object or its attributes.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Namespace} namespace
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.removeNamespace(namespace)

...

classlastDetailRow

...

idreplace-String_XML
Table Row (tr)
idname
Table Cell (td)
replace
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
replace
Span
(propertyName, replacementValue)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Takes two arguments, the property name of the property / properties to be replaced, and the
value to replace the properties.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} propertyName
{XML} replacementValue
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.replace(propertyName, replacementValue)

...

classlastDetailRow

...

idsetChildren-Object
Table Row (tr)
idname
Table Cell (td)
setChildren
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
setChildren
Span
(value)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Replaces all children of the XML object with this value. The method returns the XML object it
is called on.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} value
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.setChildren(value)

...

classlastDetailRow

...

idsetLocalName-String
Table Row (tr)
idname
Table Cell (td)
setLocalName
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
void
Span
stylefont-weight: bold;
setLocalName
Span
(name)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Changes the local name of this XML object to the name passed in.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} name
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
void
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.setLocalName(name)

...

classlastDetailRow

...

idsetName-String
Table Row (tr)
idname
Table Cell (td)
setName
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
void
Span
stylefont-weight: bold;
setName
Span
(name)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Replaces the name of this XML object with the name passed in.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{String} name
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
void
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.setName(name)

...

classlastDetailRow

...

idsetNamespace-Namespace
Table Row (tr)
idname
Table Cell (td)
setNamespace
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
void
Span
stylefont-weight: bold;
setNamespace
Span
(namespace)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Changes the namespace associated with the name of this XML object to the new namespace.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Namespace} namespace
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
void
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.setNamespace(namespace)

...

classlastDetailRow

...

idsetSettings
Table Row (tr)
idname
Table Cell (td)
setSettings
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
void
Span
stylefont-weight: bold;
setSettings
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Allows the global XML settings to be adjusted or restored to their default values.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
void
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.setSettings(settings)

...

classlastDetailRow

...

idsetSettings-Object
Table Row (tr)
idname
Table Cell (td)
setSettings
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
void
Span
stylefont-weight: bold;
setSettings
Span
(settings)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Allows the global XML settings to be adjusted or restored to their default values.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Object} settings - The new settings that should be applied globally to the XML object.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
void
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.setSettings(settings)

...

classlastDetailRow

...

idsettings
Table Row (tr)
idname
Table Cell (td)
settings
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Object
Span
stylefont-weight: bold;
settings
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an object containing the global XML settings.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Object
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.settings()

...

classlastDetailRow

...

idtext
Table Row (tr)
idname
Table Cell (td)
text
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XMLList
Span
stylefont-weight: bold;
text
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns an XMLList with all the children of this XML object that represent text nodes.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XMLList
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.text()

...

classlastDetailRow

...

idtoString
Table Row (tr)
idname
Table Cell (td)
toString
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
String
Span
stylefont-weight: bold;
toString
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns a convenient string value of this XML object.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
String
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.toString()

...

classlastDetailRow

...

idtoXMLString
Table Row (tr)
idname
Table Cell (td)
toXMLString
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
String
Span
stylefont-weight: bold;
toXMLString
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns a string with the serialized XML markup for this XML object. XML.prettyPrinting
and XML.prettyIndent settings affect the returned string.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
String
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.toXMLString()

...

classlastDetailRow

...

idvalueOf
Table Row (tr)
idname
Table Cell (td)
valueOf
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
XML
Span
stylefont-weight: bold;
valueOf
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The method simply returns the XML object it is called on.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
XML
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript
xml.valueOf()

...

classlastDetailRow

...

DO NOT EDIT THE CONTENT OF THIS PAGE DIRECTLY (EXCEPT INSIDE THE DIV BELOW WITH ID=DESCRIPTION), UNLESS YOU KNOW WHAT YOU'RE DOING.
THE STRUCTURE OF THE CONTENT IS VITAL IN BEING ABLE TO AUTO UPDATE THE CONTENT THROUGH THE DOC GENERATOR.
Enter additional information related to this 'class' inside the {div} macro with 'id=description'
Divcache
styleindexdisplay:none

...

iddescription
Creating XML objects

...

from a string

Code Block
var myXml = new XML('<test level="1"><test2 level="2">A value</test2></test>');

using XML object notation

Code Block
var myXml =
<test level="1">
  <test2 level="2">A value</test2>
</test>;

using JavaScript variables

Code Block
var myValue = 'hello, some value!';
var myXml =
<test level="1">
  <test2 level="2">{myValue}</test2>
</test>;

...

Accessing the XML

...

General

Code Block
var myXml = new XML('<test level="1"><test2 level="2">A value</test2></test>');
application.output(myXml.test2.toString()); //outputs 'A value'

A specific index on subnodes

Code Block
var myXml = new XML('<test level="1"><test2 level="2">A value</test2><test2 level="2">Another value</test2></test>');
application.output(myXml.test2[1].toXMLString()); //outputs '<test2 level="2">Another value</test2>'

XML in Action!

...

true
refresh100d
showRefreshtrue
iddoc
titleRefresh page
showDatetrue
retryEnable

servoy sReturnTypes2100%height: 30px;2Supported ClientssWordListSmartClientsWordListWebClientsWordListNGClient

servoy sSummary12%30%58%height: 30px;3Property SummaryIf set to true, then comments in the XML are ignored when constructing new XML objects.If set to true, then processing instructions are ignored when constructing new XML objects.If set to true, then whitespace in the XML is ignored when constructing new XML objects.The amount of positions used when indenting child nodes are relative to their parent if prettyPrinting is enabled.If set to true, then toString() and toXMLString() methods will normalize the output to achieve a uniform appearance.

servoy sSummary12%30%58%height: 30px;3Methods SummaryTakes one argument which can be a string with a namespace URI or a Namespace object and adds the argument to the in scope namespaces of this XML object.Appends a new child at the end of this XML object's properties, the changed XML object is then returned.Takes a single argument with the attribute name and returns an XMLList with attributes matching the argument.Returns an XMLList with the attributes of this XML object which are in no namespace.Returns an XMLList with children matching the property name.If the XML object has no parent then the special number NaN is returned, otherwise the ordinal position the object has in the context of its parent is returned.Returns an XMLList with the child nodes of this XML object.Returns an XMLList with the comment nodes which are children of this XML object.Calling xmlObject.Returns a deep copy of the XML object it is called on where the internal parent property is set to nullReturns an object containing the default XML settings.Returns an XMLList with the descendants matching the passed name argument or with all descendants if no argument is passed.Returns an XMLList with the descendants matching the passed name argument or with all descendants if no argument is passed.Takes one optional argument, the name of elements you are looking for, and returns an XMLList with all matching child elements.Takes one optional argument, the name of elements you are looking for, and returns an XMLList with all matching child elements.Returns false for XML objects of node kind 'text', 'attribute', 'comment', and 'processing-instruction'.Returns true if the XML object the method is called on has a property of that name.Returns true for XML objects of node kind text or attribute.Returns an array of Namespace objects representing the namespace that are in scope for this XML object.Takes two arguments, an existing child to insert after and the new child to be inserted.Takes two arguments, an existing child to insert before and the new child to be inserted.This always returns 1.returns the local name part if the XML object has a name.Returns the qualified name (a QName object) of the XML object it is calledIf no argument is passed to the method then it returns the namespace associated with the qualified name of this XML object.If no argument is passed to the method then it returns the namespace associated with the qualified name of this XML object.Returns an array with the namespace declarations associated with the XML object it is called on.Returns a string denoting the kind of node this XML object represents.Returns this XML object after normalizing all text content.Returns the parent XML object of this XML object or null if there is no parent.Iinserts the given value as the first child of the XML object and returns the XML object.If no argument is passed in then the method returns an XMLList with all the children of the XML object which are processing instructions.If no argument is passed in then the method returns an XMLList with all the children of the XML object which are processing instructions.Returns true if the property name is '0' and false otherwise.Removes the namespace from the in scope namespaces of this XML object if the namespace is not used for the qualified name of the object or its attributes.Takes two arguments, the property name of the property / properties to be replaced, and the value to replace the properties.Replaces all children of the XML object with this value.voidChanges the local name of this XML object to the name passed in.voidReplaces the name of this XML object with the name passed in.voidChanges the namespace associated with the name of this XML object to the new namespace.voidAllows the global XML settings to be adjusted or restored to their default values.voidAllows the global XML settings to be adjusted or restored to their default values.Returns an object containing the global XML settings.Returns an XMLList with all the children of this XML object that represent text nodes.Returns a convenient string value of this XML object.Returns a string with the serialized XML markup for this XML object.The method simply returns the XML object it is called on.

propertyservoy sDetail2100%height:30px2Property DetailsignoreCommentsname

ignoreComments

dessIndent
If set to true, then comments in the XML are ignored when constructing new XML objects.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRowignoreProcessingInstructionsname

ignoreProcessingInstructions

dessIndent
If set to true, then processing instructions are ignored when constructing new XML objects.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
ignoreWhitespacename

ignoreWhitespace

dessIndent
If set to true, then whitespace in the XML is ignored when constructing new XML objects.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
prettyIndentname

prettyIndent

dessIndent
The amount of positions used when indenting child nodes are relative to their parent
if prettyPrinting is enabled.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
prettyPrintingname

prettyPrinting

dessIndent
If set to true, then toString() and toXMLString() methods will normalize the output
to achieve a uniform appearance.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow

functionservoy sDetail2100%height:30px2Methods DetailsaddNamespacename

addNamespace(namespaceToAdd)

dessIndent
Takes one argument which can be a string with a namespace URI or a Namespace object and adds the 
argument to the in scope namespaces of this XML object.
prs

Parameters

sIndentnamespaceToAdd ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRowappendChildname

appendChild(childToAppend)

dessIndent
Appends a new child at the end of this XML object's properties, the changed XML object is then returned.
prs

Parameters

sIndentchildToAppend ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
attributename

attribute(attributeName)

dessIndent
Takes a single argument with the attribute name and returns an XMLList with attributes 
matching the argument.
prs

Parameters

sIndentattributeName ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
attributesname

attributes()

dessIndent
Returns an XMLList with the attributes of this XML object which are in no namespace.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
childname

child(propertyName)

dessIndent
Returns an XMLList with children matching the property name.
prs

Parameters

sIndentpropertyName ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
childIndexname

childIndex()

dessIndent
If the XML object has no parent then the special number NaN is returned, otherwise the ordinal 
position the object has in the context of its parent is returned.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
childrenname

children()

dessIndent
Returns an XMLList with the child nodes of this XML object.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
commentsname

comments()

dessIndent
Returns an XMLList with the comment nodes which are children of this XML object.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
containsname

contains(value)

dessIndent
Calling xmlObject.contains(value) yields the same result as the equality comparison xmlObject == value
prs

Parameters

sIndentvalue ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
copyname

copy()

dessIndent
Returns a deep copy of the XML object it is called on where the internal parent property is set to null
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
defaultSettingsname

defaultSettings()

dessIndent
Returns an object containing the default XML settings.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
descendantsname

descendants()

dessIndent
Returns an XMLList with the descendants matching the passed name argument or with all descendants 
if no argument is passed.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
descendantsname

descendants(name)

dessIndent
Returns an XMLList with the descendants matching the passed name argument or with all descendants 
if no argument is passed.
prs

Parameters

sIndentname ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
elementsname

elements()

dessIndent
Takes one optional argument, the name of elements you are looking for, and returns an XMLList with 
all matching child elements.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
elementsname

elements(name)

dessIndent
Takes one optional argument, the name of elements you are looking for, and returns an XMLList with 
all matching child elements.
prs

Parameters

sIndentname ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
hasComplexContentname

hasComplexContent()

dessIndent
Returns false for XML objects of node kind 'text', 'attribute', 'comment', and 'processing-instruction'.
For objects of kind 'element' it checks whether the element has at least one child element.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
hasOwnPropertyname

hasOwnProperty(propertyName)

dessIndent
Returns true if the XML object the method is called on has a property of that name.
prs

Parameters

sIndentpropertyName ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
hasSimpleContentname

hasSimpleContent()

dessIndent
Returns true for XML objects of node kind text or attribute. For XML objects of node kind 
element it returns true if the element has no child elements and false otherwise.
For other node kinds (comment, processing instruction) the method always returns false.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
inScopeNamespacesname

inScopeNamespaces()

dessIndent
Returns an array of Namespace objects representing the namespace that are in scope for this XML object.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
insertChildAftername

insertChildAfter(childToInserAfter, childToInsert)

dessIndent
Takes two arguments, an existing child to insert after and the new child to be inserted.
If the first argument is null then the second argument is inserted as the first child of this XML.
prs

Parameters

sIndentchildToInserAfter ;childToInsert ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
insertChildBeforename

insertChildBefore(childToInsertBefore, childToInsert)

dessIndent
Takes two arguments, an existing child to insert before and the new child to be inserted.
If the first argument is null then the child is inserted as the last child.
prs

Parameters

sIndentchildToInsertBefore ;childToInsert ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
lengthname

length()

dessIndent
This always returns 1. This is done to blur the distinction between an XML object and an XMLList 
containing exactly one value.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
localNamename

localName()

dessIndent
returns the local name part if the XML object has a name.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
namename

name()

dessIndent
Returns the qualified name (a QName object) of the XML object it is called
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
namespacename

namespace()

dessIndent
If no argument is passed to the method then it returns the namespace associated with the qualified 
name of this XML object. If a prefix is passed to the method then it looks for a matching namespace 
in the in scope namespace of this XML object and returns it when found, otherwise undefined is returned.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
namespacename

namespace(prefix)

dessIndent
If no argument is passed to the method then it returns the namespace associated with the qualified 
name of this XML object. If a prefix is passed to the method then it looks for a matching namespace 
in the in scope namespace of this XML object and returns it when found, otherwise undefined is returned.
prs

Parameters

sIndentprefix ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
namespaceDeclarationsname

namespaceDeclarations()

dessIndent
Returns an array with the namespace declarations associated with the XML object it is called on.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
nodeKindname

nodeKind()

dessIndent
Returns a string denoting the kind of node this XML object represents. Possible values: 'element', 
'attribute', 'text', 'comment', 'processing-instruction'.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
normalizename

normalize()

dessIndent
Returns this XML object after normalizing all text content.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
parentname

parent()

dessIndent
Returns the parent XML object of this XML object or null if there is no parent.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
prependChildname

prependChild(childToPrepend)

dessIndent
Iinserts the given value as the first child of the XML object and returns the XML object.
prs

Parameters

sIndentchildToPrepend ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
processingInstructionsname

processingInstructions()

dessIndent
If no argument is passed in then the method returns an XMLList with all the children of the XML 
object which are processing instructions. If an argument is passed in then the method returns an 
XMLList with all children of the XML object which are processing instructions where the name 
matches the argument.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
processingInstructionsname

processingInstructions(name)

dessIndent
If no argument is passed in then the method returns an XMLList with all the children of the XML 
object which are processing instructions. If an argument is passed in then the method returns an 
XMLList with all children of the XML object which are processing instructions where the name 
matches the argument.
prs

Parameters

sIndentname ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
propertyIsEnumerablename

propertyIsEnumerable(propertyName)

dessIndent
Returns true if the property name is '0' and false otherwise.
prs

Parameters

sIndentpropertyName ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
removeNamespacename

removeNamespace(namespace)

dessIndent
Removes the namespace from the in scope namespaces of this XML object if the namespace 
is not used for the qualified name of the object or its attributes.
prs

Parameters

sIndentnamespace ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
replacename

replace(propertyName, replacementValue)

dessIndent
Takes two arguments, the property name of the property / properties to be replaced, and the 
value to replace the properties.
prs

Parameters

sIndentpropertyName ;replacementValue ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
setChildrenname

setChildren(value)

dessIndent
Replaces all children of the XML object with this value. The method returns the XML object it 
is called on.
prs

Parameters

sIndentvalue ;
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
setLocalNamename

setLocalName(name)

dessIndent
Changes the local name of this XML object to the name passed in.
prs

Parameters

sIndentname ;
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
setNamename

setName(name)

dessIndent
Replaces the name of this XML object with the name passed in.
prs

Parameters

sIndentname ;
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
setNamespacename

setNamespace(namespace)

dessIndent
Changes the namespace associated with the name of this XML object to the new namespace.
prs

Parameters

sIndentnamespace ;
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
setSettingsname

setSettings()

dessIndent
Allows the global XML settings to be adjusted or restored to their default values.
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
setSettingsname

setSettings(settings)

dessIndent
Allows the global XML settings to be adjusted or restored to their default values.
prs

Parameters

sIndentsettingsThe new settings that should be applied globally to the XML object.
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
settingsname

settings()

dessIndent
Returns an object containing the global XML settings.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
textname

text()

dessIndent
Returns an XMLList with all the children of this XML object that represent text nodes.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
toStringname

toString()

dessIndent
Returns a convenient string value of this XML object.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
toXMLStringname

toXMLString()

dessIndent
Returns a string with the serialized XML markup for this XML object. XML.prettyPrinting 
and XML.prettyIndent settings affect the returned string.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow
valueOfname

valueOf()

dessIndent
The method simply returns the XML object it is called on.
ret

Returns

sIndent
clients

Supported Clients

sIndentSmartClient,WebClient,NGClient
sam

Sample

sIdentjavascript
lastDetailRow