|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.AbstractCollection<T>
edu.rice.cs.plt.collect.ImmutableCollection<T>
edu.rice.cs.plt.collect.ImmutableSet<T>
public class ImmutableSet<T>
Wraps a set in an immutable interface. Similar to Collections.unmodifiableSet(java.util.Set extends T>),
but this class also implements PredicateSet and allows subclassing.
Subclasses can invoke the overridden methods in AbstractCollection to use the
default implementations there by invoking, for example, ImmutableCollection.abstractCollectionAddAll(java.util.Collection extends T>)
(see AbstractCollection for details on the default implementations).
| Field Summary |
|---|
| Fields inherited from class edu.rice.cs.plt.collect.ImmutableCollection |
|---|
_delegate |
| Constructor Summary | |
|---|---|
ImmutableSet(java.util.Set<? extends T> set)
|
|
| Method Summary | ||
|---|---|---|
boolean |
equals(java.lang.Object o)
|
|
int |
hashCode()
|
|
static
|
make(java.util.Set<? extends T> set)
Call the constructor (allows T to be inferred). |
|
| Methods inherited from class edu.rice.cs.plt.collect.ImmutableCollection |
|---|
abstractCollectionAddAll, abstractCollectionClear, abstractCollectionContains, abstractCollectionContainsAll, abstractCollectionIsEmpty, abstractCollectionRemove, abstractCollectionRemoveAll, abstractCollectionRetainAll, abstractCollectionToArray, abstractCollectionToArray, add, addAll, clear, compositeHeight, compositeSize, contains, containsAll, hasFixedSize, isEmpty, isInfinite, isStatic, iterator, make, remove, removeAll, retainAll, size, size, toArray, toArray, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.Set |
|---|
add, addAll, clear, contains, containsAll, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray |
| Methods inherited from interface edu.rice.cs.plt.lambda.Predicate |
|---|
contains |
| Methods inherited from interface edu.rice.cs.plt.iter.SizedIterable |
|---|
hasFixedSize, isEmpty, isInfinite, isStatic, size, size |
| Constructor Detail |
|---|
public ImmutableSet(java.util.Set<? extends T> set)
| Method Detail |
|---|
public boolean equals(java.lang.Object o)
equals in interface java.util.Collection<T>equals in interface java.util.Set<T>equals in class java.lang.Objectpublic int hashCode()
hashCode in interface java.util.Collection<T>hashCode in interface java.util.Set<T>hashCode in class java.lang.Objectpublic static <T> ImmutableSet<T> make(java.util.Set<? extends T> set)
T to be inferred).
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||