|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The TableDataFilter interface performs a filtering operation on a
TableDataProvider
. If a component is using an TableDataFilter, it
will invoke the filter(...)
method to determine which rows
should be displayed in the visual (or non-visual) component.
NOTE: If a component is bound to a TableDataProvider
and a
TableDataFilter which are the *same* instance, the filter(...)
method is never called. The filter is assumed to be intrinsic in the row
data of the TableDataProvider
, based on the currently set filter
criteria.
Typically, an TableDataFilter implementation will iterate the contained
set of FilterCriteria objects and call the match(...)
method on
each for each row of data in the TableDataProvider. The combination of
include and/or exclude match criteria then determines wether a row is
included or excluded from the filter.
TableDataProvider
,
FilterCriteria
Method Summary | |
RowKey[] |
filter(TableDataProvider provider,
RowKey[] rows)
Performs a filter operation on the passed set of RowKey
objects. |
FilterCriteria[] |
getFilterCriteria()
Returns the current filter criteria on this data filterer. |
void |
setFilterCriteria(FilterCriteria[] filterCriteria)
Sets the filter criteria on this data filter. |
Method Detail |
public void setFilterCriteria(FilterCriteria[] filterCriteria)
Sets the filter criteria on this data filter.
filterCriteria
- An array of FilterCriteria
objects defining
the filter order on this TableDataFilterpublic FilterCriteria[] getFilterCriteria()
Returns the current filter criteria on this data filterer.
public RowKey[] filter(TableDataProvider provider, RowKey[] rows) throws DataProviderException
Performs a filter operation on the passed set of RowKey
objects. Typically, the contained FilterCriteria objects will be
iterated for each row and their match(...)
method will be
called in conjunction with their isInclude()
method to
determine if a row should be displayed or not.
NOTE: If a component is bound to an TableDataProvider
and
an TableDataFilter, which are the *same* instance, this method is never
called. The filter is assumed to be intrinsic in the row data of the
TableDataProvider
, based on the currently set filter criteria.
provider
- TableDataProvider
containing the data on displayrows
- An array of RowKey
to be filtered. If this is
null
, then the return value should be
null
or an empty array of RowKeys.
RowKey
representing the result of the filter
operation
DataProviderException
- Implementations may wish to surface
internal exceptions (nested in DataProviderException) rather
than simply returning null. A DPE may also indicate that the
passed TableDataProvider or RowKeys are not valid. Consult the
documentation of the specific TableDataFilter implementation for
details on what exceptions might be wrapped by a DPE.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |