Package org.openrefine.model
Class RowInRecordFilter
- java.lang.Object
-
- org.openrefine.model.RowInRecordFilter
-
- All Implemented Interfaces:
Serializable
,RecordFilter
,RowFilter
- Direct Known Subclasses:
DualExpressionsNumberComparisonRowFilter
,ExpressionEqualRowFilter
,ExpressionNumberComparisonRowFilter
,ExpressionStringComparisonRowFilter
public abstract class RowInRecordFilter extends Object implements RowFilter, RecordFilter
Row filter which has also access to the spanning record. This is needed when filtering by expressions which refer to the record via the `row.record` variable. When used as aRowFilter
this just passes `null` as a record.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static RowInRecordFilter
ANY_ROW_IN_RECORD
-
Fields inherited from interface org.openrefine.model.RecordFilter
ANY_RECORD
-
-
Constructor Summary
Constructors Constructor Description RowInRecordFilter(boolean anyRow)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description boolean
filterRecord(Record record)
boolean
filterRow(long rowIndex, Row row)
abstract boolean
filterRow(long rowIndex, Row row, Record record)
Determines if a row matches the filter.static RowInRecordFilter
fromRowFilter(RowFilter rowFilter)
-
-
-
Field Detail
-
ANY_ROW_IN_RECORD
public static final RowInRecordFilter ANY_ROW_IN_RECORD
-
-
Method Detail
-
filterRow
public abstract boolean filterRow(long rowIndex, Row row, Record record)
Determines if a row matches the filter.- Parameters:
rowIndex
- the global index of the row (from the entire grid)row
- the row itselfrecord
- the enclosing record- Returns:
- true if the row matches the filter
-
filterRecord
public boolean filterRecord(Record record)
- Specified by:
filterRecord
in interfaceRecordFilter
-
filterRow
public boolean filterRow(long rowIndex, Row row)
-
fromRowFilter
public static RowInRecordFilter fromRowFilter(RowFilter rowFilter)
-
-