org.attoparser.markup.dom.impl
Class AbstractNestableNode

Object
  extended by org.attoparser.markup.dom.impl.AbstractNode
      extended by org.attoparser.markup.dom.impl.AbstractNestableNode
All Implemented Interfaces:
INestableNode, INode
Direct Known Subclasses:
Document, Element

public abstract class AbstractNestableNode
extends AbstractNode
implements INestableNode

Abstract base class for all implementation of INestableNode.

Since:
1.1
Author:
Daniel Fernández

Constructor Summary
protected AbstractNestableNode()
           
 
Method Summary
 void addChild(INode newChild)
           
 void clearChildren()
           
 List<INode> getChildren()
           
<T extends INode>
List<T>
getChildrenOfType(Class<T> type)
           
 INode getFirstChild()
           
<T extends INode>
T
getFirstChildOfType(Class<T> type)
           
 boolean hasChildren()
           
 void insertChild(int index, INode newChild)
           
 void insertChildAfter(INode after, INode newChild)
           
 void insertChildBefore(INode before, INode newChild)
           
 int numChildren()
           
 void removeChild(INode child)
           
 
Methods inherited from class org.attoparser.markup.dom.impl.AbstractNode
getCol, getLine, getParent, hasCol, hasLine, hasParent, setCol, setLine, setParent
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.attoparser.markup.dom.INode
cloneNode, getCol, getLine, getParent, hasCol, hasLine, hasParent, setCol, setLine, setParent
 

Constructor Detail

AbstractNestableNode

protected AbstractNestableNode()
Method Detail

hasChildren

public boolean hasChildren()
Specified by:
hasChildren in interface INestableNode

numChildren

public int numChildren()
Specified by:
numChildren in interface INestableNode

getChildren

public List<INode> getChildren()
Specified by:
getChildren in interface INestableNode

getChildrenOfType

public <T extends INode> List<T> getChildrenOfType(Class<T> type)
Specified by:
getChildrenOfType in interface INestableNode

getFirstChild

public INode getFirstChild()
Specified by:
getFirstChild in interface INestableNode

getFirstChildOfType

public <T extends INode> T getFirstChildOfType(Class<T> type)
Specified by:
getFirstChildOfType in interface INestableNode

addChild

public void addChild(INode newChild)
Specified by:
addChild in interface INestableNode

insertChild

public final void insertChild(int index,
                              INode newChild)
Specified by:
insertChild in interface INestableNode

insertChildBefore

public final void insertChildBefore(INode before,
                                    INode newChild)
Specified by:
insertChildBefore in interface INestableNode

insertChildAfter

public final void insertChildAfter(INode after,
                                   INode newChild)
Specified by:
insertChildAfter in interface INestableNode

removeChild

public final void removeChild(INode child)
Specified by:
removeChild in interface INestableNode

clearChildren

public final void clearChildren()
Specified by:
clearChildren in interface INestableNode


Copyright © 2013 The ATTOPARSER team. All Rights Reserved.