gravitino.api.expressions.transforms.transform.Transform¶
- class gravitino.api.expressions.transforms.transform.Transform¶
Bases:
Expression,ABCRepresents a transform function in the public logical expression API.
For example, the transform date(ts) is used to derive a date value from a timestamp column. The transform name is “date” and its argument is a reference to the “ts” column.
- __init__()¶
Methods
__init__()Gets the arguments passed to the transform function.
Gets the preassigned partitions in the partitioning.
children()Returns a list of the children of this node.
name()Gets the transform function name.
Returns a list of fields or columns that are referenced by this expression.
Attributes
EMPTY_EXPRESSION is only used as an input when the default children method builds the result.
EMPTY_NAMED_REFERENCE is only used as an input when the default references method builds the result array to avoid repeatedly allocating an empty array.
- EMPTY_EXPRESSION: List[Expression] = []¶
EMPTY_EXPRESSION is only used as an input when the default children method builds the result.
- EMPTY_NAMED_REFERENCE: List[NamedReference] = []¶
EMPTY_NAMED_REFERENCE is only used as an input when the default references method builds the result array to avoid repeatedly allocating an empty array.
- abstract arguments() List[Expression]¶
Gets the arguments passed to the transform function.
- Returns:
List[Expression]: The arguments passed to the transform function.
- assignments() List[Partition]¶
Gets the preassigned partitions in the partitioning.
Currently, only Transforms.ListTransform and Transforms.RangeTransform need to deal with assignments
- Returns:
List[Partition]: The preassigned partitions in the partitioning.
- children() List[Expression]¶
Returns a list of the children of this node. Children should not change.
- abstract name() str¶
Gets the transform function name.
- Returns:
str: The transform function name.
- references() List[NamedReference]¶
Returns a list of fields or columns that are referenced by this expression.