CSLA.NET 5.4.2
CSLA .NET is a software development framework that helps you build a reusable, maintainable object-oriented business layer for your app.
Csla.Iosui.Binding.Binding Class Reference

Contains an individual binding to tie a property on an Axml view to the property on a supplied object. More...

Inheritance diagram for Csla.Iosui.Binding.Binding:

Public Member Functions

 Binding (UIView target, string targetProperty, object source, string sourceProperty, BindingDirection bindingDirection)
 Creates a new instance of the Binding class. More...
 
 Binding (UIView target, string targetProperty, object source, string sourceProperty, Func< object, object > convert, BindingDirection bindingDirection)
 Creates a new instance of the Binding class. More...
 
 Binding (UIView target, string targetProperty, object source, string sourceProperty, Func< object, object > convert, Func< object, object > convertBack, BindingDirection bindingDirection)
 Creates a new instance of the Binding class. More...
 
void UpdateSource ()
 Updates the source with the current value in the target object. More...
 
void UpdateTarget ()
 Updates the target with the current value in the source object. More...
 
void Dispose ()
 Clears the bindings, references and event handlers. More...
 

Properties

BindingDirection BindingDirection [get]
 Indicates if this is read only or two way binding. More...
 
UIView Target [get]
 The iOS view that is used by the binding. More...
 
object Source [get]
 The object that the view is bound to. More...
 
System.Reflection.PropertyInfo TargetProperty [get]
 The PropertyInfo for the property on the target view that is being bound to. More...
 
System.Reflection.PropertyInfo SourceProperty [get]
 The PropertyInfo for the property on the source object that is being bound to. More...
 
Func< object, object > Convert [get]
 A reference to a function to do a custom conversion from the source property to the target property. More...
 
Func< object, object > ConvertBack [get]
 A reference to a function to do a custom conversion from the target property to the source property. More...
 

Detailed Description

Contains an individual binding to tie a property on an Axml view to the property on a supplied object.

Definition at line 24 of file Csla.Iosui.Ios/Binding/Binding.cs.

Constructor & Destructor Documentation

◆ Binding() [1/3]

Csla.Iosui.Binding.Binding.Binding ( UIView  target,
string  targetProperty,
object  source,
string  sourceProperty,
BindingDirection  bindingDirection 
)

Creates a new instance of the Binding class.

Parameters
targetA reference to the control to bind to.
targetPropertyThe name of the property on the view to bind to.
sourceA reference to the object that will be bound to the control.
sourcePropertyThe name of the property on the object that will be bound to the target property.
bindingDirectionIndicates if the binding is one way or two way.

Definition at line 69 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ Binding() [2/3]

Csla.Iosui.Binding.Binding.Binding ( UIView  target,
string  targetProperty,
object  source,
string  sourceProperty,
Func< object, object >  convert,
BindingDirection  bindingDirection 
)

Creates a new instance of the Binding class.

Parameters
targetA reference to the control to bind to.
targetPropertyThe name of the property on the view to bind to.
sourceA reference to the object that will be bound to the control.
sourcePropertyThe name of the property on the object that will be bound to the target property.
convertA reference to a function to do a custom conversion from the source property to the target property.
bindingDirectionIndicates if the binding is one way or two way.

Definition at line 82 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ Binding() [3/3]

Csla.Iosui.Binding.Binding.Binding ( UIView  target,
string  targetProperty,
object  source,
string  sourceProperty,
Func< object, object >  convert,
Func< object, object >  convertBack,
BindingDirection  bindingDirection 
)

Creates a new instance of the Binding class.

Parameters
targetA reference to the control to bind to.
targetPropertyThe name of the property on the view to bind to.
sourceA reference to the object that will be bound to the control.
sourcePropertyThe name of the property on the object that will be bound to the target property.
convertA reference to a function to do a custom conversion from the source property to the target property.
convertBackA reference to a function to do a custom conversion from the target property to the source property.
bindingDirectionIndicates if the binding is one way or two way.

Definition at line 96 of file Csla.Iosui.Ios/Binding/Binding.cs.

Member Function Documentation

◆ Dispose()

void Csla.Iosui.Binding.Binding.Dispose ( )

Clears the bindings, references and event handlers.

Definition at line 176 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ UpdateSource()

void Csla.Iosui.Binding.Binding.UpdateSource ( )

Updates the source with the current value in the target object.

Uses the ConvertBack function to convert the data if available.

Definition at line 144 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ UpdateTarget()

void Csla.Iosui.Binding.Binding.UpdateTarget ( )

Updates the target with the current value in the source object.

Uses the Convert function to convert the data if available.

Definition at line 161 of file Csla.Iosui.Ios/Binding/Binding.cs.

Property Documentation

◆ BindingDirection

BindingDirection Csla.Iosui.Binding.Binding.BindingDirection
get

Indicates if this is read only or two way binding.

Definition at line 29 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ Convert

Func<object, object> Csla.Iosui.Binding.Binding.Convert
get

A reference to a function to do a custom conversion from the source property to the target property.

Definition at line 54 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ ConvertBack

Func<object, object> Csla.Iosui.Binding.Binding.ConvertBack
get

A reference to a function to do a custom conversion from the target property to the source property.

Definition at line 59 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ Source

object Csla.Iosui.Binding.Binding.Source
get

The object that the view is bound to.

Definition at line 39 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ SourceProperty

System.Reflection.PropertyInfo Csla.Iosui.Binding.Binding.SourceProperty
get

The PropertyInfo for the property on the source object that is being bound to.

Definition at line 49 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ Target

UIView Csla.Iosui.Binding.Binding.Target
get

The iOS view that is used by the binding.

Definition at line 34 of file Csla.Iosui.Ios/Binding/Binding.cs.

◆ TargetProperty

System.Reflection.PropertyInfo Csla.Iosui.Binding.Binding.TargetProperty
get

The PropertyInfo for the property on the target view that is being bound to.

Definition at line 44 of file Csla.Iosui.Ios/Binding/Binding.cs.