Package org.attoparser.dom
Class AbstractNestableNode
- java.lang.Object
-
- org.attoparser.dom.AbstractNode
-
- org.attoparser.dom.AbstractNestableNode
-
- All Implemented Interfaces:
INestableNode,INode
abstract class AbstractNestableNode extends AbstractNode implements INestableNode
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.List<INode>childrenprivate intchildrenLen
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractNestableNode()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddChild(INode newChild)voidclearChildren()java.util.List<INode>getChildren()<T extends INode>
java.util.List<T>getChildrenOfType(java.lang.Class<T> type)INodegetFirstChild()<T extends INode>
TgetFirstChildOfType(java.lang.Class<T> type)booleanhasChildren()voidinsertChild(int index, INode newChild)voidinsertChildAfter(INode after, INode newChild)voidinsertChildBefore(INode before, INode newChild)intnumChildren()voidremoveChild(INode child)-
Methods inherited from class org.attoparser.dom.AbstractNode
getCol, getLine, getParent, hasCol, hasLine, hasParent, setCol, setLine, setParent
-
-
-
-
Field Detail
-
children
private java.util.List<INode> children
-
childrenLen
private int childrenLen
-
-
Method Detail
-
hasChildren
public boolean hasChildren()
- Specified by:
hasChildrenin interfaceINestableNode
-
numChildren
public int numChildren()
- Specified by:
numChildrenin interfaceINestableNode
-
getChildren
public java.util.List<INode> getChildren()
- Specified by:
getChildrenin interfaceINestableNode
-
getChildrenOfType
public <T extends INode> java.util.List<T> getChildrenOfType(java.lang.Class<T> type)
- Specified by:
getChildrenOfTypein interfaceINestableNode
-
getFirstChild
public INode getFirstChild()
- Specified by:
getFirstChildin interfaceINestableNode
-
getFirstChildOfType
public <T extends INode> T getFirstChildOfType(java.lang.Class<T> type)
- Specified by:
getFirstChildOfTypein interfaceINestableNode
-
addChild
public void addChild(INode newChild)
- Specified by:
addChildin interfaceINestableNode
-
insertChild
public final void insertChild(int index, INode newChild)- Specified by:
insertChildin interfaceINestableNode
-
insertChildBefore
public final void insertChildBefore(INode before, INode newChild)
- Specified by:
insertChildBeforein interfaceINestableNode
-
insertChildAfter
public final void insertChildAfter(INode after, INode newChild)
- Specified by:
insertChildAfterin interfaceINestableNode
-
removeChild
public final void removeChild(INode child)
- Specified by:
removeChildin interfaceINestableNode
-
clearChildren
public final void clearChildren()
- Specified by:
clearChildrenin interfaceINestableNode
-
-