Delen via


IConventionProperty.SetValueConverter Method

Definition

Overloads

SetValueConverter(ValueConverter, Boolean)

Sets the custom ValueConverter for this property.

SetValueConverter(Type, Boolean)

Sets the custom ValueConverter for this property.

SetValueConverter(ValueConverter, Boolean)

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

Sets the custom ValueConverter for this property.

public Microsoft.EntityFrameworkCore.Storage.ValueConversion.ValueConverter? SetValueConverter (Microsoft.EntityFrameworkCore.Storage.ValueConversion.ValueConverter? converter, bool fromDataAnnotation = false);
abstract member SetValueConverter : Microsoft.EntityFrameworkCore.Storage.ValueConversion.ValueConverter * bool -> Microsoft.EntityFrameworkCore.Storage.ValueConversion.ValueConverter
Public Function SetValueConverter (converter As ValueConverter, Optional fromDataAnnotation As Boolean = false) As ValueConverter

Parameters

converter
ValueConverter

The converter, or null to remove any previously set converter.

fromDataAnnotation
Boolean

Indicates whether the configuration was specified using a data annotation.

Returns

The configured value.

Applies to

SetValueConverter(Type, Boolean)

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

Sets the custom ValueConverter for this property.

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

Parameters

converterType
Type

A type that inherits from ValueConverter, or null to remove any previously set converter.

fromDataAnnotation
Boolean

Indicates whether the configuration was specified using a data annotation.

Returns

The configured value.

Applies to