struct AliasedScalarUDFImpl {
inner: UdfEq<Arc<dyn ScalarUDFImpl>>,
aliases: Vec<String>,
}Expand description
ScalarUDF that adds an alias to the underlying function. It is better to
implement ScalarUDFImpl, which supports aliases, directly if possible.
Fields§
§inner: UdfEq<Arc<dyn ScalarUDFImpl>>§aliases: Vec<String>Implementations§
Source§impl AliasedScalarUDFImpl
impl AliasedScalarUDFImpl
pub fn new( inner: Arc<dyn ScalarUDFImpl>, new_aliases: impl IntoIterator<Item = &'static str>, ) -> Self
Trait Implementations§
Source§impl Debug for AliasedScalarUDFImpl
impl Debug for AliasedScalarUDFImpl
Source§impl Hash for AliasedScalarUDFImpl
impl Hash for AliasedScalarUDFImpl
Source§impl PartialEq for AliasedScalarUDFImpl
impl PartialEq for AliasedScalarUDFImpl
Source§impl ScalarUDFImpl for AliasedScalarUDFImpl
impl ScalarUDFImpl for AliasedScalarUDFImpl
Source§fn display_name(&self, args: &[Expr]) -> Result<String>
fn display_name(&self, args: &[Expr]) -> Result<String>
👎Deprecated since 50.0.0: This method is unused and will be removed in a future release
Returns the user-defined display name of function, given the arguments Read more
Source§fn schema_name(&self, args: &[Expr]) -> Result<String>
fn schema_name(&self, args: &[Expr]) -> Result<String>
Returns the name of the column this expression would create Read more
Source§fn signature(&self) -> &Signature
fn signature(&self) -> &Signature
Returns a
Signature describing the argument types for which this
function has an implementation, and the function’s Volatility. Read moreSource§fn return_type(&self, arg_types: &[DataType]) -> Result<DataType>
fn return_type(&self, arg_types: &[DataType]) -> Result<DataType>
[
DataType] returned by this function, given the types of the
arguments. Read moreSource§fn return_field_from_args(&self, args: ReturnFieldArgs<'_>) -> Result<FieldRef>
fn return_field_from_args(&self, args: ReturnFieldArgs<'_>) -> Result<FieldRef>
What type will be returned by this function, given the arguments? Read more
Source§fn is_nullable(&self, args: &[Expr], schema: &dyn ExprSchema) -> bool
fn is_nullable(&self, args: &[Expr], schema: &dyn ExprSchema) -> bool
👎Deprecated since 45.0.0: Use
return_field_from_args instead. if you use is_nullable that returns non-nullable with return_type, you would need to switch to return_field_from_args, you might have errorSource§fn invoke_with_args(&self, args: ScalarFunctionArgs) -> Result<ColumnarValue>
fn invoke_with_args(&self, args: ScalarFunctionArgs) -> Result<ColumnarValue>
Invoke the function returning the appropriate result. Read more
Source§fn with_updated_config(&self, _config: &ConfigOptions) -> Option<ScalarUDF>
fn with_updated_config(&self, _config: &ConfigOptions) -> Option<ScalarUDF>
Create a new instance of this function with updated configuration. Read more
Source§fn aliases(&self) -> &[String]
fn aliases(&self) -> &[String]
Returns any aliases (alternate names) for this function. Read more
Source§fn simplify(
&self,
args: Vec<Expr>,
info: &dyn SimplifyInfo,
) -> Result<ExprSimplifyResult>
fn simplify( &self, args: Vec<Expr>, info: &dyn SimplifyInfo, ) -> Result<ExprSimplifyResult>
Optionally apply per-UDF simplification / rewrite rules. Read more
Source§fn conditional_arguments<'a>(
&self,
args: &'a [Expr],
) -> Option<(Vec<&'a Expr>, Vec<&'a Expr>)>
fn conditional_arguments<'a>( &self, args: &'a [Expr], ) -> Option<(Vec<&'a Expr>, Vec<&'a Expr>)>
Determines which of the arguments passed to this function are evaluated eagerly
and which may be evaluated lazily. Read more
Source§fn short_circuits(&self) -> bool
fn short_circuits(&self) -> bool
Returns true if some of this
exprs subexpressions may not be evaluated
and thus any side effects (like divide by zero) may not be encountered. Read moreSource§fn propagate_constraints(
&self,
interval: &Interval,
inputs: &[&Interval],
) -> Result<Option<Vec<Interval>>>
fn propagate_constraints( &self, interval: &Interval, inputs: &[&Interval], ) -> Result<Option<Vec<Interval>>>
Source§fn output_ordering(&self, inputs: &[ExprProperties]) -> Result<SortProperties>
fn output_ordering(&self, inputs: &[ExprProperties]) -> Result<SortProperties>
Calculates the
SortProperties of this function based on its children’s properties.Source§fn preserves_lex_ordering(&self, inputs: &[ExprProperties]) -> Result<bool>
fn preserves_lex_ordering(&self, inputs: &[ExprProperties]) -> Result<bool>
Returns true if the function preserves lexicographical ordering based on
the input ordering. Read more
Source§fn coerce_types(&self, arg_types: &[DataType]) -> Result<Vec<DataType>>
fn coerce_types(&self, arg_types: &[DataType]) -> Result<Vec<DataType>>
Coerce arguments of a function call to types that the function can evaluate. Read more
Source§fn documentation(&self) -> Option<&Documentation>
fn documentation(&self) -> Option<&Documentation>
Returns the documentation for this Scalar UDF. Read more
Source§fn lambdas_parameters(
&self,
args: &[ValueOrLambdaParameter<'_>],
) -> Result<Vec<Option<Vec<Field>>>>
fn lambdas_parameters( &self, args: &[ValueOrLambdaParameter<'_>], ) -> Result<Vec<Option<Vec<Field>>>>
Returns the parameters that any lambda supports
impl Eq for AliasedScalarUDFImpl
impl StructuralPartialEq for AliasedScalarUDFImpl
Auto Trait Implementations§
impl Freeze for AliasedScalarUDFImpl
impl !RefUnwindSafe for AliasedScalarUDFImpl
impl Send for AliasedScalarUDFImpl
impl Sync for AliasedScalarUDFImpl
impl Unpin for AliasedScalarUDFImpl
impl !UnwindSafe for AliasedScalarUDFImpl
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more