StatsProvider¶
Creating Instance¶
StatsProvider
takes the following to be created:
StatsProvider
is created alongside DataFiltersBuilder.
Statistic Column Function¶
StatsProvider
is given a Statistic Column Function when created.
StatsColumn => Option[Column]
The function is always getStatsColumnOpt.
getPredicateWithStatType¶
getPredicateWithStatType(
pathToColumn: Seq[String],
statType: String)(
f: Column => Column): Option[DataSkippingPredicate]
getPredicateWithStatType
getPredicateWithStatsColumn with a StatsColumn
for the given statType
and pathToColumn
, and the given f
function.
getPredicateWithStatType
is used when:
ColumnPredicateBuilder
is requested to lessThan, lessThanOrEqual, greaterThan, greaterThanOrEqualDataFiltersBuilder
is requested to constructDataFilters (forIsNull
predicate)
getPredicateWithStatsColumn¶
getPredicateWithStatsColumn(
statCol: StatsColumn)(
f: Column => Column): Option[DataSkippingPredicate]
getPredicateWithStatsColumn
uses the getStat function to look up the given statCol
and, if found (stat
), creates a DataSkippingPredicate
with the following:
- The result of applying the
f
function tostat
- The given
statCol
getPredicateWithStatTypes¶
getPredicateWithStatTypes(
pathToColumn: Seq[String],
statType1: String,
statType2: String)(
f: (Column, Column) => Column): Option[DataSkippingPredicate]
getPredicateWithStatTypes(
pathToColumn: Seq[String],
statType1: String,
statType2: String,
statType3: String)(
f: (Column, Column, Column) => Column): Option[DataSkippingPredicate]
getPredicateWithStatTypes
getPredicateWithStatsColumns with a StatsColumn
for all the given statType
s and pathToColumn
, and the given f
function.
getPredicateWithStatTypes
is used when:
ColumnPredicateBuilder
is requested to equalTo, notEqualToDataFiltersBuilder
is requested to constructDataFilters (forStartsWith
predicate)