pub trait VortexExpr:
'static
+ Send
+ Sync
+ Debug
+ Display
+ DynEq
+ DynHash
+ Sealed
+ AnalysisExpr {
// Required methods
fn as_any(&self) -> &dyn Any;
fn to_expr(&self) -> ExprRef;
fn encoding(&self) -> ExprEncodingRef;
fn unchecked_evaluate(&self, ctx: &Scope) -> VortexResult<ArrayRef>;
fn children(&self) -> Vec<&ExprRef> ⓘ;
fn with_children(
self: Arc<Self>,
children: Vec<ExprRef>,
) -> VortexResult<ExprRef>;
fn return_dtype(&self, scope: &DType) -> VortexResult<DType>;
// Provided method
fn metadata(&self) -> Option<Vec<u8>> { ... }
}Expand description
Represents logical operation on ArrayRefs
Required Methods§
Sourcefn encoding(&self) -> ExprEncodingRef
fn encoding(&self) -> ExprEncodingRef
Return the encoding of the expression.
Sourcefn unchecked_evaluate(&self, ctx: &Scope) -> VortexResult<ArrayRef>
fn unchecked_evaluate(&self, ctx: &Scope) -> VortexResult<ArrayRef>
Compute result of expression on given batch producing a new batch
“Unchecked” means that this function lacks a debug assertion that the returned array matches
the VortexExpr::return_dtype method. Use instead the
VortexExpr::evaluate.
function which includes such an assertion.
Sourcefn with_children(
self: Arc<Self>,
children: Vec<ExprRef>,
) -> VortexResult<ExprRef>
fn with_children( self: Arc<Self>, children: Vec<ExprRef>, ) -> VortexResult<ExprRef>
Returns a new instance of this expression with the children replaced.
Sourcefn return_dtype(&self, scope: &DType) -> VortexResult<DType>
fn return_dtype(&self, scope: &DType) -> VortexResult<DType>
Compute the type of the array returned by
VortexExpr::evaluate.
Provided Methods§
Implementations§
Source§impl dyn VortexExpr + '_
impl dyn VortexExpr + '_
pub fn id(&self) -> ExprId
pub fn is<V: VTable>(&self) -> bool
pub fn as_<V: VTable>(&self) -> &V::Expr
pub fn as_opt<V: VTable>(&self) -> Option<&V::Expr>
Sourcepub fn evaluate(&self, scope: &Scope) -> VortexResult<ArrayRef>
pub fn evaluate(&self, scope: &Scope) -> VortexResult<ArrayRef>
Compute result of expression on given batch producing a new batch
Trait Implementations§
Source§impl AsRef<dyn VortexExpr> for BetweenExpr
impl AsRef<dyn VortexExpr> for BetweenExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for BinaryExpr
impl AsRef<dyn VortexExpr> for BinaryExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for CastExpr
impl AsRef<dyn VortexExpr> for CastExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for DynamicComparisonExpr
impl AsRef<dyn VortexExpr> for DynamicComparisonExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for GetItemExpr
impl AsRef<dyn VortexExpr> for GetItemExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for IsNullExpr
impl AsRef<dyn VortexExpr> for IsNullExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for LikeExpr
impl AsRef<dyn VortexExpr> for LikeExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for ListContainsExpr
impl AsRef<dyn VortexExpr> for ListContainsExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for LiteralExpr
impl AsRef<dyn VortexExpr> for LiteralExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for MergeExpr
impl AsRef<dyn VortexExpr> for MergeExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for NotExpr
impl AsRef<dyn VortexExpr> for NotExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for PackExpr
impl AsRef<dyn VortexExpr> for PackExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for RootExpr
impl AsRef<dyn VortexExpr> for RootExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl AsRef<dyn VortexExpr> for SelectExpr
impl AsRef<dyn VortexExpr> for SelectExpr
Source§fn as_ref(&self) -> &dyn VortexExpr
fn as_ref(&self) -> &dyn VortexExpr
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl ExprSerializeProtoExt for dyn VortexExpr + '_
impl ExprSerializeProtoExt for dyn VortexExpr + '_
Source§fn serialize_proto(&self) -> VortexResult<Expr>
fn serialize_proto(&self) -> VortexResult<Expr>
Serialize the expression to its protobuf representation.