| 
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.healthmarketscience.jackcess.RowFilter
public abstract class RowFilter
The RowFilter class encapsulates a filter test for a table row.  This can
 be used by the apply(Iterable) method to create an Iterable over a
 table which returns only rows matching some criteria.
| Constructor Summary | |
|---|---|
RowFilter()
 | 
|
| Method Summary | |
|---|---|
 Iterable<Map<String,Object>> | 
apply(Iterable<Map<String,Object>> iterable)
Returns an iterable which filters the given iterable based on this filter.  | 
static Iterable<Map<String,Object>> | 
apply(RowFilter rowFilter,
      Iterable<Map<String,Object>> iterable)
Returns an iterable which filters the given iterable based on the given rowFilter.  | 
static RowFilter | 
invert(RowFilter filter)
Creates a filter which inverts the sense of the given filter (rows which are matched by the given filter will not be matched by the returned filter, and vice versa).  | 
abstract  boolean | 
matches(Map<String,Object> row)
Returns true if the given table row matches the Filter criteria,
 false otherwise. | 
static RowFilter | 
matchPattern(Column columnPattern,
             Object valuePattern)
Creates a filter based on a single value row pattern.  | 
static RowFilter | 
matchPattern(Map<String,Object> rowPattern)
Creates a filter based on a row pattern.  | 
| Methods inherited from class java.lang.Object | 
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Constructor Detail | 
|---|
public RowFilter()
| Method Detail | 
|---|
public abstract boolean matches(Map<String,Object> row)
true if the given table row matches the Filter criteria,
 false otherwise.
row - current row to test for inclusion in the filterpublic Iterable<Map<String,Object>> apply(Iterable<Map<String,Object>> iterable)
iterable - row iterable to filter
public static RowFilter matchPattern(Map<String,Object> rowPattern)
rowPattern - Map from column names to the values to be matched.
                   A table row will match the target if
                   ObjectUtils.equals(rowPattern.get(s), row.get(s))
                   for all column names in the pattern map.
public static RowFilter matchPattern(Column columnPattern,
                                     Object valuePattern)
columnPattern - column to be matchedvaluePattern - value to be matched.
                     A table row will match the target if
                     ObjectUtils.equals(valuePattern, row.get(columnPattern.getName())).
public static RowFilter invert(RowFilter filter)
filter - filter which to invert
public static Iterable<Map<String,Object>> apply(RowFilter rowFilter,
                                                 Iterable<Map<String,Object>> iterable)
rowFilter - the filter criteria, may be nulliterable - row iterable to filter
null
         filter was given)
  | 
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||