AvaloniaObjectExtensions.

Bind<T>(IAvaloniaObject, AvaloniaProperty<T>, IObservable<BindingValue<T>>, BindingPriority) Method

Summary

Binds a AvaloniaProperty to an observable.
Namespace
Avalonia
Containing Type
AvaloniaObjectExtensions

Syntax

public static IDisposable Bind<T>(this IAvaloniaObject target, AvaloniaProperty<T> property, IObservable<BindingValue<T>> source, BindingPriority priority = LocalValue)

Type Parameters

Name Description
T The type of the property.

Parameters

Name Type Description
target IAvaloniaObject The object.
property AvaloniaProperty<T> The property.
source IObservable<BindingValue<T>> The observable.
priority BindingPriority The priority of the binding.

Return Value

Type Description
IDisposable A disposable which can be used to terminate the binding.