Click or drag to resize

SubscriptionExtensionsSubscribeT Method

Subscribes an action to a specific property that will be called during that property's OnPropertyChanged event.

Namespace:  Xcalibur.Extensions.MVVM.Extensions
Assembly:  Xcalibur.Extensions.MVVM (in Xcalibur.Extensions.MVVM.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
public static void Subscribe<T>(
	this T model,
	Expression<Func<T, Object>> property,
	Action<Object> onChanged,
	Nullable<Guid> ownerId = null
)
where T : ISubscribe

Parameters

model
Type: T
The model.
property
Type: System.Linq.ExpressionsExpressionFuncT, Object
The property.
onChanged
Type: SystemActionObject
The on changed.
ownerId (Optional)
Type: SystemNullableGuid
The owner identifier.

Type Parameters

T

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type . When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also