Share via


IDatabase.CompileQuery Method

Definition

Overloads

CompileQuery<TResult>(QueryModel)

Translates a query model into a function that can be executed to get query results from the database.

CompileQuery<TResult>(Expression, Boolean)

Compiles the given query to generate a Func<T,TResult>.

CompileQuery<TResult>(QueryModel)

Translates a query model into a function that can be executed to get query results from the database.

public Func<Microsoft.EntityFrameworkCore.Query.QueryContext,System.Collections.Generic.IEnumerable<TResult>> CompileQuery<TResult> (Remotion.Linq.QueryModel queryModel);
abstract member CompileQuery : Remotion.Linq.QueryModel -> Func<Microsoft.EntityFrameworkCore.Query.QueryContext, seq<'Result>>
Public Function CompileQuery(Of TResult) (queryModel As QueryModel) As Func(Of QueryContext, IEnumerable(Of TResult))

Type Parameters

TResult

The type of results returned by the query.

Parameters

queryModel
Remotion.Linq.QueryModel

An object model representing the query to be executed.

Returns

A function that will execute the query.

Applies to

CompileQuery<TResult>(Expression, Boolean)

Compiles the given query to generate a Func<T,TResult>.

public Func<Microsoft.EntityFrameworkCore.Query.QueryContext,TResult> CompileQuery<TResult> (System.Linq.Expressions.Expression query, bool async);
abstract member CompileQuery : System.Linq.Expressions.Expression * bool -> Func<Microsoft.EntityFrameworkCore.Query.QueryContext, 'Result>
Public Function CompileQuery(Of TResult) (query As Expression, async As Boolean) As Func(Of QueryContext, TResult)

Type Parameters

TResult

The type of query result.

Parameters

query
Expression

The query to compile.

async
Boolean

A value indicating whether this is an async query.

Returns

Func<QueryContext,TResult>

A Func<T,TResult> which can be invoked to get results of the query.

Applies to