public class FilteredCollection<T,S extends T> extends Object implements Collection<S>
| Modifier and Type | Class and Description |
|---|---|
protected static class |
FilteredCollection.FilteringIterator<T,S extends T> |
| Modifier and Type | Field and Description |
|---|---|
protected Collection<T> |
collection |
protected CollectionFilter<S> |
filter |
| Constructor and Description |
|---|
FilteredCollection(Collection<T> collection,
CollectionFilter<S> filter) |
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
accept(Object o) |
boolean |
add(S o) |
boolean |
addAll(Collection<? extends S> c) |
void |
clear() |
boolean |
contains(Object o) |
boolean |
containsAll(Collection<?> c) |
boolean |
isEmpty() |
Iterator<S> |
iterator() |
boolean |
remove(Object o) |
boolean |
removeAll(Collection<?> c) |
boolean |
retainAll(Collection<?> c) |
int |
size() |
Object[] |
toArray() |
<T> T[] |
toArray(T[] a) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequals, hashCodeprotected final Collection<T> collection
protected final CollectionFilter<S extends T> filter
public FilteredCollection(Collection<T> collection, CollectionFilter<S> filter)
public boolean add(S o)
add in interface Collection<S extends T>public boolean addAll(Collection<? extends S> c)
addAll in interface Collection<S extends T>public void clear()
clear in interface Collection<S extends T>protected boolean accept(Object o)
public boolean contains(Object o)
contains in interface Collection<S extends T>public boolean containsAll(Collection<?> c)
containsAll in interface Collection<S extends T>public boolean isEmpty()
isEmpty in interface Collection<S extends T>public boolean remove(Object o)
remove in interface Collection<S extends T>public boolean removeAll(Collection<?> c)
removeAll in interface Collection<S extends T>public boolean retainAll(Collection<?> c)
retainAll in interface Collection<S extends T>public int size()
size in interface Collection<S extends T>public Object[] toArray()
toArray in interface Collection<S extends T>public <T> T[] toArray(T[] a)
toArray in interface Collection<S extends T>Copyright © 2013. All rights reserved