Struct msi::Expr[][src]

pub struct Expr { /* fields omitted */ }
Expand description

An expression on database rows that can be used in queries.

Implementations

Returns an expression that evaluates to the value of the specified column.

Returns an expression that evaluates to a null value.

Returns an expression that evaluates to the given boolean value.

Returns an expression that evaluates to the given integer value.

Returns an expression that evaluates to the given string value.

Returns an expression that evaluates to true if the two subexpressions evaluate to equal values.

Returns an expression that evaluates to true if the two subexpressions evaluate to unequal values.

Returns an expression that evaluates to true if the left-hand subexpression evaluates to a strictly lesser value than the right-hand subexpression.

Returns an expression that evaluates to true if the left-hand subexpression evaluates to a lesser-or-equal value than the right-hand subexpression.

Returns an expression that evaluates to true if the left-hand subexpression evaluates to a strictly greater value than the right-hand subexpression.

Returns an expression that evaluates to true if the left-hand subexpression evaluates to a greater-or-equal value than the right-hand subexpression.

Returns an expression that computes the bitwise inverse of the subexpression. If the subexpression evaluates to a non-number, the result will be a null value.

This method exists instead of the std::ops::Not trait to distinguish it from the (logical) not() method.

Returns an expression that evaluates to true if both subexpressions evaluate to true.

Returns an expression that evaluates to true if either subexpression evaluates to true.

Returns an expression that evaluates to true if the subexpression evaluates to false.

This method exists instead of the std::ops::Not trait to distinguish it from the (bitwise) bitinv() method.

Evaluates the expression against the given row. Any errors in the expression (such as dividing a number by zero, or applying a bitwise operator to a string) will result in a null value.

Returns the set of all column names referenced by this expression.

Trait Implementations

Produces an expression that evaluates to the sum of the two subexpressions (if they are integers) or concatenation (if they are strings). If the two subexpressions evaluate to different types, or if either evaluates to a null value, the result will be a null value.

The resulting type after applying the + operator.

Performs the + operation. Read more

Produces an expression that evaluates to the bitwise-and of the two subexpressions. If either subexpression evaluates to a non-number, the result will be a null value.

The resulting type after applying the & operator.

Performs the & operation. Read more

Produces an expression that evaluates to the bitwise-or of the two subexpressions. If either subexpression evaluates to a non-number, the result will be a null value.

The resulting type after applying the | operator.

Performs the | operation. Read more

Produces an expression that evaluates to the bitwise-xor of the two subexpressions. If either subexpression evaluates to a non-number, the result will be a null value.

The resulting type after applying the ^ operator.

Performs the ^ operation. Read more

Formats the value using the given formatter. Read more

Produces an expression that evaluates to the integer quotient of the two subexpressions. If either subexpression evaluates to a non-number, or if the divisor evalulates to zero, the result will be a null value.

The resulting type after applying the / operator.

Performs the / operation. Read more

Produces an expression that evaluates to the product of the two subexpressions. If either subexpression evaluates to a non-number, the result will be a null value.

The resulting type after applying the * operator.

Performs the * operation. Read more

Produces an expression that evaluates to the negative of the subexpression. If the subexpression evaluates to a non-number, the result will be a null value.

The resulting type after applying the - operator.

Performs the unary - operation. Read more

Produces an expression that evaluates to the value of the left-hand subexpression bit-shifted left by the value of the right-hand subexpression. If either subexpression evaluates to a non-number, the result will be a null value.

The resulting type after applying the << operator.

Performs the << operation. Read more

Produces an expression that evaluates to the value of the left-hand subexpression bit-shifted right by the value of the right-hand subexpression. If either subexpression evaluates to a non-number, the result will be a null value.

The resulting type after applying the >> operator.

Performs the >> operation. Read more

Produces an expression that evaluates to the difference of the two subexpressions. If either subexpression evaluates to a non-number, the result will be a null value.

The resulting type after applying the - operator.

Performs the - operation. 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.

Performs the conversion.

Converts the given value to a String. 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.