java.lang.Object
|
+--org.apache.commons.collections.collection.AbstractCollectionDecorator
|
+--org.apache.commons.collections.collection.PredicatedCollection
|
+--org.apache.commons.collections.set.PredicatedSet
|
+--org.apache.commons.collections.set.PredicatedSortedSet
All Implemented Interfaces:PredicatedSortedSet(SortedSet set, Predicate predicate) Constructor that wraps (not copies). |
Comparator | |
static SortedSet | decorate(SortedSet set, Predicate predicate) Factory method to create a predicated (validating) sorted set. |
Object | first() |
SortedSet | headSet(Object toElement) |
Object | last() |
SortedSet | subSet(Object fromElement, Object toElement) |
SortedSet | tailSet(Object fromElement) |
protected PredicatedSortedSet(SortedSet set, Predicate predicate)
- if set or predicate is null - if the set contains invalid elementspublic Comparator comparator()
public static SortedSet decorate(SortedSet set, Predicate predicate)
- if set or predicate is null - if the set contains invalid elementspublic Object first()
public SortedSet headSet(Object toElement)
public Object last()
public SortedSet subSet(Object fromElement, Object toElement)
public SortedSet tailSet(Object fromElement)
SortedSetto validate that all additions match a specified predicate. If an object cannot be added to the set, an IllegalArgumentException is thrown.