SVXmlNode
Designer Javascript References
A wrapper around a JavaScript XML node object. It has the following functions:
Function | Description | Arguments |
getValue | Returns the value of the node. | None. |
setValue | Sets the value of the node | value — the value to set. |
appendChild | Appends the given node to this node as the last child of this node. | child — the node to attach. This node must be owned by this node's SVXmlDocument, so SVXmlDoucment.importNode might have to be called to incorporate the node into the current SVXmlDocument. |
getNodeType | Returns this node's type. | None. |
getAttribute | Returns the value of the attribute with the given name. | name — the name of the attribute to retrieve. |
setAttribute | Sets the given attribute to the given value. | name — the name of the attribute. value — the value to set. |
removeAttribute | Removes the given attribute. | name — the name of the attribute. |
selectSingleNode | Selects the node starting at this node that resides at the given XPath, or null if no such node exists. | xpath — the XPath used to retrieve the node. |
selectNodes | Returns an array of SVXmlNodes retrieved based on the given XPath, or an empty array if no nodes exist at the given path. | xpath — the XPath used to retrieve the nodes. |
getXPath | Returns this node's XPath in the SVXmlDocument. | None. |
getTagName | Returns this node's tag name. | None. |
getPreviousSibling | Returns the previous SVXmlNode or null if there are no siblings. | None. |
getParentNode | Returns the parent SVXmlNode or null if there is no parent. | None. |
getChildNodes | Returns an array of child SVXmlNodes. | None. |
getAttributes | Returns all attributes in this node. | None. |
cloneNode | Makes a copy of this SVXmlNode and returns it. | deep — whether to recursively copy all descendent nodes of this node. |
insertBefore | Inserts a new node before a given node in the child list. | newNode — the node to insert. beforeNode — the node that the given node should be inserted before. |
getNodeName | Returns the name of the node. | None. |
getFirstChild | Returns the first child SVXmlNode. | None. |
getLastChild | Returns the last child SVXmlNode. | None. |
getNextSibling | Return the next sibling SVXmlNode. | None. |
removeChild | Removes the given node from this node's child list. | node — the node to remove. |