# Class NpgsqlStringTypeMapping

Namespace
  Npgsql.EntityFrameworkCore.PostgreSQL.Storage.Internal.Mapping

Assembly
  Npgsql.EntityFrameworkCore.PostgreSQL.dll

The base class for mapping Npgsql-specific string types. It configures parameters with the NpgsqlDbType provider-specific type enum.

    public class NpgsqlStringTypeMapping : StringTypeMapping, INpgsqlTypeMapping

Inheritance
  object
  CoreTypeMapping
  RelationalTypeMapping
  StringTypeMapping
  NpgsqlStringTypeMapping

Implements
  INpgsqlTypeMapping

Derived
  NpgsqlCharacterStringTypeMapping
  NpgsqlLTreeTypeMapping

Inherited Members
  StringTypeMapping.EscapeSqlLiteral(string)
  StringTypeMapping.GenerateNonNullSqlLiteral(object)
  RelationalTypeMapping.NullMapping
  RelationalTypeMapping.Clone(CoreTypeMapping.CoreTypeMappingParameters)
  RelationalTypeMapping.WithStoreTypeAndSize(string, int?)
  RelationalTypeMapping.WithPrecisionAndScale(int?, int?)
  RelationalTypeMapping.WithComposedConverter(ValueConverter, ValueComparer, ValueComparer, CoreTypeMapping, JsonValueReaderWriter)
  RelationalTypeMapping.WithTypeMappingInfo(in RelationalTypeMappingInfo)
  RelationalTypeMapping.Clone(in RelationalTypeMappingInfo?, Type, ValueConverter, ValueComparer, ValueComparer, ValueComparer, CoreTypeMapping, JsonValueReaderWriter, StoreTypePostfix?)
  RelationalTypeMapping.ProcessStoreType(RelationalTypeMapping.RelationalTypeMappingParameters, string, string)
  RelationalTypeMapping.CreateParameter(DbCommand, string, object, bool?, ParameterDirection)
  RelationalTypeMapping.GenerateSqlLiteral(object)
  RelationalTypeMapping.GenerateProviderValueSqlLiteral(object)
  RelationalTypeMapping.GetDataReaderMethod()
  RelationalTypeMapping.GetDataReaderMethod(Type)
  RelationalTypeMapping.CustomizeDataReaderExpression(Expression)
  RelationalTypeMapping.Parameters
  RelationalTypeMapping.StoreTypePostfix
  RelationalTypeMapping.StoreType
  RelationalTypeMapping.StoreTypeNameBase
  RelationalTypeMapping.DbType
  RelationalTypeMapping.IsUnicode
  RelationalTypeMapping.Size
  RelationalTypeMapping.Precision
  RelationalTypeMapping.Scale
  RelationalTypeMapping.IsFixedLength
  RelationalTypeMapping.SqlLiteralFormatString
  CoreTypeMapping.Clone(in TypeMappingInfo?, Type, ValueConverter, ValueComparer, ValueComparer, ValueComparer, CoreTypeMapping, JsonValueReaderWriter)
  CoreTypeMapping.GenerateCodeLiteral(object)
  CoreTypeMapping.ClrType
  CoreTypeMapping.Converter
  CoreTypeMapping.ValueGeneratorFactory
  CoreTypeMapping.Comparer
  CoreTypeMapping.KeyComparer
  CoreTypeMapping.ProviderValueComparer
  CoreTypeMapping.ElementTypeMapping
  CoreTypeMapping.JsonValueReaderWriter
  object.Equals(object)
  object.Equals(object, object)
  object.GetHashCode()
  object.GetType()
  object.MemberwiseClone()
  object.ReferenceEquals(object, object)
  object.ToString()

## Constructors

### NpgsqlStringTypeMapping(RelationalTypeMappingParameters, NpgsqlDbType)

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

    protected NpgsqlStringTypeMapping(RelationalTypeMapping.RelationalTypeMappingParameters parameters, NpgsqlDbType npgsqlDbType)

#### Parameters

`parameters` RelationalTypeMapping.RelationalTypeMappingParameters
`npgsqlDbType` NpgsqlDbType

### NpgsqlStringTypeMapping(string, NpgsqlDbType)

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

    public NpgsqlStringTypeMapping(string storeType, NpgsqlDbType npgsqlDbType)

#### Parameters

`storeType` string
`npgsqlDbType` NpgsqlDbType

## Properties

### Default

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

    public static NpgsqlStringTypeMapping Default { get; }

#### Property Value

NpgsqlStringTypeMapping

### NpgsqlDbType

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

    public virtual NpgsqlDbType NpgsqlDbType { get; }

#### Property Value

NpgsqlDbType

## Methods

### Clone(RelationalTypeMappingParameters)

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

    protected override RelationalTypeMapping Clone(RelationalTypeMapping.RelationalTypeMappingParameters parameters)

#### Parameters

`parameters` RelationalTypeMapping.RelationalTypeMappingParameters

#### Returns

RelationalTypeMapping

### Clone(NpgsqlDbType)

This method exists only to support the compiled model.

    public virtual NpgsqlStringTypeMapping Clone(NpgsqlDbType npgsqlDbType)

#### Parameters

`npgsqlDbType` NpgsqlDbType

#### Returns

NpgsqlStringTypeMapping

#### Remarks

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

### ConfigureParameter(DbParameter)

This is an internal API that supports the Entity Framework Core infrastructure and not subject to the same compatibility standards as public APIs. It may be changed or removed without notice in any release. You should only use it directly in your code with extreme caution and knowing that doing so can result in application failures when updating to a new Entity Framework Core release.

    protected override void ConfigureParameter(DbParameter parameter)

#### Parameters

`parameter` DbParameter