Struct sixtyfps_compilerlib::expression_tree::BindingExpression [−][src]
pub struct BindingExpression {
pub expression: Expression,
pub span: Option<SourceLocation>,
pub priority: i32,
pub animation: Option<PropertyAnimation>,
pub analysis: RefCell<Option<BindingAnalysis>>,
pub two_way_bindings: Vec<NamedReference>,
}
Expand description
The expression in the Element::binding hash table
Fields
expression: Expression
span: Option<SourceLocation>
The location of this expression in the source code
priority: i32
How deep is this binding declared in the hierarchy. When two binding are conflicting for the same priority (because of two way binding), the lower priority wins. The priority starts at 1, and each level of inlining adds one to the priority. 0 means the expression was added by some passes and it is not explicit in the source code
animation: Option<PropertyAnimation>
analysis: RefCell<Option<BindingAnalysis>>
The analysis information. None before it is computed
two_way_bindings: Vec<NamedReference>
The properties this expression is aliased with using two way bindings
Implementations
Create an expression binding that simply is a two way binding to the other
Merge the other into this one. Normally, &self is kept intact (has priority) unless the expression is invalid, in which case the other one is taken.
Also the animation is taken if the other don’t have one, and the two ways binding are taken into account.
Returns true if the other expression was taken
returns false if there is no expression or two way binding
Methods from Deref<Target = Expression>
Call the visitor for each sub-expression. (note: this function does not recurse)
Visit itself and each sub expression recursively
Visit itself and each sub expression recursively
Try to mark this expression to a lvalue that can be assigned to.
Return true if the expression is a “lvalue” that can be used as the left hand side of a =
or +=
or similar
Trait Implementations
type Target = Expression
type Target = Expression
The resulting type after dereferencing.
Performs the conversion.
Auto Trait Implementations
impl !RefUnwindSafe for BindingExpression
impl !Send for BindingExpression
impl !Sync for BindingExpression
impl Unpin for BindingExpression
impl !UnwindSafe for BindingExpression
Blanket Implementations
Mutably borrows from an owned value. Read more