Package org.apache.calcite.tools
Class Programs
java.lang.Object
org.apache.calcite.tools.Programs
Utilities for creating
Program
s.-
Field Summary
Modifier and TypeFieldDescriptionstatic final Program
Program that converts filters and projects toCalc
s.static final com.google.common.collect.ImmutableList<RelOptRule>
Deprecated.static final com.google.common.collect.ImmutableSet<RelOptRule>
static final Program
Program that expands sub-queries. -
Method Summary
Modifier and TypeMethodDescriptionstatic Program
calc
(RelMetadataProvider metadataProvider) static Program
conditional
(Predicate<RelNode> predicate, Program program) Creates a program that executes if a predicate is true.static Program
Deprecated.static Program
hep
(Iterable<? extends RelOptRule> rules, boolean noDag, RelMetadataProvider metadataProvider) Creates a program that executes a list of rules in a HEP planner.static Program
heuristicJoinOrder
(Iterable<? extends RelOptRule> rules, boolean bushy, int minJoinCount) Creates a program that invokes heuristic join-order optimization (viaJoinToMultiJoinRule
,MultiJoin
andLoptOptimizeJoinRule
) if there are 6 or more joins (7 or more relations).Creates a list of programs based on a list of rule sets.Creates a list of programs based on an array of rule sets.static Program
measure
(RelMetadataProvider metadataProvider) static Program
of
(HepProgram hepProgram, boolean noDag, RelMetadataProvider metadataProvider) Creates a program that executes aHepProgram
.static Program
Creates a program that executes a rule set.static Program
ofRules
(Iterable<? extends RelOptRule> rules) Creates a program from a list of rules.static Program
ofRules
(RelOptRule... rules) Creates a program from a list of rules.static Program
Creates a program that executes a sequence of programs.static Program
standard()
Returns the standard program used by Prepare.static Program
standard
(RelMetadataProvider metadataProvider) Returns the standard program with user metadata provider.static Program
standard
(RelMetadataProvider metadataProvider, boolean enableFieldTrimming) Returns the standard program with user metadata provider and enableFieldTrimming config.static Program
subquery
(RelMetadataProvider metadataProvider) Deprecated.static Program
subQuery
(RelMetadataProvider metadataProvider)
-
Field Details
-
CALC_RULES
Deprecated. -
CALC_PROGRAM
Program that converts filters and projects toCalc
s. -
SUB_QUERY_PROGRAM
Program that expands sub-queries. -
RULE_SET
-
-
Method Details
-
of
Creates a program that executes a rule set. -
listOf
Creates a list of programs based on an array of rule sets. -
listOf
Creates a list of programs based on a list of rule sets. -
ofRules
Creates a program from a list of rules. -
ofRules
Creates a program from a list of rules. -
sequence
Creates a program that executes a sequence of programs. -
conditional
Creates a program that executes if a predicate is true. -
hep
public static Program hep(Iterable<? extends RelOptRule> rules, boolean noDag, RelMetadataProvider metadataProvider) Creates a program that executes a list of rules in a HEP planner. -
of
public static Program of(HepProgram hepProgram, boolean noDag, RelMetadataProvider metadataProvider) Creates a program that executes aHepProgram
. -
heuristicJoinOrder
public static Program heuristicJoinOrder(Iterable<? extends RelOptRule> rules, boolean bushy, int minJoinCount) Creates a program that invokes heuristic join-order optimization (viaJoinToMultiJoinRule
,MultiJoin
andLoptOptimizeJoinRule
) if there are 6 or more joins (7 or more relations). -
calc
-
subquery
Deprecated. -
subQuery
-
measure
-
getProgram
Deprecated. -
standard
Returns the standard program used by Prepare. -
standard
Returns the standard program with user metadata provider. -
standard
Returns the standard program with user metadata provider and enableFieldTrimming config.
-