Class TypeInfoMappingHelpers
public static class TypeInfoMappingHelpers
- Inheritance
-
TypeInfoMappingHelpers
- Inherited Members
Methods
CreateInfo(TypeInfoMapping, PgSerializerOptions, PgConverter)
Creates a PgTypeInfo from a mapping, optins, and a converter.
public static PgTypeInfo CreateInfo(this TypeInfoMapping mapping, PgSerializerOptions options, PgConverter converter)
Parameters
mapping
TypeInfoMappingThe mapping to create an info for.
options
PgSerializerOptionsThe options to use.
converter
PgConverterThe converter to create a PgTypeInfo for.
Returns
- PgTypeInfo
The created info instance.
CreateInfo(TypeInfoMapping, PgSerializerOptions, PgConverter, DataFormat?, bool)
Creates a PgTypeInfo from a mapping, options, and a converter.
public static PgTypeInfo CreateInfo(this TypeInfoMapping mapping, PgSerializerOptions options, PgConverter converter, DataFormat? preferredFormat = null, bool supportsWriting = true)
Parameters
mapping
TypeInfoMappingThe mapping to create an info for.
options
PgSerializerOptionsThe options to use.
converter
PgConverterThe converter to create a PgTypeInfo for.
preferredFormat
DataFormat?Whether to prefer a specific data format for this info, when null it defaults to the most suitable format.
supportsWriting
boolWhether the converters returned from the given converter resolver support writing.
Returns
- PgTypeInfo
The created info instance.
CreateInfo(TypeInfoMapping, PgSerializerOptions, PgConverterResolver, bool)
Creates a PgResolverTypeInfo from a mapping, options, and a converter resolver.
public static PgResolverTypeInfo CreateInfo(this TypeInfoMapping mapping, PgSerializerOptions options, PgConverterResolver resolver, bool includeDataTypeName)
Parameters
mapping
TypeInfoMappingThe mapping to create an info for.
options
PgSerializerOptionsThe options to use.
resolver
PgConverterResolverThe resolver to create a PgResolverTypeInfo for.
includeDataTypeName
boolWhether to pass mapping.DataTypeName to the PgResolverTypeInfo constructor, mandatory when TypeInfoFactory(..., requiresDataTypeName: true).
Returns
- PgResolverTypeInfo
The created info instance.
CreateInfo(TypeInfoMapping, PgSerializerOptions, PgConverterResolver, bool, DataFormat?, bool)
Creates a PgResolverTypeInfo from a mapping, options, and a converter resolver.
public static PgResolverTypeInfo CreateInfo(this TypeInfoMapping mapping, PgSerializerOptions options, PgConverterResolver resolver, bool includeDataTypeName, DataFormat? preferredFormat = null, bool supportsWriting = true)
Parameters
mapping
TypeInfoMappingThe mapping to create an info for.
options
PgSerializerOptionsThe options to use.
resolver
PgConverterResolverThe converter resolver to create a PgResolverTypeInfo for.
includeDataTypeName
boolWhether to pass mapping.DataTypeName to the PgResolverTypeInfo constructor, mandatory when TypeInfoFactory(..., requiresDataTypeName: true).
preferredFormat
DataFormat?Whether to prefer a specific data format for this info, when null it defaults to the most suitable format.
supportsWriting
boolWhether the converters returned from the given converter resolver support writing.
Returns
- PgResolverTypeInfo
The created info instance.