Class RewriteSpatialPartitioningAggregation
- java.lang.Object
-
- io.trino.sql.planner.iterative.rule.RewriteSpatialPartitioningAggregation
-
- All Implemented Interfaces:
Rule<AggregationNode>
public class RewriteSpatialPartitioningAggregation extends Object implements Rule<AggregationNode>
Re-writes spatial_partitioning(geometry) aggregations into spatial_partitioning(envelope, partition_count) on top of ST_Envelope(geometry) projection, e.g.- Aggregation: spatial_partitioning(geometry) - sourcebecomes- Aggregation: spatial_partitioning(envelope, partition_count) - Project: envelope := ST_Envelope(geometry) - source, where partition_count is the value of session property hash_partition_count
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface io.trino.sql.planner.iterative.Rule
Rule.Context, Rule.Result
-
-
Constructor Summary
Constructors Constructor Description RewriteSpatialPartitioningAggregation(Metadata metadata)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Rule.Resultapply(AggregationNode node, Captures captures, Rule.Context context)Pattern<AggregationNode>getPattern()Returns a pattern to which plan nodes this rule applies.
-
-
-
Constructor Detail
-
RewriteSpatialPartitioningAggregation
public RewriteSpatialPartitioningAggregation(Metadata metadata)
-
-
Method Detail
-
getPattern
public Pattern<AggregationNode> getPattern()
Description copied from interface:RuleReturns a pattern to which plan nodes this rule applies.- Specified by:
getPatternin interfaceRule<AggregationNode>
-
apply
public Rule.Result apply(AggregationNode node, Captures captures, Rule.Context context)
- Specified by:
applyin interfaceRule<AggregationNode>
-
-