java.lang.Object
|
+--org.apache.commons.collections.collection.AbstractCollectionDecorator
|
+--org.apache.commons.collections.collection.PredicatedCollection
|
+--org.apache.commons.collections.buffer.PredicatedBuffer
All Implemented Interfaces:PredicatedBuffer(Buffer buffer, Predicate predicate) Constructor that wraps (not copies). |
static Buffer | decorate(Buffer buffer, Predicate predicate) Factory method to create a predicated (validating) buffer. |
Object | get() |
Gets the buffer being decorated. | |
Object | remove() |
protected PredicatedBuffer(Buffer buffer, Predicate predicate)
- if buffer or predicate is null - if the buffer contains invalid elementspublic static Buffer decorate(Buffer buffer, Predicate predicate)
- if buffer or predicate is null - if the buffer contains invalid elementspublic Object get()
protected Buffer getBuffer()
public Object remove()
Bufferto validate that additions match a specified predicate. If an object cannot be added to the collection, an IllegalArgumentException is thrown.