|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.commons.collections15.collection.AbstractCollectionDecorator<E>
org.apache.commons.collections15.collection.AbstractSerializableCollectionDecorator<E>
org.apache.commons.collections15.collection.UnmodifiableBoundedCollection<E>
public final class UnmodifiableBoundedCollection<E>
UnmodifiableBoundedCollection decorates another
BoundedCollection to ensure it can't be altered.
| Field Summary |
|---|
| Fields inherited from class org.apache.commons.collections15.collection.AbstractCollectionDecorator |
|---|
collection |
| Method Summary | ||
|---|---|---|
boolean |
add(E object)
|
|
boolean |
addAll(Collection<? extends E> coll)
|
|
void |
clear()
|
|
static
|
decorate(BoundedCollection<E> coll)
Factory method to create an unmodifiable bounded collection. |
|
static
|
decorateUsing(Collection<E> coll)
Factory method to create an unmodifiable bounded collection. |
|
boolean |
isFull()
Returns true if this collection is full and no new elements can be added. |
|
Iterator<E> |
iterator()
|
|
int |
maxSize()
Gets the maximum size of the collection (the bound). |
|
boolean |
remove(Object object)
|
|
boolean |
removeAll(Collection<?> coll)
|
|
boolean |
retainAll(Collection<?> coll)
|
|
| Methods inherited from class org.apache.commons.collections15.collection.AbstractCollectionDecorator |
|---|
contains, containsAll, equals, getCollection, hashCode, isEmpty, 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.Collection |
|---|
contains, containsAll, equals, hashCode, isEmpty, size, toArray, toArray |
| Method Detail |
|---|
public static <E> BoundedCollection<E> decorate(BoundedCollection<E> coll)
coll - the BoundedCollection to decorate, must not be null
IllegalArgumentException - if bag is nullpublic static <E> BoundedCollection<E> decorateUsing(Collection<E> coll)
coll - the BoundedCollection to decorate, must not be null
IllegalArgumentException - if bag is nullpublic Iterator<E> iterator()
iterator in interface Iterable<E>iterator in interface Collection<E>iterator in class AbstractCollectionDecorator<E>public boolean add(E object)
add in interface Collection<E>add in class AbstractCollectionDecorator<E>public boolean addAll(Collection<? extends E> coll)
addAll in interface Collection<E>addAll in class AbstractCollectionDecorator<E>public void clear()
clear in interface Collection<E>clear in class AbstractCollectionDecorator<E>public boolean remove(Object object)
remove in interface Collection<E>remove in class AbstractCollectionDecorator<E>public boolean removeAll(Collection<?> coll)
removeAll in interface Collection<E>removeAll in class AbstractCollectionDecorator<E>public boolean retainAll(Collection<?> coll)
retainAll in interface Collection<E>retainAll in class AbstractCollectionDecorator<E>public boolean isFull()
BoundedCollection
isFull in interface BoundedCollection<E>true if the collection is fullpublic int maxSize()
BoundedCollection
maxSize in interface BoundedCollection<E>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||