IConventionProperty.SetValueComparer 方法

定义

重载

SetValueComparer(ValueComparer, Boolean)

设置此属性的自定义 ValueComparer

SetValueComparer(Type, Boolean)

设置此属性的自定义 ValueComparer

SetValueComparer(ValueComparer, Boolean)

Source:
IConventionProperty.cs
Source:
IConventionProperty.cs
Source:
IConventionProperty.cs
Source:
IConventionProperty.cs

设置此属性的自定义 ValueComparer

public Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer? SetValueComparer (Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer? comparer, bool fromDataAnnotation = false);
abstract member SetValueComparer : Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer * bool -> Microsoft.EntityFrameworkCore.ChangeTracking.ValueComparer
Public Function SetValueComparer (comparer As ValueComparer, Optional fromDataAnnotation As Boolean = false) As ValueComparer

参数

comparer
ValueComparer

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

fromDataAnnotation
Boolean

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

返回

配置的值。

适用于

SetValueComparer(Type, Boolean)

Source:
IConventionProperty.cs
Source:
IConventionProperty.cs
Source:
IConventionProperty.cs
Source:
IConventionProperty.cs

设置此属性的自定义 ValueComparer

public Type? SetValueComparer (Type? comparerType, bool fromDataAnnotation = false);
abstract member SetValueComparer : Type * bool -> Type
Public Function SetValueComparer (comparerType As Type, Optional fromDataAnnotation As Boolean = false) As Type

参数

comparerType
Type

继承自 ValueComparer的类型,或 null 用于删除任何以前设置的比较器。

fromDataAnnotation
Boolean

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

返回

配置的值。

适用于