PredicateHelper Scala Trait
PredicateHelper defines the methods that are used to work with predicates (mainly).
| Method | Description |
|---|---|
Splitting Conjunctive Predicates — splitConjunctivePredicates Method
|
1 2 3 4 5 |
splitConjunctivePredicates(condition: Expression): Seq[Expression] |
splitConjunctivePredicates takes the input condition expression and splits it to two expressions if they are children of a And binary expression.
splitConjunctivePredicates splits the child expressions recursively down the child expressions until no conjunctive And binary expressions exist.
splitDisjunctivePredicates Method
|
1 2 3 4 5 |
splitDisjunctivePredicates(condition: Expression): Seq[Expression] |
splitDisjunctivePredicates…FIXME
|
Note
|
splitDisjunctivePredicates is used when…FIXME
|
replaceAlias Method
|
1 2 3 4 5 6 7 |
replaceAlias( condition: Expression, aliases: AttributeMap[Expression]): Expression |
replaceAlias…FIXME
|
Note
|
replaceAlias is used when…FIXME
|
canEvaluate Method
|
1 2 3 4 5 |
canEvaluate(expr: Expression, plan: LogicalPlan): Boolean |
canEvaluate…FIXME
|
Note
|
canEvaluate is used when…FIXME
|
canEvaluateWithinJoin Method
|
1 2 3 4 5 |
canEvaluateWithinJoin(expr: Expression): Boolean |
canEvaluateWithinJoin indicates whether a Catalyst expression can be evaluated within a join, i.e. when one of the following conditions holds:
-
Expression is deterministic
-
Expression is not
Unevaluable,ListQueryorExists -
Expression is a
SubqueryExpressionwith no child expressions -
Expression is a
AttributeReference -
Any expression with child expressions that meet one of the above conditions
|
Note
|
|
spark技术分享