語言

IConventionRelationshipBuilder.HasPrincipalKey 方法

定義

多載

名稱 Description
HasPrincipalKey(IReadOnlyList<IConventionProperty>, Boolean)

配置此關係所針對的屬性。

HasPrincipalKey(IReadOnlyList<String>, Boolean)

配置此關係所針對的屬性。

HasPrincipalKey(IReadOnlyList<IConventionProperty>, Boolean)

配置此關係所針對的屬性。

public Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionRelationshipBuilder HasPrincipalKey(System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IConventionProperty> properties, bool fromDataAnnotation = false);
abstract member HasPrincipalKey : System.Collections.Generic.IReadOnlyList<Microsoft.EntityFrameworkCore.Metadata.IConventionProperty> * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionRelationshipBuilder
Public Function HasPrincipalKey (properties As IReadOnlyList(Of IConventionProperty), Optional fromDataAnnotation As Boolean = false) As IConventionRelationshipBuilder

參數

properties
IReadOnlyList<IConventionProperty>

這段關係的屬性是要瞄準的。

fromDataAnnotation
Boolean

表示配置是否以資料註解方式指定。

傳回

如果屬性被設定為這個關係的目標,則是同一個建構器實例, null 否則。

適用於

HasPrincipalKey(IReadOnlyList<String>, Boolean)

配置此關係所針對的屬性。

public Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionRelationshipBuilder HasPrincipalKey(System.Collections.Generic.IReadOnlyList<string> propertyNames, bool fromDataAnnotation = false);
abstract member HasPrincipalKey : System.Collections.Generic.IReadOnlyList<string> * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionRelationshipBuilder
Public Function HasPrincipalKey (propertyNames As IReadOnlyList(Of String), Optional fromDataAnnotation As Boolean = false) As IConventionRelationshipBuilder

參數

propertyNames
IReadOnlyList<String>

這段關係的屬性是要瞄準的。

fromDataAnnotation
Boolean

表示配置是否以資料註解方式指定。

傳回

如果屬性被設定為這個關係的目標,則是同一個建構器實例, null 否則。

適用於