Share via


RuntimeEntityType.AddSkipNavigation Method

Definition

Overloads

AddSkipNavigation(String, RuntimeEntityType, RuntimeForeignKey, Boolean, Boolean, Type, PropertyInfo, FieldInfo, PropertyAccessMode, Boolean)

Adds a new skip navigation property to this entity type.

AddSkipNavigation(String, RuntimeEntityType, RuntimeForeignKey, Boolean, Boolean, Type, PropertyInfo, FieldInfo, PropertyAccessMode, Boolean, Boolean)

Adds a new skip navigation property to this entity type.

AddSkipNavigation(String, RuntimeEntityType, RuntimeForeignKey, Boolean, Boolean, Type, PropertyInfo, FieldInfo, PropertyAccessMode, Boolean)

Adds a new skip navigation property to this entity type.

public virtual Microsoft.EntityFrameworkCore.Metadata.RuntimeSkipNavigation AddSkipNavigation (string name, Microsoft.EntityFrameworkCore.Metadata.RuntimeEntityType targetEntityType, Microsoft.EntityFrameworkCore.Metadata.RuntimeForeignKey foreignKey, bool collection, bool onDependent, Type clrType, System.Reflection.PropertyInfo? propertyInfo = default, System.Reflection.FieldInfo? fieldInfo = default, Microsoft.EntityFrameworkCore.PropertyAccessMode propertyAccessMode = Microsoft.EntityFrameworkCore.PropertyAccessMode.PreferField, bool eagerLoaded = false);
abstract member AddSkipNavigation : string * Microsoft.EntityFrameworkCore.Metadata.RuntimeEntityType * Microsoft.EntityFrameworkCore.Metadata.RuntimeForeignKey * bool * bool * Type * System.Reflection.PropertyInfo * System.Reflection.FieldInfo * Microsoft.EntityFrameworkCore.PropertyAccessMode * bool -> Microsoft.EntityFrameworkCore.Metadata.RuntimeSkipNavigation
override this.AddSkipNavigation : string * Microsoft.EntityFrameworkCore.Metadata.RuntimeEntityType * Microsoft.EntityFrameworkCore.Metadata.RuntimeForeignKey * bool * bool * Type * System.Reflection.PropertyInfo * System.Reflection.FieldInfo * Microsoft.EntityFrameworkCore.PropertyAccessMode * bool -> Microsoft.EntityFrameworkCore.Metadata.RuntimeSkipNavigation
Public Overridable Function AddSkipNavigation (name As String, targetEntityType As RuntimeEntityType, foreignKey As RuntimeForeignKey, collection As Boolean, onDependent As Boolean, clrType As Type, Optional propertyInfo As PropertyInfo = Nothing, Optional fieldInfo As FieldInfo = Nothing, Optional propertyAccessMode As PropertyAccessMode = Microsoft.EntityFrameworkCore.PropertyAccessMode.PreferField, Optional eagerLoaded As Boolean = false) As RuntimeSkipNavigation

Parameters

name
String

The name of the skip navigation property to add.

targetEntityType
RuntimeEntityType

The entity type that the skip navigation property will hold an instance(s) of.

foreignKey
RuntimeForeignKey

The foreign key to the join type.

collection
Boolean

Whether the navigation property is a collection property.

onDependent
Boolean

Whether the navigation property is defined on the dependent side of the underlying foreign key.

clrType
Type

The type of value that this navigation holds.

propertyInfo
PropertyInfo

The corresponding CLR property or null for a shadow navigation.

fieldInfo
FieldInfo

The corresponding CLR field or null for a shadow navigation.

propertyAccessMode
PropertyAccessMode

The PropertyAccessMode used for this navigation.

eagerLoaded
Boolean

A value indicating whether this navigation should be eager loaded by default.

Returns

The newly created skip navigation property.

Applies to

AddSkipNavigation(String, RuntimeEntityType, RuntimeForeignKey, Boolean, Boolean, Type, PropertyInfo, FieldInfo, PropertyAccessMode, Boolean, Boolean)

Adds a new skip navigation property to this entity type.

public virtual Microsoft.EntityFrameworkCore.Metadata.RuntimeSkipNavigation AddSkipNavigation (string name, Microsoft.EntityFrameworkCore.Metadata.RuntimeEntityType targetEntityType, Microsoft.EntityFrameworkCore.Metadata.RuntimeForeignKey foreignKey, bool collection, bool onDependent, Type clrType, System.Reflection.PropertyInfo? propertyInfo = default, System.Reflection.FieldInfo? fieldInfo = default, Microsoft.EntityFrameworkCore.PropertyAccessMode propertyAccessMode = Microsoft.EntityFrameworkCore.PropertyAccessMode.PreferField, bool eagerLoaded = false, bool lazyLoadingEnabled = true);
abstract member AddSkipNavigation : string * Microsoft.EntityFrameworkCore.Metadata.RuntimeEntityType * Microsoft.EntityFrameworkCore.Metadata.RuntimeForeignKey * bool * bool * Type * System.Reflection.PropertyInfo * System.Reflection.FieldInfo * Microsoft.EntityFrameworkCore.PropertyAccessMode * bool * bool -> Microsoft.EntityFrameworkCore.Metadata.RuntimeSkipNavigation
override this.AddSkipNavigation : string * Microsoft.EntityFrameworkCore.Metadata.RuntimeEntityType * Microsoft.EntityFrameworkCore.Metadata.RuntimeForeignKey * bool * bool * Type * System.Reflection.PropertyInfo * System.Reflection.FieldInfo * Microsoft.EntityFrameworkCore.PropertyAccessMode * bool * bool -> Microsoft.EntityFrameworkCore.Metadata.RuntimeSkipNavigation
Public Overridable Function AddSkipNavigation (name As String, targetEntityType As RuntimeEntityType, foreignKey As RuntimeForeignKey, collection As Boolean, onDependent As Boolean, clrType As Type, Optional propertyInfo As PropertyInfo = Nothing, Optional fieldInfo As FieldInfo = Nothing, Optional propertyAccessMode As PropertyAccessMode = Microsoft.EntityFrameworkCore.PropertyAccessMode.PreferField, Optional eagerLoaded As Boolean = false, Optional lazyLoadingEnabled As Boolean = true) As RuntimeSkipNavigation

Parameters

name
String

The name of the skip navigation property to add.

targetEntityType
RuntimeEntityType

The entity type that the skip navigation property will hold an instance(s) of.

foreignKey
RuntimeForeignKey

The foreign key to the join type.

collection
Boolean

Whether the navigation property is a collection property.

onDependent
Boolean

Whether the navigation property is defined on the dependent side of the underlying foreign key.

clrType
Type

The type of value that this navigation holds.

propertyInfo
PropertyInfo

The corresponding CLR property or null for a shadow navigation.

fieldInfo
FieldInfo

The corresponding CLR field or null for a shadow navigation.

propertyAccessMode
PropertyAccessMode

The PropertyAccessMode used for this navigation.

eagerLoaded
Boolean

A value indicating whether this navigation should be eager loaded by default.

lazyLoadingEnabled
Boolean

A value indicating whether this navigation should be enabled for lazy-loading.

Returns

The newly created skip navigation property.

Applies to