PostSharp6.1/API Reference/Post­Sharp.​Patterns.​Xaml Namespace/Dependency­Property­Services Class/Dependency­Property­Services Methods/Dependency­Property­Services.​Get­Dependency­Property Method/Dependency­Property­Services.​Get­Dependency­Property(T, U) Method (Expression(Func(T, U)))

DependencyPropertyServices.GetDependencyProperty<T, U> Method (Expression<Func<T, U>>)

Gets the DependencyProperty object associated with a property of a given name for a given type. The property name and the property owner type are extracted from the expression argument.

Namespace:  PostSharp.Patterns.Xaml
Assembly:  PostSharp.Patterns.Xaml (in PostSharp.Patterns.Xaml.dll) Version: 6.1.23.0 (6.1.23.0)
Syntax
C#
public static DependencyProperty GetDependencyProperty<T, U>(
	Expression<Func<T, U>> expression
)

Parameters

expression
Type: System.Linq.Expressions.Expression<Func<T, U>>
The lambda expression in the format (ClassName x) => x.PropertyName.

Type Parameters

T
U

Return Value

Type: DependencyProperty
The DependencyProperty instance.
See Also