示例#1
0
        /// <summary>
        /// Checks whether the body of the lambda expression is a property access.
        /// </summary>
        public static bool IsProperty(this LambdaExpression expression)
        {
            Guard.NotNull(expression, nameof(expression));

            return(expression.Body is MemberExpression memberExpression && memberExpression.Member is PropertyInfo);
        }