| Constructor and Description |
|---|
NodeSet()
Construct a new empty NodeSet
|
NodeSet(Element node)
Construct a new NodeSet which contains the given element.
|
| Modifier and Type | Method and Description |
|---|---|
Element |
findMember(Element x)
Searches for an element in this NodeSet.
|
Element |
first() |
NodeSet |
get(java.lang.String pathStr)
'Get' using path expression on nodes within the set.
|
Element |
getElement(int index)
Gets an element from the node set.
|
Element |
getFirst(java.lang.String pathStr)
'Get' using path expression on nodes within the set.
|
boolean |
isMember(Element x)
Checks if an element is a member of the NodeSet.
|
Element |
last() |
boolean |
removeMember(Element x)
Removes a member element from the NodeSet.
|
java.lang.String |
toXMLString()
Formats the NodeSet in XML format.
|
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, forEach, get, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeIf, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSizepublic NodeSet(Element node)
public NodeSet()
public Element getElement(int index)
public NodeSet get(java.lang.String pathStr) throws JNCException
pathStr - Path string to find nodes within the nodesJNCExceptionpublic Element getFirst(java.lang.String pathStr) throws JNCException
pathStr - Path string to find an element within the nodesJNCExceptionpublic Element first()
public Element last()
public boolean isMember(Element x)
Element.equals method.x - Element to check forpublic Element findMember(Element x)
Element.equals method.x - Element to findpublic boolean removeMember(Element x)
Element.equals method.x - Removes an element equals to element x.true if member was removed. false if not found.public java.lang.String toXMLString()