public class QNameSet
extends java.lang.Object
| Modifier | Constructor and Description |
|---|---|
|
QNameSet()
Constructor.
|
|
QNameSet(int initialCapacity)
Constructor.
|
|
QNameSet(QName qn)
Constructor, adds qualified name element.
|
protected |
QNameSet(QName[] qns) |
|
QNameSet(QNameSet set)
Copy Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(QName qn)
Adds a QualifiedName to this QualifiedNameSet.
|
void |
addAll(QNameSet qnsNewQNames)
Adds a QualifiedName to this QualifiedNameSet.
|
static QNameSet |
construct(java.lang.String nsAndTypes)
Constructs a QNameSet from a String containing namespaces and types.
|
boolean |
contains(QName qn)
Returns true if this qualified name set contains the specified element.
|
boolean |
containsAll(QNameSet qnames)
Checks if this contains the given QNameSet.
|
boolean |
equals(java.lang.Object obj)
Compares this qualified name data structure to the specified object.
|
int |
hashCode() |
boolean |
isEmpty()
Returns if data structure is empty.
|
boolean |
isReadOnly()
Checks if the QNameSet must not be changed anymore
|
Iterator |
iterator()
Gets Iterator
|
static QNameSet |
newInstance(Set qnames)
Creates instance of a QNameSet from a Set containing QNames.
|
static QNameSet |
newInstanceReadOnly(Set qnames)
Creates instance of QNameSet by wrapping a set of qnames.
|
boolean |
remove(QName qn)
Removes a QualifiedName from this QualifiedNameSet.
|
void |
setReadOnly()
Sets this QualifiedNameSet to readOnly.
|
int |
size()
Returns size of list.
|
static QNameSet |
sortPriorities(QNameSet qnames)
Simple bubble sort for
QNameSet. |
static QName[] |
sortPrioritiesAsArray(QNameSet qnames)
Simple bubble sort for
QNameSet. |
QName[] |
toArray()
Gets copied entries of data structure as array.
|
java.lang.String |
toString() |
public QNameSet()
public QNameSet(int initialCapacity)
public QNameSet(QName qn)
qn - QualifiedName element to be added to new QualifiedNameSetpublic QNameSet(QNameSet set)
protected QNameSet(QName[] qns)
public static QNameSet newInstanceReadOnly(Set qnames)
qnames - set of qnamespublic static QNameSet newInstance(Set qnames)
qnames - Set of QNamespublic static QNameSet construct(java.lang.String nsAndTypes)
nsAndTypes - String with list of namespace + '/' + local part elements divided by ' '.public static QName[] sortPrioritiesAsArray(QNameSet qnames)
qnames - the set of qualified of to sort.public static QNameSet sortPriorities(QNameSet qnames)
qnames - the set of qualified of to sort.public QName[] toArray()
public Iterator iterator()
DataStructure.iterator()public boolean contains(QName qn)
qn - QualifiedName whose presence in the qualified name set is checkedtrue if the argument is a component of this QNameSet; false otherwise.public boolean containsAll(QNameSet qnames)
qnames - Qualified Names which must all be included.true if all qnames are included, false otherwise.public int size()
List.size()public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectobj - the Object to compare this qualified name data structure against.public int hashCode()
hashCode in class java.lang.Objectpublic boolean isReadOnly()
true if it must not be changed.public boolean isEmpty()
true if data structure is empty, false otherwise.public void add(QName qn) throws UnsupportedOperationException
qn - The QualifiedName to be added.UnsupportedOperationExceptionList.add(Object)public void addAll(QNameSet qnsNewQNames)
qnsNewQNames - public boolean remove(QName qn) throws UnsupportedOperationException
qn - The QualifiedName to be removed.true if the argument was a component of this QualifiedNameSet; false
otherwise.UnsupportedOperationExceptionDataStructure.remove(Object)public void setReadOnly()