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