Package com.bayesserver.data
Class PartitionDataReaderFilter
- java.lang.Object
-
- com.bayesserver.data.PartitionDataReaderFilter
-
- All Implemented Interfaces:
DataReaderFilter
public final class PartitionDataReaderFilter extends Object implements DataReaderFilter
A data reader filter based on an integer column, which can contain ids or a zero based partition identifier.
-
-
Constructor Summary
Constructors Constructor Description PartitionDataReaderFilter(DataPartitioning dataPartitioning, int partitionCount, String partitionColumn)
Initializes a new instance of thePartitionDataReaderFilter
class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
include(DataRecord record)
Determines whether a record should be included or not.
-
-
-
Constructor Detail
-
PartitionDataReaderFilter
public PartitionDataReaderFilter(DataPartitioning dataPartitioning, int partitionCount, String partitionColumn)
Initializes a new instance of thePartitionDataReaderFilter
class.- Parameters:
dataPartitioning
- The partitioning to use to filter the data.partitionCount
- The total number of partitions.partitionColumn
- The name of the column containing ids or a zero based partition identifier.
-
-
Method Detail
-
include
public boolean include(DataRecord record)
Determines whether a record should be included or not.- Specified by:
include
in interfaceDataReaderFilter
- Parameters:
record
- The current record to include or exclude.- Returns:
- Returns
true
if the record should be included,false
if the recorded should be excluded.
-
-