gravitino.api.function.function_param.FunctionParams

class gravitino.api.function.function_param.FunctionParams

Bases: object

Factory class for creating FunctionParam instances.

__init__()

Methods

__init__()

of(name, data_type[, comment, default_value])

Create a FunctionParam instance.

class SimpleFunctionParam(name: str, data_type: Type, comment: str | None = None, default_value: Expression | None = None)

Bases: FunctionParam

Simple implementation of FunctionParam.

comment() str | None

Returns the optional comment of the parameter, None if not provided.

data_type() Type

Returns the data type of the parameter.

default_value() Expression | None

Returns the default value of the parameter if provided, otherwise None.

name() str

Returns the name of the parameter.

classmethod of(name: str, data_type: Type, comment: str | None = None, default_value: Expression | None = None) FunctionParam

Create a FunctionParam instance.

Args:

name: The parameter name. data_type: The parameter type. comment: The optional comment. default_value: The optional default value.

Returns:

A FunctionParam instance.