Class ProjectPushDownSpec
- java.lang.Object
-
- org.apache.flink.table.planner.plan.abilities.source.SourceAbilitySpecBase
-
- org.apache.flink.table.planner.plan.abilities.source.ProjectPushDownSpec
-
- All Implemented Interfaces:
SourceAbilitySpec
public final class ProjectPushDownSpec extends SourceAbilitySpecBase
A sub-class ofSourceAbilitySpec
that can not only serialize/deserialize the projection to/from JSON, but also can push the projection into aSupportsProjectionPushDown
.
-
-
Field Summary
Fields Modifier and Type Field Description static String
FIELD_NAME_PROJECTED_FIELDS
-
Fields inherited from class org.apache.flink.table.planner.plan.abilities.source.SourceAbilitySpecBase
FIELD_NAME_PRODUCED_TYPE
-
-
Constructor Summary
Constructors Constructor Description ProjectPushDownSpec(int[][] projectedFields, RowType producedType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
apply(DynamicTableSource tableSource, SourceAbilityContext context)
Apply the ability to the givenDynamicTableSource
.boolean
equals(Object o)
String
getDigests(SourceAbilityContext context)
Additional digests to generate when this spec is applied to the source.int[][]
getProjectedFields()
int
hashCode()
boolean
needAdjustFieldReferenceAfterProjection()
Does this spec needs adjust field reference after projection.-
Methods inherited from class org.apache.flink.table.planner.plan.abilities.source.SourceAbilitySpecBase
getProducedType
-
-
-
-
Field Detail
-
FIELD_NAME_PROJECTED_FIELDS
public static final String FIELD_NAME_PROJECTED_FIELDS
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ProjectPushDownSpec
public ProjectPushDownSpec(int[][] projectedFields, RowType producedType)
-
-
Method Detail
-
apply
public void apply(DynamicTableSource tableSource, SourceAbilityContext context)
Description copied from interface:SourceAbilitySpec
Apply the ability to the givenDynamicTableSource
.
-
needAdjustFieldReferenceAfterProjection
public boolean needAdjustFieldReferenceAfterProjection()
Description copied from interface:SourceAbilitySpec
Does this spec needs adjust field reference after projection. If the spec containsRexNode
or references fields in scan table, the referenced field indices maybe changed after projection pushdown with scan reuse. Under such case, this method need to return true to notify planner doesn't reuse the scan.
-
getProjectedFields
public int[][] getProjectedFields()
-
getDigests
public String getDigests(SourceAbilityContext context)
Description copied from interface:SourceAbilitySpec
Additional digests to generate when this spec is applied to the source.- Parameters:
context
- The context about the source.
-
equals
public boolean equals(Object o)
- Overrides:
equals
in classSourceAbilitySpecBase
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classSourceAbilitySpecBase
-
-