Share via


DefiningQueryRewritingConvention Class

Definition

Convention that converts accesses of DbSet<TEntity> inside query filters and defining queries into EntityQueryRootExpression. This makes them consistent with how DbSet accesses in the actual queries are represented, which allows for easier processing in the query pipeline.

public class DefiningQueryRewritingConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.QueryFilterRewritingConvention
type DefiningQueryRewritingConvention = class
    inherit QueryFilterRewritingConvention
Public Class DefiningQueryRewritingConvention
Inherits QueryFilterRewritingConvention
Inheritance
DefiningQueryRewritingConvention

Remarks

See Model building conventions, and The EF Core in-memory database provider for more information and examples.

Constructors

DefiningQueryRewritingConvention(ProviderConventionSetBuilderDependencies)

Creates a new instance of QueryFilterRewritingConvention.

Properties

DbSetAccessRewriter

Visitor used to rewrite DbSet<TEntity> accesses encountered in query filters to EntityQueryRootExpression.

(Inherited from QueryFilterRewritingConvention)
Dependencies

Dependencies for this service.

(Inherited from QueryFilterRewritingConvention)

Methods

ProcessModelFinalizing(IConventionModelBuilder, IConventionContext<IConventionModelBuilder>) System.Object.ProcessModelFinalizing(Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionModelBuilder,Microsoft.EntityFrameworkCore.Metadata.Conventions.IConventionContext{Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionModelBuilder})

Applies to