org.apache.commons.collections.BoundedCollection |
Known Indirect Subclasses
BoundedBuffer |
Decorates another Buffer to ensure a fixed maximum size. |
BoundedFifoBuffer |
This class is deprecated.
Moved to buffer subpackage. Due to be removed in v4.0. |
CircularFifoBuffer |
CircularFifoBuffer is a first in first out buffer with a fixed size that
replaces its oldest element if full. |
FixedSizeList |
Decorates another List to fix the size preventing add/remove. |
UnmodifiableBoundedCollection |
UnmodifiableBoundedCollection decorates another
BoundedCollection to ensure it can't be altered. |
|
Class Overview
Defines a collection that is bounded in size.
The size of the collection can vary, but it can never exceed a preset
maximum number of elements. This interface allows the querying of details
associated with the maximum number of elements.
Summary
Public Methods |
abstract
boolean
|
isFull()
Returns true if this collection is full and no new elements can be added.
|
abstract
int
|
maxSize()
Gets the maximum size of the collection (the bound).
|
[Expand]
Inherited Methods |
From interface
java.lang.Iterable
|
From interface
java.util.Collection
abstract
boolean
|
add(E arg0)
|
abstract
boolean
|
addAll(Collection<? extends E> arg0)
|
abstract
void
|
clear()
|
abstract
boolean
|
contains(Object arg0)
|
abstract
boolean
|
containsAll(Collection<?> arg0)
|
abstract
boolean
|
equals(Object arg0)
|
abstract
int
|
hashCode()
|
abstract
boolean
|
isEmpty()
|
abstract
Iterator<E>
|
iterator()
|
abstract
boolean
|
remove(Object arg0)
|
abstract
boolean
|
removeAll(Collection<?> arg0)
|
abstract
boolean
|
retainAll(Collection<?> arg0)
|
abstract
int
|
size()
|
abstract
<T>
T[]
|
toArray(T[] arg0)
|
abstract
Object[]
|
toArray()
|
|
Public Methods
public
abstract
boolean
isFull
()
Returns true if this collection is full and no new elements can be added.
Returns
true
if the collection is full
public
abstract
int
maxSize
()
Gets the maximum size of the collection (the bound).
Returns
- the maximum number of elements the collection can hold