Package org.ka2ddo.yaac.filter
Interface CumulativeFilter
- All Known Implementing Classes:
CumulativeBooleanAndFilter
,CumulativeBooleanOrFilter
public interface CumulativeFilter
This filter accumulates the results of several filters and determines the
overall pass/fail based on the aggregation of the sub-filters' results.
- Author:
- Andrew Pavlin, KA2DDO
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Add a sub-Filter to this CumulativeFilter.getFilter
(int index) Get a reference to the Nth Filter installed in this CumulativeFilter.int
Get the number of sub-filters in this CumulativeFilter.iterator()
Returns an iterator over the child Filters of this CumulativeFilter.void
removeFilter
(Filter filter) Disconnect the specified Filter from this CumulativeFilter.
-
Method Details
-
addFilter
Add a sub-Filter to this CumulativeFilter.- Parameters:
filter
- Filter to be added to this filter
-
removeFilter
Disconnect the specified Filter from this CumulativeFilter.- Parameters:
filter
- Filter to remove; if not found, nothing happens
-
getFilterCount
int getFilterCount()Get the number of sub-filters in this CumulativeFilter.- Returns:
- int filter count
-
getFilter
Get a reference to the Nth Filter installed in this CumulativeFilter.- Parameters:
index
- zero-based index into this containing Filter- Returns:
- return the Nth Filter instance
- Throws:
IndexOutOfBoundsException
- if the index is out of range
-
iterator
Returns an iterator over the child Filters of this CumulativeFilter.- Returns:
- an Iterator.
-