BindToMixins
trait · ferroui-reactiveui · v0.5.0
trait BindToMixins<V: 'static>
The write of the values of an observable to a property (ReactiveUIBindingExtensions.BindTo);
implemented for every Rc<dyn IObservable<V>>.
Each value is converted to the type of the property (by the converter the call names, else by
the one registered for the pair of types, else passed when it already is of that type; a value
that cannot be converted is not written), and written on the thread that owns the target when
its platform has one. A value the property already holds is not written again. A registered
IPropertyBindingHook may refuse the binding, which binds
nothing.
Members
bind_to
fn bind_to<T, TT>(self: &Self, target: impl Into<Option<Rc<T>>>, property: SettableProperty<Rc<T>, TT>) -> Rc<dyn IDisposable>
where T: 'static,
TT: Clone + PartialEq + 'static
Writes each value to property of target; nothing is bound when target is None
(BindTo(TTarget?, Expression<Func<TTarget, TTargetValue?>>)).
bind_to_with
fn bind_to_with<T, TT>(self: &Self, target: impl Into<Option<Rc<T>>>, property: SettableProperty<Rc<T>, TT>, conversion_hint: Option<Rc<dyn Any>>, converter_override: Option<Rc<dyn IBindingTypeConverter>>) -> Rc<dyn IDisposable>
where T: 'static,
TT: Clone + PartialEq + 'static
bind_to, converting with converter_override instead of a registered
converter when it is given, and handing conversion_hint to the converter
(BindTo(..., object? conversionHint), BindTo(..., IBindingTypeConverter? converterOverride)
and BindTo(..., object? conversionHint, IBindingTypeConverter? converterOverride)).
Trait implementations
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.