public class TopNPrel extends SinglePrel
| Modifier and Type | Field and Description |
|---|---|
protected org.apache.calcite.rel.RelCollation |
collation |
protected int |
limit |
DRILL_PHYSICAL, logger| Constructor and Description |
|---|
TopNPrel(org.apache.calcite.plan.RelOptCluster cluster,
org.apache.calcite.plan.RelTraitSet traitSet,
org.apache.calcite.rel.RelNode child,
int limit,
org.apache.calcite.rel.RelCollation collation) |
| Modifier and Type | Method and Description |
|---|---|
org.apache.calcite.plan.RelOptCost |
computeSelfCost(org.apache.calcite.plan.RelOptPlanner planner,
org.apache.calcite.rel.metadata.RelMetadataQuery mq)
Cost of doing Top-N is proportional to M log N where M is the total number of
input rows and N is the limit for Top-N.
|
org.apache.calcite.rel.RelNode |
copy(org.apache.calcite.plan.RelTraitSet traitSet,
List<org.apache.calcite.rel.RelNode> inputs) |
org.apache.calcite.rel.RelWriter |
explainTerms(org.apache.calcite.rel.RelWriter pw) |
BatchSchema.SelectionVectorMode |
getEncoding()
A Prel's own SelectionVector mode - i.e whether it generates an SV2, SV4 or None
|
PhysicalOperator |
getPhysicalOperator(PhysicalPlanCreator creator) |
BatchSchema.SelectionVectorMode[] |
getSupportedEncodings()
Supported 'encodings' of a Prel indicates what are the acceptable modes of SelectionVector
of its child Prel
|
accept, iterator, needsFinalColumnReorderingchildrenAccept, deriveRowType, estimateRowCount, getInput, getInputs, replaceInputaccept, accept, collectVariablesSet, collectVariablesUsed, computeDigest, computeSelfCost, explain, getChildExps, getCluster, getCollationList, getConvention, getCorrelVariable, getDescription, getDigest, getExpectedInputRowType, getId, getInput, getQuery, getRelTypeName, getRows, getRowType, getTable, getTraitSet, getVariablesSet, getVariablesStopped, isDistinct, isKey, isValid, isValid, metadata, onRegister, recomputeDigest, register, sole, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaccept, accept, childrenAccept, collectVariablesSet, collectVariablesUsed, computeSelfCost, estimateRowCount, explain, getChildExps, getCollationList, getConvention, getCorrelVariable, getExpectedInputRowType, getInput, getInputs, getQuery, getRelTypeName, getRows, getRowType, getTable, getVariablesStopped, isDistinct, isKey, isValid, metadata, onRegister, recomputeDigest, register, replaceInputprotected int limit
protected final org.apache.calcite.rel.RelCollation collation
public TopNPrel(org.apache.calcite.plan.RelOptCluster cluster,
org.apache.calcite.plan.RelTraitSet traitSet,
org.apache.calcite.rel.RelNode child,
int limit,
org.apache.calcite.rel.RelCollation collation)
public org.apache.calcite.rel.RelNode copy(org.apache.calcite.plan.RelTraitSet traitSet,
List<org.apache.calcite.rel.RelNode> inputs)
copy in interface org.apache.calcite.rel.RelNodecopy in class org.apache.calcite.rel.AbstractRelNodepublic PhysicalOperator getPhysicalOperator(PhysicalPlanCreator creator) throws IOException
IOExceptionpublic org.apache.calcite.plan.RelOptCost computeSelfCost(org.apache.calcite.plan.RelOptPlanner planner,
org.apache.calcite.rel.metadata.RelMetadataQuery mq)
computeSelfCost in interface org.apache.calcite.rel.RelNodecomputeSelfCost in class org.apache.calcite.rel.AbstractRelNodepublic org.apache.calcite.rel.RelWriter explainTerms(org.apache.calcite.rel.RelWriter pw)
explainTerms in class org.apache.calcite.rel.SingleRelpublic BatchSchema.SelectionVectorMode[] getSupportedEncodings()
PrelgetSupportedEncodings in interface PrelgetSupportedEncodings in class SinglePrelpublic BatchSchema.SelectionVectorMode getEncoding()
PrelCopyright © 2017 The Apache Software Foundation. All rights reserved.