public class FilteredCollection extends AbstractCollection implements Serializable
Collection which presents a filtered view of
another.| Constructor and Description |
|---|
FilteredCollection(Collection delegate,
org.apache.commons.collections.Predicate predicate)
Creates a new
FilteredCollection. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(Object object) |
boolean |
contains(Object object) |
boolean |
isEmpty() |
Iterator |
iterator()
Returns an
Iterator over the elements of this
Collection. |
boolean |
remove(Object object) |
int |
size() |
addAll, clear, containsAll, removeAll, retainAll, toArray, toArray, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitequals, hashCodepublic FilteredCollection(Collection delegate, org.apache.commons.collections.Predicate predicate)
FilteredCollection. If a
null Predicate is passed to this
constructor, TruePredicate is used internally.public int size()
size in interface Collectionsize in class AbstractCollectionpublic boolean isEmpty()
isEmpty in interface CollectionisEmpty in class AbstractCollectionpublic boolean add(Object object)
add in interface Collectionadd in class AbstractCollectionpublic boolean remove(Object object)
remove in interface Collectionremove in class AbstractCollectionpublic boolean contains(Object object)
contains in interface Collectioncontains in class AbstractCollectionpublic Iterator iterator()
Iterator over the elements of this
Collection. If the remove() method
is called after hasNext() without an intervening
call to next(), the last element returned by
next() will be removed by calling Collection.remove( object ) on the
underlying Collection. Depending upon the
underlying Collection implementation, this may
invalidate this Iterator.iterator in interface Iterableiterator in interface Collectioniterator in class AbstractCollectionSee the Plexus project home, hosted by SourceForge.
Copyright ? 1994-2006, by Phoenix Software Technologists, Inc. and others. All Rights Reserved. Use is subject to license terms.