IConventionPropertyBuilder.HasStructuralValueComparer 方法

定义

注意

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

ValueComparer 配置为用于此属性的结构比较。

public Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder HasStructuralValueComparer (Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer comparer, bool fromDataAnnotation = false);
[System.Obsolete("Use HasValueComparer. Only a single value comparer is allowed for a given property.")]
public Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder HasStructuralValueComparer (Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer comparer, bool fromDataAnnotation = false);
[System.Obsolete("Use HasValueComparer. Only a single value comparer is allowed for a given property.")]
public Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder? HasStructuralValueComparer (Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer? comparer, bool fromDataAnnotation = false);
abstract member HasStructuralValueComparer : Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder
[<System.Obsolete("Use HasValueComparer. Only a single value comparer is allowed for a given property.")>]
abstract member HasStructuralValueComparer : Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer * bool -> Microsoft.EntityFrameworkCore.Metadata.Builders.IConventionPropertyBuilder
Public Function HasStructuralValueComparer (comparer As ValueComparer, Optional fromDataAnnotation As Boolean = false) As IConventionPropertyBuilder

参数

comparer
ValueComparer

比较器,或者 null 删除任何以前设置的比较器。

fromDataAnnotation
Boolean

指示是否使用数据注释指定配置。

返回

如果应用了配置,则为同一生成器实例, null 否则为 。

属性

适用于