Table of Contents

Class BindableObject

Namespace
Icy.Data.Bindings
Assembly
IcyUI.dll

Represents an object that supports general bindings as target.

public abstract class BindableObject : ObservableDispatcherObject, INotifyPropertyChanging, IBindingTarget, INotifyPropertyChanged
Inheritance
BindableObject
Implements
Derived
Inherited Members
Extension Methods

Properties

Bindings

Gets all bindings set to this target.

public IReadOnlyCollection<IBinding> Bindings { get; }

Property Value

IReadOnlyCollection<IBinding>

Methods

Bind(IBinding)

Adds a binding to this object. Binding should have this object as a target.

public void Bind(IBinding binding)

Parameters

binding IBinding

Binding instance to add.

OnPropertyChanging(PropertyChangingEventArgs)

Raises the PropertyChanging event.

protected override void OnPropertyChanging(PropertyChangingEventArgs e)

Parameters

e PropertyChangingEventArgs

The input PropertyChangingEventArgs instance.

Unbind(IBinding)

Removes a binding from this object. This also will dispose the binding.

public bool Unbind(IBinding binding)

Parameters

binding IBinding

Binding instance to remove.

Returns

bool

true if the bindings was removed successfully, false otherwise.

UnbindAll()

Removes all the related bindings from this object.

public void UnbindAll()

UnbindWhere(Func<IBinding, bool>)

Removes all bindings that match the specified predicate.

public int UnbindWhere(Func<IBinding, bool> predicate)

Parameters

predicate Func<IBinding, bool>

A predicate to select bindings for the removal.

Returns

int

Count of removed bindings.