Package | Description |
---|---|
org.apache.commons.collections |
This package contains the interfaces and utilities shared across all the subpackages of this component.
|
org.apache.commons.collections.buffer |
This package contains implementations of the
Buffer interface. |
Modifier and Type | Class | Description |
---|---|---|
class |
ArrayStack |
An implementation of the
Stack API that is based on an
ArrayList instead of a Vector , so it is not
synchronized to protect against multi-threaded access. |
class |
BinaryHeap |
Deprecated.
Replaced by PriorityBuffer in buffer subpackage.
|
class |
BoundedFifoBuffer |
Deprecated.
Moved to buffer subpackage.
|
class |
UnboundedFifoBuffer |
Deprecated.
Moved to buffer subpackage.
|
Modifier and Type | Field | Description |
---|---|---|
static Buffer |
BufferUtils.EMPTY_BUFFER |
An empty unmodifiable buffer.
|
Modifier and Type | Method | Description |
---|---|---|
static Buffer |
BufferUtils.blockingBuffer(Buffer buffer) |
|
static Buffer |
BufferUtils.blockingBuffer(Buffer buffer,
long timeoutMillis) |
|
static Buffer |
BufferUtils.boundedBuffer(Buffer buffer,
int maximumSize) |
Returns a synchronized buffer backed by the given buffer that will
block on
Collection.add(Object) and
Collection.addAll(java.util.Collection) until enough object(s) are
removed from the buffer to allow the object(s) to be added and still
maintain the maximum size. |
static Buffer |
BufferUtils.boundedBuffer(Buffer buffer,
int maximumSize,
long timeoutMillis) |
Returns a synchronized buffer backed by the given buffer that will
block on
Collection.add(Object) and
Collection.addAll(java.util.Collection) until enough object(s) are
removed from the buffer to allow the object(s) to be added and still
maintain the maximum size or the timeout expires. |
static Buffer |
BufferUtils.predicatedBuffer(Buffer buffer,
Predicate predicate) |
Returns a predicated (validating) buffer backed by the given buffer.
|
static Buffer |
BufferUtils.synchronizedBuffer(Buffer buffer) |
Returns a synchronized buffer backed by the given buffer.
|
static Buffer |
BufferUtils.transformedBuffer(Buffer buffer,
Transformer transformer) |
Returns a transformed buffer backed by the given buffer.
|
static Buffer |
BufferUtils.typedBuffer(Buffer buffer,
java.lang.Class type) |
Returns a typed buffer backed by the given buffer.
|
static Buffer |
BufferUtils.unmodifiableBuffer(Buffer buffer) |
Returns an unmodifiable buffer backed by the given buffer.
|
Modifier and Type | Method | Description |
---|---|---|
static Buffer |
BufferUtils.blockingBuffer(Buffer buffer) |
|
static Buffer |
BufferUtils.blockingBuffer(Buffer buffer,
long timeoutMillis) |
|
static Buffer |
BufferUtils.boundedBuffer(Buffer buffer,
int maximumSize) |
Returns a synchronized buffer backed by the given buffer that will
block on
Collection.add(Object) and
Collection.addAll(java.util.Collection) until enough object(s) are
removed from the buffer to allow the object(s) to be added and still
maintain the maximum size. |
static Buffer |
BufferUtils.boundedBuffer(Buffer buffer,
int maximumSize,
long timeoutMillis) |
Returns a synchronized buffer backed by the given buffer that will
block on
Collection.add(Object) and
Collection.addAll(java.util.Collection) until enough object(s) are
removed from the buffer to allow the object(s) to be added and still
maintain the maximum size or the timeout expires. |
static Buffer |
BufferUtils.predicatedBuffer(Buffer buffer,
Predicate predicate) |
Returns a predicated (validating) buffer backed by the given buffer.
|
static Buffer |
BufferUtils.synchronizedBuffer(Buffer buffer) |
Returns a synchronized buffer backed by the given buffer.
|
static Buffer |
BufferUtils.transformedBuffer(Buffer buffer,
Transformer transformer) |
Returns a transformed buffer backed by the given buffer.
|
static Buffer |
BufferUtils.typedBuffer(Buffer buffer,
java.lang.Class type) |
Returns a typed buffer backed by the given buffer.
|
static Buffer |
BufferUtils.unmodifiableBuffer(Buffer buffer) |
Returns an unmodifiable buffer backed by the given buffer.
|
Modifier and Type | Class | Description |
---|---|---|
class |
AbstractBufferDecorator |
Decorates another
Buffer to provide additional behaviour. |
class |
BlockingBuffer |
Decorates another
Buffer to make BlockingBuffer.get() and
BlockingBuffer.remove() block when the Buffer is empty. |
class |
BoundedBuffer |
Decorates another
Buffer to ensure a fixed maximum size. |
class |
BoundedFifoBuffer |
The BoundedFifoBuffer is a very efficient implementation of
Buffer that is of a fixed size. |
class |
CircularFifoBuffer |
CircularFifoBuffer is a first in first out buffer with a fixed size that
replaces its oldest element if full.
|
class |
PredicatedBuffer |
Decorates another
Buffer to validate that additions
match a specified predicate. |
class |
PriorityBuffer |
Binary heap implementation of
Buffer that provides for
removal based on Comparator ordering. |
class |
SynchronizedBuffer |
Decorates another
Buffer to synchronize its behaviour
for a multi-threaded environment. |
class |
TransformedBuffer |
Decorates another
Buffer to transform objects that are added. |
class |
UnboundedFifoBuffer |
UnboundedFifoBuffer is a very efficient implementation of
Buffer that can grow to any size. |
class |
UnmodifiableBuffer |
Decorates another
Buffer to ensure it can't be altered. |
Modifier and Type | Method | Description |
---|---|---|
static Buffer |
BlockingBuffer.decorate(Buffer buffer) |
Factory method to create a blocking buffer.
|
static Buffer |
BlockingBuffer.decorate(Buffer buffer,
long timeoutMillis) |
Factory method to create a blocking buffer with a timeout value.
|
static Buffer |
PredicatedBuffer.decorate(Buffer buffer,
Predicate predicate) |
Factory method to create a predicated (validating) buffer.
|
static Buffer |
SynchronizedBuffer.decorate(Buffer buffer) |
Factory method to create a synchronized buffer.
|
static Buffer |
TransformedBuffer.decorate(Buffer buffer,
Transformer transformer) |
Factory method to create a transforming buffer.
|
static Buffer |
TypedBuffer.decorate(Buffer buffer,
java.lang.Class type) |
Factory method to create a typed list.
|
static Buffer |
UnmodifiableBuffer.decorate(Buffer buffer) |
Factory method to create an unmodifiable buffer.
|
protected Buffer |
AbstractBufferDecorator.getBuffer() |
Gets the buffer being decorated.
|
protected Buffer |
PredicatedBuffer.getBuffer() |
Gets the buffer being decorated.
|
protected Buffer |
SynchronizedBuffer.getBuffer() |
Gets the buffer being decorated.
|
protected Buffer |
TransformedBuffer.getBuffer() |
Gets the decorated buffer.
|
Modifier and Type | Method | Description |
---|---|---|
static Buffer |
BlockingBuffer.decorate(Buffer buffer) |
Factory method to create a blocking buffer.
|
static Buffer |
BlockingBuffer.decorate(Buffer buffer,
long timeoutMillis) |
Factory method to create a blocking buffer with a timeout value.
|
static BoundedBuffer |
BoundedBuffer.decorate(Buffer buffer,
int maximumSize) |
Factory method to create a bounded buffer.
|
static BoundedBuffer |
BoundedBuffer.decorate(Buffer buffer,
int maximumSize,
long timeout) |
Factory method to create a bounded buffer that blocks for a maximum
amount of time.
|
static Buffer |
PredicatedBuffer.decorate(Buffer buffer,
Predicate predicate) |
Factory method to create a predicated (validating) buffer.
|
static Buffer |
SynchronizedBuffer.decorate(Buffer buffer) |
Factory method to create a synchronized buffer.
|
static Buffer |
TransformedBuffer.decorate(Buffer buffer,
Transformer transformer) |
Factory method to create a transforming buffer.
|
static Buffer |
TypedBuffer.decorate(Buffer buffer,
java.lang.Class type) |
Factory method to create a typed list.
|
static Buffer |
UnmodifiableBuffer.decorate(Buffer buffer) |
Factory method to create an unmodifiable buffer.
|
Constructor | Description |
---|---|
AbstractBufferDecorator(Buffer buffer) |
Constructor that wraps (not copies).
|
BlockingBuffer(Buffer buffer) |
Constructor that wraps (not copies).
|
BlockingBuffer(Buffer buffer,
long timeoutMillis) |
Constructor that wraps (not copies).
|
BoundedBuffer(Buffer buffer,
int maximumSize,
long timeout) |
Constructor that wraps (not copies) another buffer, making it bounded
waiting only up to a maximum amount of time.
|
PredicatedBuffer(Buffer buffer,
Predicate predicate) |
Constructor that wraps (not copies).
|
SynchronizedBuffer(Buffer buffer) |
Constructor that wraps (not copies).
|
SynchronizedBuffer(Buffer buffer,
java.lang.Object lock) |
Constructor that wraps (not copies).
|
TransformedBuffer(Buffer buffer,
Transformer transformer) |
Constructor that wraps (not copies).
|
Copyright © 2001-2017 Apache Software Foundation. All Rights Reserved.