ManyToManyJoinEntityTypeConvention Class

Definition

A convention which looks for matching skip navigations and automatically creates a many-to-many join entity with suitable foreign keys, sets the two matching skip navigations to use those foreign keys.

public class ManyToManyJoinEntityTypeConvention : Microsoft.EntityFrameworkCore.Metadata.Conventions.ISkipNavigationAddedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.ISkipNavigationForeignKeyChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.ISkipNavigationInverseChangedConvention, Microsoft.EntityFrameworkCore.Metadata.Conventions.ISkipNavigationRemovedConvention
type ManyToManyJoinEntityTypeConvention = class
    interface ISkipNavigationAddedConvention
    interface IConvention
    interface ISkipNavigationInverseChangedConvention
    interface ISkipNavigationForeignKeyChangedConvention
    interface ISkipNavigationRemovedConvention
Public Class ManyToManyJoinEntityTypeConvention
Implements ISkipNavigationAddedConvention, ISkipNavigationForeignKeyChangedConvention, ISkipNavigationInverseChangedConvention, ISkipNavigationRemovedConvention
Inheritance
ManyToManyJoinEntityTypeConvention
Derived
Implements

Remarks

See Model building conventions for more information and examples.

Constructors

ManyToManyJoinEntityTypeConvention(ProviderConventionSetBuilderDependencies)

Creates a new instance of ManyToManyJoinEntityTypeConvention.

Properties

Dependencies

Dependencies for this service.

Methods

CreateJoinEntityType(String, IConventionSkipNavigation)

Create a join entity type and configures the corresponding foreign keys.

CreateSkipNavigationForeignKey(IConventionSkipNavigation, IConventionEntityTypeBuilder)

Creates a foreign key on the given entity type to be used by the given skip navigation.

GenerateJoinTypeName(IConventionSkipNavigation)

Generates a unique name for the new joint entity type.

ProcessSkipNavigationAdded(IConventionSkipNavigationBuilder, IConventionContext<IConventionSkipNavigationBuilder>)

Called after a skip navigation is added to the entity type.

ProcessSkipNavigationForeignKeyChanged(IConventionSkipNavigationBuilder, IConventionForeignKey, IConventionForeignKey, IConventionContext<IConventionForeignKey>)

Called after a skip navigation inverse is changed.

ProcessSkipNavigationInverseChanged(IConventionSkipNavigationBuilder, IConventionSkipNavigation, IConventionSkipNavigation, IConventionContext<IConventionSkipNavigation>)

Called after a skip navigation inverse is changed.

ProcessSkipNavigationRemoved(IConventionEntityTypeBuilder, IConventionSkipNavigation, IConventionContext<IConventionSkipNavigation>)

Called after a skip navigation is removed from the entity type.

ShouldCreateJoinType(IConventionSkipNavigation)

Checks whether a new join entity type is needed.

Applies to