Redigeeri

Jagamisviis:


IQueryProvider.Execute Method

Definition

Overloads

Execute(Expression)

Executes the query represented by a specified expression tree.

Execute<TResult>(Expression)

Executes the strongly-typed query represented by a specified expression tree.

Execute(Expression)

Executes the query represented by a specified expression tree.

public:
 System::Object ^ Execute(System::Linq::Expressions::Expression ^ expression);
public object Execute (System.Linq.Expressions.Expression expression);
public object? Execute (System.Linq.Expressions.Expression expression);
abstract member Execute : System.Linq.Expressions.Expression -> obj
Public Function Execute (expression As Expression) As Object

Parameters

expression
Expression

An expression tree that represents a LINQ query.

Returns

The value that results from executing the specified query.

Remarks

The Execute method executes queries that return a single value (instead of an enumerable sequence of values). Expression trees that represent queries that return enumerable results are executed when their associated IQueryable object is enumerated.

Applies to

Execute<TResult>(Expression)

Executes the strongly-typed query represented by a specified expression tree.

public:
generic <typename TResult>
 TResult Execute(System::Linq::Expressions::Expression ^ expression);
public TResult Execute<TResult> (System.Linq.Expressions.Expression expression);
abstract member Execute : System.Linq.Expressions.Expression -> 'Result
Public Function Execute(Of TResult) (expression As Expression) As TResult

Type Parameters

TResult

The type of the value that results from executing the query.

Parameters

expression
Expression

An expression tree that represents a LINQ query.

Returns

TResult

The value that results from executing the specified query.

Remarks

The Execute method executes queries that return a single value (instead of an enumerable sequence of values). Expression trees that represent queries that return enumerable results are executed when the IQueryable<T> object that contains the expression tree is enumerated.

The Queryable standard query operator methods that return singleton results call Execute. They pass it a MethodCallExpression that represents a LINQ query.

Applies to