ExpressionExtensions.TryGetEFPropertyArguments Method

Definition

If the given a method-call expression represents a call to Property<TProperty>(Object, String), then this method extracts the entity expression and property name.

public static bool TryGetEFPropertyArguments (this System.Linq.Expressions.MethodCallExpression methodCallExpression, out System.Linq.Expressions.Expression entityExpression, out string propertyName);
public static bool TryGetEFPropertyArguments (this System.Linq.Expressions.MethodCallExpression methodCallExpression, out System.Linq.Expressions.Expression? entityExpression, out string? propertyName);
static member TryGetEFPropertyArguments : System.Linq.Expressions.MethodCallExpression * Expression * string -> bool
<Extension()>
Public Function TryGetEFPropertyArguments (methodCallExpression As MethodCallExpression, ByRef entityExpression As Expression, ByRef propertyName As String) As Boolean

Parameters

methodCallExpression
MethodCallExpression

The method-call expression for Property<TProperty>(Object, String)

entityExpression
Expression

The extracted entity access expression.

propertyName
String

The accessed property name.

Returns

true if the method-call was for Property<TProperty>(Object, String); false otherwise.

Applies to