public class DefaultNode extends AbstractNodeWithAttributes
MAP_TYPE_FLYWEIGHT, MAP_TYPE_HASH| Modifier | Constructor and Description |
|---|---|
|
DefaultNode(java.lang.String tag) |
protected |
DefaultNode(java.lang.String tag,
Node parent) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(int idx,
NodeElement child)
Deprecated.
This method was replaced by addElement(int, Object).
|
void |
add(NodeElement child)
Deprecated.
This method was replaced by addElement(Object).
|
void |
addElement(int index,
java.lang.Object e)
Adds a node element at
index to this node. |
void |
addElement(java.lang.Object e)
Adds a node element to this node.
|
java.lang.Object |
clone()
Clones this element.
|
DefaultNode |
createAndAddChild(java.lang.String childNodeName) |
java.util.List<java.lang.Object> |
getElements()
Gets childreen of this node.
|
void |
remove(NodeElement child)
Deprecated.
This method was replaced by removeElement(Object).
|
java.lang.Object |
removeElement(int i)
Removes an element from this node.
|
boolean |
removeElement(java.lang.Object e)
Removes an element from this node.
|
boolean |
replaceElement(java.lang.Object oldElement,
java.lang.Object newElement)
Replaces an element.
|
java.lang.Object |
setElement(int index,
java.lang.Object e)
Replaces a node element at
index of this node. |
doGetAttribute, doSetAttribute, getAttributeMap, getDefaultMapType, getDefinedAttributes, setDefaultMapTypeaddAttributeChangeListener, addElements, addElements, clearEqualAttributes, clearInheratedAttribute, clearInheratedAttributes, clearValue, contains, contains, copyAttributes, createID, findFirstNodeWithText, findNode, findNodesWithText, fire, fireSaxEvents, firstElement, getAttrAsBoolean, getAttrAsInteger, getAttrAsString, getAttrAsString, getAttribute, getAttribute, getAttributeMap, getContentText, getContentText, getDefinedAttributes, getElements, getElements, getElements, getFirstElement, getIndex, getLocalName, getNamespacePrefix, getNamespacePrefixes, getNamespaceURI, getParent, getParent, getParent, getParentOrThis, getQName, getRoot, hasEqualAttrs, indexOf, isEmpty, lastElement, liftInheritedAttribute, removeAttributeChangeListener, setAttribute, setAttributes, setAttrIfNotNull, setEnableAttributeChangeEvent, setNamespace, setParent, setQName, setUndefinedAttributes, writeTo, writeTo, writeTo, writeTopublic DefaultNode(java.lang.String tag)
protected DefaultNode(java.lang.String tag,
Node parent)
public void addElement(java.lang.Object e)
e - Node element.java.lang.UnsupportedOperationException - is throws if no childreen are allowed.java.lang.NullPointerException - is thrown if e==nullpublic void addElement(int index,
java.lang.Object e)
index to this node.index - Index of element.e - Node element.java.lang.IndexOutOfBoundsException - is thrown if index is out of bounds.java.lang.UnsupportedOperationException - is throws if no childreen are allowed.java.lang.NullPointerException - is thrown if e==nullpublic java.lang.Object setElement(int index,
java.lang.Object e)
index of this node.index - Index of element.e - Node element.java.lang.IndexOutOfBoundsException - is thrown if index is out of bounds.java.lang.UnsupportedOperationException - is throws if no childreen are allowed.java.lang.NullPointerException - is thrown if e==nullpublic boolean removeElement(java.lang.Object e)
e - NodeElementpublic java.lang.Object removeElement(int i)
i - Index of element.java.lang.IndexOutOfBoundsException - is thrown if index is out of bounds.public boolean replaceElement(java.lang.Object oldElement,
java.lang.Object newElement)
oldElement - Old element.newElement - New element.true if this node contained oldElementpublic void add(NodeElement child)
child - Child.public void add(int idx,
NodeElement child)
idx - Index (starting at 0)child - Child.public void remove(NodeElement child)
child - Child.public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
NodeElementclone in interface NodeElementclone in class AbstractNodeWithAttributesjava.lang.CloneNotSupportedExceptionpublic java.util.List<java.lang.Object> getElements()
AbstractNodeNodeElement or String.getElements in interface NodegetElements in class AbstractNodepublic DefaultNode createAndAddChild(java.lang.String childNodeName)
© 2003-2011 by Sascha Schmidt (vision-cloud.de). All Rights Reserved.