Package org.apache.batik.dom
Class AbstractParentNode.ChildNodes
- java.lang.Object
-
- org.apache.batik.dom.AbstractParentNode.ChildNodes
-
- All Implemented Interfaces:
java.io.Serializable,org.w3c.dom.NodeList
- Enclosing class:
- AbstractParentNode
protected class AbstractParentNode.ChildNodes extends java.lang.Object implements org.w3c.dom.NodeList, java.io.SerializableTo manage the children of this node.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected intchildrenThe number of children.protected intelementChildrenThe number of Element children.protected ExtendedNodefirstChildThe first child.protected ExtendedNodelastChildThe last child.
-
Constructor Summary
Constructors Constructor Description ChildNodes()Creates a new ChildNodes object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ExtendedNodeappend(ExtendedNode n)Appends a node to the tree.intgetLength()DOM: ImplementsNodeList.getLength().ExtendedNodeinsert(ExtendedNode n, ExtendedNode r)Inserts a node in the tree.org.w3c.dom.Nodeitem(int index)DOM: ImplementsNodeList.item(int).ExtendedNoderemove(ExtendedNode n)Removes the given node from the tree.ExtendedNodereplace(ExtendedNode n, ExtendedNode o)Replaces a node in the tree by an other.
-
-
-
Field Detail
-
firstChild
protected ExtendedNode firstChild
The first child.
-
lastChild
protected ExtendedNode lastChild
The last child.
-
children
protected int children
The number of children.
-
elementChildren
protected int elementChildren
The number of Element children.
-
-
Method Detail
-
item
public org.w3c.dom.Node item(int index)
DOM: ImplementsNodeList.item(int).- Specified by:
itemin interfaceorg.w3c.dom.NodeList
-
getLength
public int getLength()
DOM: ImplementsNodeList.getLength().- Specified by:
getLengthin interfaceorg.w3c.dom.NodeList- Returns:
children.
-
append
public ExtendedNode append(ExtendedNode n)
Appends a node to the tree. The node is assumed not to be a DocumentFragment instance.
-
insert
public ExtendedNode insert(ExtendedNode n, ExtendedNode r)
Inserts a node in the tree.
-
replace
public ExtendedNode replace(ExtendedNode n, ExtendedNode o)
Replaces a node in the tree by an other.
-
remove
public ExtendedNode remove(ExtendedNode n)
Removes the given node from the tree.
-
-