public class CompositeCollection extends AbstractCollection implements Serializable
Collection
view of a number of other
Collections
. New elements are added to the last
Collection
and elements are removed from the first
Collection
in which they are found.Constructor and Description |
---|
CompositeCollection(Collection collections)
Creates a new
CompositeCollection . |
CompositeCollection(Collection[] collections)
Creates a new
CompositeCollection . |
CompositeCollection(Collection first,
Collection second)
Creates a new
CompositeCollection . |
Modifier and Type | Method and Description |
---|---|
boolean |
add(Object object) |
boolean |
addAll(Collection collection) |
void |
clear() |
boolean |
contains(Object object) |
List |
getOperands()
Returns an unmodifiable
List of the argument
Collections being used by this
CollectionChain . |
boolean |
isEmpty() |
Iterator |
iterator() |
boolean |
remove(Object object) |
boolean |
removeAll(Collection collection) |
boolean |
retainAll(Collection collection) |
int |
size() |
containsAll, toArray, toArray, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
equals, hashCode
public CompositeCollection(Collection[] collections)
CompositeCollection
.public CompositeCollection(Collection collections)
CompositeCollection
.public CompositeCollection(Collection first, Collection second)
CompositeCollection
.public int size()
size
in interface Collection
size
in class AbstractCollection
public boolean isEmpty()
isEmpty
in interface Collection
isEmpty
in class AbstractCollection
public boolean add(Object object)
add
in interface Collection
add
in class AbstractCollection
public boolean remove(Object object)
remove
in interface Collection
remove
in class AbstractCollection
public boolean contains(Object object)
contains
in interface Collection
contains
in class AbstractCollection
public Iterator iterator()
iterator
in interface Iterable
iterator
in interface Collection
iterator
in class AbstractCollection
public boolean addAll(Collection collection)
addAll
in interface Collection
addAll
in class AbstractCollection
public boolean removeAll(Collection collection)
removeAll
in interface Collection
removeAll
in class AbstractCollection
public boolean retainAll(Collection collection)
retainAll
in interface Collection
retainAll
in class AbstractCollection
public void clear()
clear
in interface Collection
clear
in class AbstractCollection
public List getOperands()
List
of the argument
Collections
being used by this
CollectionChain
.See 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.