Share via


RelationalParameterBasedSqlProcessor.Optimize Method

Definition

Overloads

Optimize(SelectExpression, IReadOnlyDictionary<String,Object>, Boolean)

Optimizes the SelectExpression for given parameter values.

Optimize(Expression, IReadOnlyDictionary<String,Object>, Boolean)

Optimizes the query expression for given parameter values.

Optimize(SelectExpression, IReadOnlyDictionary<String,Object>, Boolean)

Optimizes the SelectExpression for given parameter values.

public virtual Microsoft.EntityFrameworkCore.Query.SqlExpressions.SelectExpression Optimize (Microsoft.EntityFrameworkCore.Query.SqlExpressions.SelectExpression selectExpression, System.Collections.Generic.IReadOnlyDictionary<string,object> parametersValues, out bool canCache);
public virtual Microsoft.EntityFrameworkCore.Query.SqlExpressions.SelectExpression Optimize (Microsoft.EntityFrameworkCore.Query.SqlExpressions.SelectExpression selectExpression, System.Collections.Generic.IReadOnlyDictionary<string,object?> parametersValues, out bool canCache);
abstract member Optimize : Microsoft.EntityFrameworkCore.Query.SqlExpressions.SelectExpression * System.Collections.Generic.IReadOnlyDictionary<string, obj> * bool -> Microsoft.EntityFrameworkCore.Query.SqlExpressions.SelectExpression
override this.Optimize : Microsoft.EntityFrameworkCore.Query.SqlExpressions.SelectExpression * System.Collections.Generic.IReadOnlyDictionary<string, obj> * bool -> Microsoft.EntityFrameworkCore.Query.SqlExpressions.SelectExpression
Public Overridable Function Optimize (selectExpression As SelectExpression, parametersValues As IReadOnlyDictionary(Of String, Object), ByRef canCache As Boolean) As SelectExpression

Parameters

selectExpression
SelectExpression

A select expression to optimize.

parametersValues
IReadOnlyDictionary<String,Object>

A dictionary of parameter values to use.

canCache
Boolean

A bool value indicating if the select expression can be cached.

Returns

An optimized select expression.

Applies to

Optimize(Expression, IReadOnlyDictionary<String,Object>, Boolean)

Optimizes the query expression for given parameter values.

public virtual System.Linq.Expressions.Expression Optimize (System.Linq.Expressions.Expression queryExpression, System.Collections.Generic.IReadOnlyDictionary<string,object?> parametersValues, out bool canCache);
abstract member Optimize : System.Linq.Expressions.Expression * System.Collections.Generic.IReadOnlyDictionary<string, obj> * bool -> System.Linq.Expressions.Expression
override this.Optimize : System.Linq.Expressions.Expression * System.Collections.Generic.IReadOnlyDictionary<string, obj> * bool -> System.Linq.Expressions.Expression
Public Overridable Function Optimize (queryExpression As Expression, parametersValues As IReadOnlyDictionary(Of String, Object), ByRef canCache As Boolean) As Expression

Parameters

queryExpression
Expression

A query expression to optimize.

parametersValues
IReadOnlyDictionary<String,Object>

A dictionary of parameter values to use.

canCache
Boolean

A bool value indicating if the query expression can be cached.

Returns

An optimized query expression.

Applies to