Package org.apache.calcite.rel.metadata
Class RelMdSize
java.lang.Object
org.apache.calcite.rel.metadata.RelMdSize
- All Implemented Interfaces:
MetadataHandler<BuiltInMetadata.Size>
Default implementations of the
BuiltInMetadata.Size
metadata provider for the standard logical algebra.-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
Bytes per character (2).static final RelMetadataProvider
Source forBuiltInMetadata.Size
. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaverageColumnSizes
(Aggregate rel, RelMetadataQuery mq) averageColumnSizes
(Calc rel, RelMetadataQuery mq) averageColumnSizes
(Exchange rel, RelMetadataQuery mq) averageColumnSizes
(Filter rel, RelMetadataQuery mq) averageColumnSizes
(Intersect rel, RelMetadataQuery mq) averageColumnSizes
(Join rel, RelMetadataQuery mq) averageColumnSizes
(Minus rel, RelMetadataQuery mq) averageColumnSizes
(Project rel, RelMetadataQuery mq) averageColumnSizes
(Sort rel, RelMetadataQuery mq) averageColumnSizes
(TableScan rel, RelMetadataQuery mq) averageColumnSizes
(Union rel, RelMetadataQuery mq) averageColumnSizes
(Values rel, RelMetadataQuery mq) averageColumnSizes
(RelNode rel, RelMetadataQuery mq) Catch-all implementation forBuiltInMetadata.Size.averageColumnSizes()
, invoked using reflection.protected @Nullable Double
Estimates the average size (in bytes) of a value of a field, knowing nothing more than its type.@Nullable Double
averageRexSize
(RexNode node, List<? extends @Nullable Double> inputColumnSizes) @Nullable Double
averageRowSize
(RelNode rel, RelMetadataQuery mq) Catch-all implementation forBuiltInMetadata.Size.averageRowSize()
, invoked using reflection.@Nullable Double
Estimates the average size (in bytes) of a value of a type.getDef()
double
typeValueSize
(RelDataType type, @Nullable Comparable value) Estimates the average size (in bytes) of a value of a type.
-
Field Details
-
SOURCE
Source forBuiltInMetadata.Size
. -
BYTES_PER_CHARACTER
public static final int BYTES_PER_CHARACTERBytes per character (2).- See Also:
-
-
Constructor Details
-
RelMdSize
protected RelMdSize()
-
-
Method Details
-
getDef
- Specified by:
getDef
in interfaceMetadataHandler<BuiltInMetadata.Size>
-
averageRowSize
Catch-all implementation forBuiltInMetadata.Size.averageRowSize()
, invoked using reflection. -
averageColumnSizes
Catch-all implementation forBuiltInMetadata.Size.averageColumnSizes()
, invoked using reflection. -
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageColumnSizes
-
averageFieldValueSize
Estimates the average size (in bytes) of a value of a field, knowing nothing more than its type.We assume that the proportion of nulls is negligible, even if the field is nullable.
-
averageTypeValueSize
Estimates the average size (in bytes) of a value of a type.We assume that the proportion of nulls is negligible, even if the type is nullable.
-
typeValueSize
Estimates the average size (in bytes) of a value of a type.Nulls count as 1 byte.
-
averageRexSize
-