다음을 통해 공유


ConventionPropertyExtensions.SetKeyValueComparer 메서드

정의

주의

Use SetValueComparer. Only a single value comparer is allowed for a given property.

키 비교를 수행할 때 이 속성에 대한 사용자 지정 ValueComparer 을 설정합니다.

public static void SetKeyValueComparer (this Microsoft.EntityFrameworkCore.Metadata.IConventionProperty property, Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer comparer, bool fromDataAnnotation = false);
[System.Obsolete("Use SetValueComparer. Only a single value comparer is allowed for a given property.")]
public static void SetKeyValueComparer (this Microsoft.EntityFrameworkCore.Metadata.IConventionProperty property, Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer comparer, bool fromDataAnnotation = false);
[System.Obsolete("Use SetValueComparer. Only a single value comparer is allowed for a given property.")]
public static void SetKeyValueComparer (this Microsoft.EntityFrameworkCore.Metadata.IConventionProperty property, Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer? comparer, bool fromDataAnnotation = false);
static member SetKeyValueComparer : Microsoft.EntityFrameworkCore.Metadata.IConventionProperty * Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer * bool -> unit
[<System.Obsolete("Use SetValueComparer. Only a single value comparer is allowed for a given property.")>]
static member SetKeyValueComparer : Microsoft.EntityFrameworkCore.Metadata.IConventionProperty * Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer * bool -> unit
<Extension()>
Public Sub SetKeyValueComparer (property As IConventionProperty, comparer As ValueComparer, Optional fromDataAnnotation As Boolean = false)

매개 변수

property
IConventionProperty

속성입니다.

comparer
ValueComparer

비교자 또는 null 이전에 설정된 비교자를 제거합니다.

fromDataAnnotation
Boolean

데이터 주석을 사용하여 구성을 지정했는지 여부를 나타냅니다.

특성

적용 대상