Struct sql::plan::query::ExprContext[][src]

pub struct ExprContext<'a> {
    pub qcx: &'a QueryContext<'a>,
    pub name: &'a str,
    pub scope: &'a Scope,
    pub relation_type: &'a RelationType,
    pub allow_aggregates: bool,
    pub allow_subqueries: bool,
    pub allow_windows: bool,
}
Expand description

A bundle of unrelated things that we need for planning Exprs.

Fields

qcx: &'a QueryContext<'a>name: &'a str

The name of this kind of expression eg “WHERE clause”. Used only for error messages.

scope: &'a Scope

The context for the Query that contains this Expr. The current scope.

relation_type: &'a RelationType

The type of the current relation expression upon which this scalar expression will be evaluated.

allow_aggregates: bool

Are aggregate functions allowed in this context

allow_subqueries: bool

Are subqueries allowed in this context

allow_windows: bool

Are window functions allowed in this context

Implementations

Trait Implementations

Extracts a reference to the recursion guard embedded within the type.

Checks whether it is safe to recur and calls f if so. Read more

Like CheckedRecursion::checked_recur, but operates on a mutable reference to Self. Read more

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

Upcasts this ProgressEventTimestamp to Any. Read more

Returns the name of the concrete type of this object. Read more

Should always be Self

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more