|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.shotoku.NodeList
public class NodeList
A class representing a list of nodes and providing the possibility to manipulate these nodes.
Constructor Summary | |
---|---|
NodeList()
|
|
NodeList(java.util.List<Node> nodeList)
|
Method Summary | ||
---|---|---|
boolean |
add(Node node)
Adds the given node to the node list. |
|
boolean |
addAll(java.util.Collection<? extends Node> c)
|
|
void |
addAll(NodeList list)
Adds nodes from the given node list to this node list. |
|
void |
clear()
|
|
boolean |
contains(java.lang.Object o)
|
|
boolean |
containsAll(java.util.Collection<?> c)
|
|
Node |
get(int i)
Gets the i-th element of the list. |
|
boolean |
isEmpty()
|
|
java.util.Iterator<Node> |
iterator()
|
|
void |
limit(int limit)
Limits the size of this node list. |
|
boolean |
remove(java.lang.Object o)
|
|
boolean |
removeAll(java.util.Collection<?> c)
|
|
boolean |
retainAll(java.util.Collection<?> c)
|
|
int |
size()
|
|
void |
sort(java.util.Comparator<Node> comparator)
Sorts this node list with the given comparator. |
|
java.lang.Object[] |
toArray()
|
|
|
toArray(T[] a)
|
|
java.util.List<Node> |
toList()
Gets an immutable java.util.List representation of this
node list. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface java.util.Collection |
---|
equals, hashCode |
Constructor Detail |
---|
public NodeList()
public NodeList(java.util.List<Node> nodeList)
Method Detail |
---|
public boolean add(Node node)
add
in interface java.util.Collection<Node>
node
- Node to add.public void addAll(NodeList list)
list
- Node list to add.public void sort(java.util.Comparator<Node> comparator)
comparator
- Comparator to sort with.public java.util.List<Node> toList()
java.util.List
representation of this
node list.
java.util.List
representation of
this node list.public void limit(int limit)
limit
- Node count limit.public Node get(int i)
i
- Index of the element to get.
public java.util.Iterator<Node> iterator()
iterator
in interface java.lang.Iterable<Node>
iterator
in interface java.util.Collection<Node>
public int size()
size
in interface java.util.Collection<Node>
public boolean isEmpty()
isEmpty
in interface java.util.Collection<Node>
public boolean contains(java.lang.Object o)
contains
in interface java.util.Collection<Node>
public java.lang.Object[] toArray()
toArray
in interface java.util.Collection<Node>
public <T> T[] toArray(T[] a)
toArray
in interface java.util.Collection<Node>
public boolean remove(java.lang.Object o)
remove
in interface java.util.Collection<Node>
public boolean containsAll(java.util.Collection<?> c)
containsAll
in interface java.util.Collection<Node>
public boolean addAll(java.util.Collection<? extends Node> c)
addAll
in interface java.util.Collection<Node>
public boolean removeAll(java.util.Collection<?> c)
removeAll
in interface java.util.Collection<Node>
public boolean retainAll(java.util.Collection<?> c)
retainAll
in interface java.util.Collection<Node>
public void clear()
clear
in interface java.util.Collection<Node>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |