UserDefinedFunction2

open class UserDefinedFunction2<T1, T2, R>(val udf: UserDefinedFunction, val encoder: Encoder<R>) : UserDefinedFunction<R, NamedUserDefinedFunction2<T1, T2, R>>

Instance of a UDF with 2 arguments. This UDF can be invoked with (typed) columns in a Dataset.select or selectTyped call. Alternatively it can be registered for SQL calls using register.

See also

Constructors

Link copied to clipboard
fun <R> UserDefinedFunction2(udf: UserDefinedFunction, encoder: Encoder<R>)

Functions

Link copied to clipboard
open operator override fun getValue(thisRef: Any?, property: KProperty<*>): NamedUserDefinedFunction2<T1, T2, R>

Returns named variant of this UDF.

Link copied to clipboard
operator fun invoke(param0: Column, param1: Column): Column

Returns an expression that invokes the UDF in untyped manner, using the given arguments.

operator fun <DsType> invoke(param0: TypedColumn<DsType, T1>, param1: TypedColumn<DsType, T2>): TypedColumn<DsType, R>

Allows this UDF to be called in typed manner using columns in a Dataset.selectTyped call.

Link copied to clipboard
fun invokeUntyped(param0: Column, param1: Column): Column

Returns an expression that invokes the UDF in untyped manner, using the given arguments.

Link copied to clipboard
open override fun withName(name: String): NamedUserDefinedFunction2<T1, T2, R>

Returns named variant of this UDF.

Properties

Link copied to clipboard
open val deterministic: Boolean

Returns true iff the UDF is deterministic, i.e. the UDF produces the same output given the same input.

Link copied to clipboard
open override val encoder: Encoder<R>
Link copied to clipboard
open val nullable: Boolean

Returns true when the UDF can return a nullable value.

Link copied to clipboard
open override val udf: UserDefinedFunction

Inheritors

Link copied to clipboard