StringToBytesConverter(Encoding, ConverterMappingHints) 构造函数

定义

创建此转换器的新实例。

public StringToBytesConverter (System.Text.Encoding encoding, Microsoft.EntityFrameworkCore.Storage.ValueConversion.ConverterMappingHints mappingHints = default);
public StringToBytesConverter (System.Text.Encoding encoding, Microsoft.EntityFrameworkCore.Storage.ValueConversion.ConverterMappingHints? mappingHints = default);
new Microsoft.EntityFrameworkCore.Storage.ValueConversion.StringToBytesConverter : System.Text.Encoding * Microsoft.EntityFrameworkCore.Storage.ValueConversion.ConverterMappingHints -> Microsoft.EntityFrameworkCore.Storage.ValueConversion.StringToBytesConverter
Public Sub New (encoding As Encoding, Optional mappingHints As ConverterMappingHints = Nothing)

参数

encoding
Encoding

要使用的字符串编码。

mappingHints
ConverterMappingHints

可用于 ITypeMappingSource 为转换的数据创建具有适当分面的数据类型的提示。

注解

有关详细信息和示例 ,请参阅 EF Core 值转换器

适用于