CreateStruct Function Builder

CreateStruct is a function builder (e.g. Seq[Expression] ⇒ Expression) that can create CreateNamedStruct expressions and is the metadata of the struct function.

Metadata of struct Function — registryEntry Property

registryEntry: (String, (ExpressionInfo, FunctionBuilder))

registryEntry…​FIXME

Note
registryEntry is used exclusively when FunctionRegistry is requested for the function expression registry.

Creating CreateNamedStruct Expression — apply Method

apply(children: Seq[Expression]): CreateNamedStruct
Note
apply is part of Scala’s scala.Function1 contract to create a function of one parameter (e.g. Seq[Expression]).

apply creates a CreateNamedStruct expression with the input children expressions as follows:

  • For NamedExpression expressions that are resolved, apply creates a pair of a Literal expression (with the name of the NamedExpression) and the NamedExpression itself

  • For NamedExpression expressions that are not resolved yet, apply creates a pair of a NamePlaceholder expression and the NamedExpression itself

  • For all other expressions, apply creates a pair of a Literal expression (with the value as col[index]) and the Expression itself

Note

apply is used when:

results matching ""

    No results matching ""