ConventionEntityTypeExtensions.FindForeignKeys Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
FindForeignKeys(IConventionEntityType, IProperty) |
Gets the foreign keys defined on the given property. Only foreign keys that are defined on exactly the specified property are returned. Composite foreign keys that include the specified property are not returned. |
FindForeignKeys(IConventionEntityType, IReadOnlyList<IProperty>) |
Gets the foreign keys defined on the given properties. Only foreign keys that are defined on exactly the specified set of properties are returned. |
FindForeignKeys(IConventionEntityType, IProperty)
Gets the foreign keys defined on the given property. Only foreign keys that are defined on exactly the specified property are returned. Composite foreign keys that include the specified property are not returned.
public static System.Collections.Generic.IEnumerable<Microsoft.EntityFrameworkCore.Metadata.IConventionForeignKey> FindForeignKeys (this Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType entityType, Microsoft.EntityFrameworkCore.Metadata.IProperty property);
static member FindForeignKeys : Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType * Microsoft.EntityFrameworkCore.Metadata.IProperty -> seq<Microsoft.EntityFrameworkCore.Metadata.IConventionForeignKey>
<Extension()>
Public Function FindForeignKeys (entityType As IConventionEntityType, property As IProperty) As IEnumerable(Of IConventionForeignKey)
Parameters
- entityType
- IConventionEntityType
The entity type.
- property
- IProperty
The property to find the foreign keys on.
Returns
The foreign keys.
Applies to
FindForeignKeys(IConventionEntityType, IReadOnlyList<IProperty>)
Gets the foreign keys defined on the given properties. Only foreign keys that are defined on exactly the specified set of properties are returned.
public static System.Collections.Generic.IEnumerable<Microsoft.EntityFrameworkCore.Metadata.IConventionForeignKey> FindForeignKeys (this Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType entityType, System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IProperty> properties);
static member FindForeignKeys : Microsoft.EntityFrameworkCore.Metadata.IConventionEntityType * System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IProperty> -> seq<Microsoft.EntityFrameworkCore.Metadata.IConventionForeignKey>
<Extension()>
Public Function FindForeignKeys (entityType As IConventionEntityType, properties As IReadOnlyList(Of IProperty)) As IEnumerable(Of IConventionForeignKey)
Parameters
- entityType
- IConventionEntityType
The entity type.
- properties
- IReadOnlyList<IProperty>
The properties to find the foreign keys on.
Returns
The foreign keys.
Applies to
Entity Framework
Feedback
https://aka.ms/ContentUserFeedback.
Kommer snart: Under hela 2024 kommer vi att fasa ut GitHub-problem som feedbackmekanism för innehåll och ersätta det med ett nytt feedbacksystem. Mer information finns i:Skicka och visa feedback för