C# Class Illusion.BindingEngine

A bind engine supports custom data binding.
It exports two methods for data binding: 1.SetPropertyBinding 2.ClearPropertyBinding The binding engine use weak reference to hold the dependent, that means if u miss to clear data binding, the dependent will not leak memory.
Mostra file Open project: kasicass/kasicass

Public Methods

Method Description
ClearPropertyBinding ( Object source, INotifyPropertyChanged target, string sourceProp, string targetProp ) : void

Clears the property binding.

SetPropertyBinding ( Object source, INotifyPropertyChanged target, string sourceProp, string targetProp, bool notify = true, IDataConverter converter = null, object parameter = null ) : void

Sets the property binding.

Private Methods

Method Description
GetExpressionAction ( WeakEntry entry, object source, bool createNew, IDataConverter converter = null ) : Delegate

Gets the expression action.

Method Details

ClearPropertyBinding() public static method

Clears the property binding.
public static ClearPropertyBinding ( Object source, INotifyPropertyChanged target, string sourceProp, string targetProp ) : void
source Object The source.
target INotifyPropertyChanged The target.
sourceProp string The source prop.
targetProp string The target prop.
return void

SetPropertyBinding() public static method

Sets the property binding.
public static SetPropertyBinding ( Object source, INotifyPropertyChanged target, string sourceProp, string targetProp, bool notify = true, IDataConverter converter = null, object parameter = null ) : void
source Object The source.
target INotifyPropertyChanged The target.
sourceProp string The source prop.
targetProp string The target prop.
notify bool if set to true update immediately.
converter IDataConverter The converter.
parameter object The converter parameter.
return void