evaluate_expr_with_shared

Function evaluate_expr_with_shared 

Source
pub fn evaluate_expr_with_shared(
    expr: &Expr,
    model: &dyn UiBindable,
    shared: Option<&dyn UiBindable>,
) -> Result<BindingValue, BindingError>
Expand description

Evaluate an expression with access to both local model and shared context

This is the preferred method when shared state bindings ({shared.field}) are used. Falls back to model-only evaluation for expressions that don’t use shared state.

§Arguments

  • expr - The expression to evaluate
  • model - The local view model implementing UiBindable
  • shared - Optional shared context implementing UiBindable

§Returns

The evaluated BindingValue or an error if evaluation fails.