|
![]() |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.AbstractCollection<E>
java.util.AbstractSet<E>
net.ontopia.utils.CompactHashSet<E>
net.ontopia.utils.UniqueSet<E>
public class UniqueSet<E>
INTERNAL:
Constructor Summary | |
---|---|
UniqueSet()
|
|
UniqueSet(java.util.Collection<E> c)
|
|
UniqueSet(int size)
|
|
UniqueSet(UniqueSet<E> s)
|
|
UniqueSet(UniqueSet<E> s1,
UniqueSet<E> s2)
|
Method Summary | |
---|---|
boolean |
add(java.lang.Object o)
Adds the specified element to this set if it is not already present. |
UniqueSet<E> |
add(UniqueSet<E> set,
java.lang.Object o,
boolean dereference)
|
boolean |
addAll(java.util.Collection<? extends E> coll)
|
void |
clear()
Removes all of the elements from this set. |
void |
dereference(UniqueSet<E> set)
|
void |
dump()
INTERNAL: Used for debugging only. |
UniqueSet<E> |
get(java.util.Set<E> set)
INTERNAL: Get the internal representation of a given set. |
int |
getReferenceCount()
|
int |
hashCode()
|
boolean |
remove(java.lang.Object o)
Removes the specified element from the set. |
UniqueSet<E> |
remove(UniqueSet<E> set,
java.lang.Object o,
boolean dereference)
|
boolean |
removeAll(java.util.Collection<?> coll)
|
boolean |
retainAll(java.util.Collection<?> coll)
|
java.lang.String |
toString()
|
Methods inherited from class net.ontopia.utils.CompactHashSet |
---|
contains, isEmpty, iterator, size, toArray, toArray |
Methods inherited from class java.util.AbstractSet |
---|
equals |
Methods inherited from class java.util.AbstractCollection |
---|
containsAll |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.Set |
---|
containsAll |
Constructor Detail |
---|
public UniqueSet()
public UniqueSet(int size)
public UniqueSet(java.util.Collection<E> c)
public UniqueSet(UniqueSet<E> s)
public UniqueSet(UniqueSet<E> s1, UniqueSet<E> s2)
Method Detail |
---|
public int getReferenceCount()
public UniqueSet<E> get(java.util.Set<E> set)
public void dereference(UniqueSet<E> set)
public UniqueSet<E> add(UniqueSet<E> set, java.lang.Object o, boolean dereference)
public UniqueSet<E> remove(UniqueSet<E> set, java.lang.Object o, boolean dereference)
public void dump()
CompactHashSet
dump
in class CompactHashSet<E>
public boolean add(java.lang.Object o)
CompactHashSet
add
in interface java.util.Collection<E>
add
in interface java.util.Set<E>
add
in class CompactHashSet<E>
o
- element to be added to this set.
public boolean remove(java.lang.Object o)
CompactHashSet
remove
in interface java.util.Collection<E>
remove
in interface java.util.Set<E>
remove
in class CompactHashSet<E>
public boolean addAll(java.util.Collection<? extends E> coll)
addAll
in interface java.util.Collection<E>
addAll
in interface java.util.Set<E>
addAll
in class java.util.AbstractCollection<E>
public boolean removeAll(java.util.Collection<?> coll)
removeAll
in interface java.util.Collection<E>
removeAll
in interface java.util.Set<E>
removeAll
in class java.util.AbstractSet<E>
public boolean retainAll(java.util.Collection<?> coll)
retainAll
in interface java.util.Collection<E>
retainAll
in interface java.util.Set<E>
retainAll
in class java.util.AbstractCollection<E>
public void clear()
CompactHashSet
clear
in interface java.util.Collection<E>
clear
in interface java.util.Set<E>
clear
in class CompactHashSet<E>
public java.lang.String toString()
toString
in class java.util.AbstractCollection<E>
public int hashCode()
hashCode
in interface java.util.Collection<E>
hashCode
in interface java.util.Set<E>
hashCode
in class java.util.AbstractSet<E>
|
![]() |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |