Package org.apache.druid.segment
Class EncodedKeyComponent<K>
java.lang.Object
org.apache.druid.segment.EncodedKeyComponent<K>
- Type Parameters:
K- Encoded key component type
Represents the encoded component of a row key corresponding to a single dimension.
The row key contains a component for each dimension.
-
Constructor Summary
ConstructorsConstructorDescriptionEncodedKeyComponent(K component, long effectiveSizeBytes) Creates an EncodedKeyComponent corresponding to a single dimension. -
Method Summary
Modifier and TypeMethodDescriptionEncoded dimension value(s) to be used as a component for a row key.longEffective size of the key component in bytes.
-
Constructor Details
-
EncodedKeyComponent
Creates an EncodedKeyComponent corresponding to a single dimension.- Parameters:
component- The encoded dimension value(s)effectiveSizeBytes- Effective size of the key component in bytes. This value is used to estimate on-heap memory usage and must account for the footprint of both the original and encoded dimension values, as applicable.
-
-
Method Details
-
getComponent
Encoded dimension value(s) to be used as a component for a row key. -
getEffectiveSizeBytes
public long getEffectiveSizeBytes()Effective size of the key component in bytes. This value is used to estimate on-heap memory usage and accounts for the memory footprint of both the original and encoded dimension values, as applicable.
-