Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions src/Npgsql/Internal/TypeHandlers/BitStringHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ namespace Npgsql.Internal.TypeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("bit varying", NpgsqlDbType.Varbit, new[] { typeof(BitArray), typeof(BitVector32) })]
[TypeMapping("bit", NpgsqlDbType.Bit)]
public class BitStringHandler : NpgsqlTypeHandler<BitArray>,
INpgsqlTypeHandler<BitVector32>, INpgsqlTypeHandler<bool>, INpgsqlTypeHandler<string>
{
Expand Down
1 change: 0 additions & 1 deletion src/Npgsql/Internal/TypeHandlers/BoolHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace Npgsql.Internal.TypeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("boolean", NpgsqlDbType.Boolean, DbType.Boolean, typeof(bool))]
public class BoolHandler : NpgsqlSimpleTypeHandler<bool>
{
/// <inheritdoc />
Expand Down
12 changes: 0 additions & 12 deletions src/Npgsql/Internal/TypeHandlers/ByteaHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,18 +20,6 @@ namespace Npgsql.Internal.TypeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping(
"bytea",
NpgsqlDbType.Bytea,
DbType.Binary,
new[] {
typeof(byte[]),
typeof(ArraySegment<byte>),
#if !NETSTANDARD2_0
typeof(ReadOnlyMemory<byte>),
typeof(Memory<byte>)
#endif
})]
public class ByteaHandler : NpgsqlTypeHandler<byte[]>, INpgsqlTypeHandler<ArraySegment<byte>>
#if !NETSTANDARD2_0
, INpgsqlTypeHandler<ReadOnlyMemory<byte>>, INpgsqlTypeHandler<Memory<byte>>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ namespace Npgsql.Internal.TypeHandlers.DateTimeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("date", NpgsqlDbType.Date, DbType.Date, typeof(NpgsqlDate))]
public class DateHandlerFactory : NpgsqlTypeHandlerFactory<DateTime>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace Npgsql.Internal.TypeHandlers.DateTimeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("interval", NpgsqlDbType.Interval, new[] { typeof(TimeSpan), typeof(NpgsqlTimeSpan) })]
public class IntervalHandlerFactory : NpgsqlTypeHandlerFactory<TimeSpan>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ namespace Npgsql.Internal.TypeHandlers.DateTimeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("time without time zone", NpgsqlDbType.Time, new[] { DbType.Time })]
public class TimeHandlerFactory : NpgsqlTypeHandlerFactory<TimeSpan>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace Npgsql.Internal.TypeHandlers.DateTimeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("time with time zone", NpgsqlDbType.TimeTz)]
public class TimeTzHandlerFactory : NpgsqlTypeHandlerFactory<DateTimeOffset>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ namespace Npgsql.Internal.TypeHandlers.DateTimeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("timestamp without time zone", NpgsqlDbType.Timestamp, new[] { DbType.DateTime, DbType.DateTime2 }, new[] { typeof(NpgsqlDateTime), typeof(DateTime) }, DbType.DateTime)]
public class TimestampHandlerFactory : NpgsqlTypeHandlerFactory<DateTime>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ namespace Npgsql.Internal.TypeHandlers.DateTimeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("timestamp with time zone", NpgsqlDbType.TimestampTz, DbType.DateTimeOffset, typeof(DateTimeOffset))]
public class TimestampTzHandlerFactory : NpgsqlTypeHandlerFactory<DateTime>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ namespace Npgsql.Internal.TypeHandlers.FullTextSearchHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("tsquery", NpgsqlDbType.TsQuery, new[] {
typeof(NpgsqlTsQuery), typeof(NpgsqlTsQueryAnd), typeof(NpgsqlTsQueryEmpty), typeof(NpgsqlTsQueryFollowedBy),
typeof(NpgsqlTsQueryLexeme), typeof(NpgsqlTsQueryNot), typeof(NpgsqlTsQueryOr), typeof(NpgsqlTsQueryBinOp) })
]
public class TsQueryHandler : NpgsqlTypeHandler<NpgsqlTsQuery>,
INpgsqlTypeHandler<NpgsqlTsQueryEmpty>, INpgsqlTypeHandler<NpgsqlTsQueryLexeme>,
INpgsqlTypeHandler<NpgsqlTsQueryNot>, INpgsqlTypeHandler<NpgsqlTsQueryAnd>,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ namespace Npgsql.Internal.TypeHandlers.FullTextSearchHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("tsvector", NpgsqlDbType.TsVector, typeof(NpgsqlTsVector))]
public class TsVectorHandler : NpgsqlTypeHandler<NpgsqlTsVector>
{
// 2561 = 2046 (max length lexeme string) + (1) null terminator +
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ namespace Npgsql.Internal.TypeHandlers.GeometricHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("box", NpgsqlDbType.Box, typeof(NpgsqlBox))]
public class BoxHandler : NpgsqlSimpleTypeHandler<NpgsqlBox>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ namespace Npgsql.Internal.TypeHandlers.GeometricHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("circle", NpgsqlDbType.Circle, typeof(NpgsqlCircle))]
public class CircleHandler : NpgsqlSimpleTypeHandler<NpgsqlCircle>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ namespace Npgsql.Internal.TypeHandlers.GeometricHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("line", NpgsqlDbType.Line, typeof(NpgsqlLine))]
public class LineHandler : NpgsqlSimpleTypeHandler<NpgsqlLine>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ namespace Npgsql.Internal.TypeHandlers.GeometricHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("lseg", NpgsqlDbType.LSeg, typeof(NpgsqlLSeg))]
public class LineSegmentHandler : NpgsqlSimpleTypeHandler<NpgsqlLSeg>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ namespace Npgsql.Internal.TypeHandlers.GeometricHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("path", NpgsqlDbType.Path, typeof(NpgsqlPath))]
public class PathHandler : NpgsqlTypeHandler<NpgsqlPath>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ namespace Npgsql.Internal.TypeHandlers.GeometricHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("point", NpgsqlDbType.Point, typeof(NpgsqlPoint))]
public class PointHandler : NpgsqlSimpleTypeHandler<NpgsqlPoint>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ namespace Npgsql.Internal.TypeHandlers.GeometricHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("polygon", NpgsqlDbType.Polygon, typeof(NpgsqlPolygon))]
public class PolygonHandler : NpgsqlTypeHandler<NpgsqlPolygon>
{
/// <inheritdoc />
Expand Down
10 changes: 1 addition & 9 deletions src/Npgsql/Internal/TypeHandlers/HstoreHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,6 @@ namespace Npgsql.Internal.TypeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("hstore", NpgsqlDbType.Hstore, new[]
{
typeof(Dictionary<string, string?>),
typeof(IDictionary<string, string?>),
#if !NETSTANDARD2_0 && !NETSTANDARD2_1
typeof(ImmutableDictionary<string, string?>)
#endif
})]
public class HstoreHandlerFactory : NpgsqlTypeHandlerFactory<Dictionary<string, string?>>
{
/// <inheritdoc />
Expand Down Expand Up @@ -92,7 +84,7 @@ public int ValidateAndGetLength(IDictionary<string, string?> value, ref NpgsqlLe
totalLen += _textHandler.ValidateAndGetLength(kv.Value!, ref lengthCache, null);
}

return lengthCache.Lengths[pos] = totalLen;
return lengthCache!.Lengths[pos] = totalLen;
}

/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

namespace Npgsql.Internal.TypeHandlers.InternalTypeHandlers
{
[TypeMapping("int2vector", NpgsqlDbType.Int2Vector)]
class Int2VectorHandlerFactory : NpgsqlTypeHandlerFactory
{
public override NpgsqlTypeHandler CreateNonGeneric(PostgresType pgType, NpgsqlConnection conn)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
using Npgsql.BackendMessages;
using Npgsql.Internal.TypeHandling;
using Npgsql.PostgresTypes;
using Npgsql.TypeMapping;
using NpgsqlTypes;

namespace Npgsql.Internal.TypeHandlers
namespace Npgsql.Internal.TypeHandlers.InternalTypeHandlers
{
/// <summary>
/// A type handler for the PostgreSQL "char" type, used only internally.
Expand All @@ -16,7 +14,6 @@ namespace Npgsql.Internal.TypeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("char", NpgsqlDbType.InternalChar)]
public class InternalCharHandler : NpgsqlSimpleTypeHandler<char>,
INpgsqlSimpleTypeHandler<byte>, INpgsqlSimpleTypeHandler<short>, INpgsqlSimpleTypeHandler<int>, INpgsqlSimpleTypeHandler<long>
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

namespace Npgsql.Internal.TypeHandlers.InternalTypeHandlers
{
[TypeMapping("oidvector", NpgsqlDbType.Oidvector)]
class OIDVectorHandlerFactory : NpgsqlTypeHandlerFactory
{
public override NpgsqlTypeHandler CreateNonGeneric(PostgresType pgType, NpgsqlConnection conn)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,10 @@
using Npgsql.BackendMessages;
using Npgsql.Internal.TypeHandling;
using Npgsql.PostgresTypes;
using Npgsql.TypeMapping;
using NpgsqlTypes;

namespace Npgsql.Internal.TypeHandlers.InternalTypeHandlers
{
[TypeMapping("pg_lsn", NpgsqlDbType.PgLsn, typeof(NpgsqlLogSequenceNumber))]
class PgLsnHandler : NpgsqlSimpleTypeHandler<NpgsqlLogSequenceNumber>
{
public PgLsnHandler(PostgresType postgresType) : base(postgresType) {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

namespace Npgsql.Internal.TypeHandlers.InternalTypeHandlers
{
[TypeMapping("tid", NpgsqlDbType.Tid, typeof(NpgsqlTid))]
class TidHandler : NpgsqlSimpleTypeHandler<NpgsqlTid>
{
public TidHandler(PostgresType postgresType) : base(postgresType) {}
Expand Down
2 changes: 0 additions & 2 deletions src/Npgsql/Internal/TypeHandlers/JsonHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ namespace Npgsql.Internal.TypeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("jsonb", NpgsqlDbType.Jsonb, typeof(JsonDocument))]
public class JsonbHandlerFactory : NpgsqlTypeHandlerFactory<string>
{
readonly JsonSerializerOptions? _serializerOptions;
Expand All @@ -48,7 +47,6 @@ public override NpgsqlTypeHandler<string> Create(PostgresType postgresType, Npgs
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("json", NpgsqlDbType.Json)]
public class JsonHandlerFactory : NpgsqlTypeHandlerFactory<string>
{
readonly JsonSerializerOptions? _serializerOptions;
Expand Down
1 change: 0 additions & 1 deletion src/Npgsql/Internal/TypeHandlers/JsonPathHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ namespace Npgsql.Internal.TypeHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("jsonpath", NpgsqlDbType.JsonPath)]
public class JsonPathHandlerFactory : NpgsqlTypeHandlerFactory<string>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,9 @@
using Npgsql.BackendMessages;
using Npgsql.Internal.TypeHandling;
using Npgsql.PostgresTypes;
using Npgsql.TypeMapping;
using NpgsqlTypes;

namespace Npgsql.Internal.TypeHandlers
namespace Npgsql.Internal.TypeHandlers.LTreeHandlers
{
[TypeMapping("lquery", NpgsqlDbType.LQuery)]
class LQueryHandlerFactory : NpgsqlTypeHandlerFactory<string>
{
public override NpgsqlTypeHandler<string> Create(PostgresType postgresType, NpgsqlConnection conn)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,9 @@
using Npgsql.BackendMessages;
using Npgsql.Internal.TypeHandling;
using Npgsql.PostgresTypes;
using Npgsql.TypeMapping;
using NpgsqlTypes;

namespace Npgsql.Internal.TypeHandlers
namespace Npgsql.Internal.TypeHandlers.LTreeHandlers
{
[TypeMapping("ltree", NpgsqlDbType.LTree)]
class LTreeHandlerFactory : NpgsqlTypeHandlerFactory<string>
{
public override NpgsqlTypeHandler<string> Create(PostgresType postgresType, NpgsqlConnection conn)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,9 @@
using Npgsql.BackendMessages;
using Npgsql.Internal.TypeHandling;
using Npgsql.PostgresTypes;
using Npgsql.TypeMapping;
using NpgsqlTypes;

namespace Npgsql.Internal.TypeHandlers
namespace Npgsql.Internal.TypeHandlers.LTreeHandlers
{
[TypeMapping("ltxtquery", NpgsqlDbType.LTxtQuery)]
class LTxtQueryHandlerFactory : NpgsqlTypeHandlerFactory<string>
{
public override NpgsqlTypeHandler<string> Create(PostgresType postgresType, NpgsqlConnection conn)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ namespace Npgsql.Internal.TypeHandlers.NetworkHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("cidr", NpgsqlDbType.Cidr)]
public class CidrHandler : NpgsqlSimpleTypeHandler<(IPAddress Address, int Subnet)>, INpgsqlSimpleTypeHandler<NpgsqlInet>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,6 @@ namespace Npgsql.Internal.TypeHandlers.NetworkHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping(
"inet",
NpgsqlDbType.Inet,
new[] { typeof(IPAddress), typeof((IPAddress Address, int Subnet)), typeof(NpgsqlInet) })]
public class InetHandler : NpgsqlSimpleTypeHandlerWithPsv<IPAddress, (IPAddress Address, int Subnet)>,
INpgsqlSimpleTypeHandler<NpgsqlInet>
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ namespace Npgsql.Internal.TypeHandlers.NetworkHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("macaddr8", NpgsqlDbType.MacAddr8)]
[TypeMapping("macaddr", NpgsqlDbType.MacAddr, typeof(PhysicalAddress))]
public class MacaddrHandler : NpgsqlSimpleTypeHandler<PhysicalAddress>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace Npgsql.Internal.TypeHandlers.NumericHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("double precision", NpgsqlDbType.Double, DbType.Double, typeof(double))]
public class DoubleHandler : NpgsqlSimpleTypeHandler<double>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace Npgsql.Internal.TypeHandlers.NumericHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("smallint", NpgsqlDbType.Smallint, new[] { DbType.Int16, DbType.Byte, DbType.SByte }, new[] { typeof(short), typeof(byte), typeof(sbyte) }, DbType.Int16)]
public class Int16Handler : NpgsqlSimpleTypeHandler<short>,
INpgsqlSimpleTypeHandler<byte>, INpgsqlSimpleTypeHandler<sbyte>, INpgsqlSimpleTypeHandler<int>, INpgsqlSimpleTypeHandler<long>,
INpgsqlSimpleTypeHandler<float>, INpgsqlSimpleTypeHandler<double>, INpgsqlSimpleTypeHandler<decimal>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace Npgsql.Internal.TypeHandlers.NumericHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("integer", NpgsqlDbType.Integer, DbType.Int32, typeof(int))]
public class Int32Handler : NpgsqlSimpleTypeHandler<int>,
INpgsqlSimpleTypeHandler<byte>, INpgsqlSimpleTypeHandler<short>, INpgsqlSimpleTypeHandler<long>,
INpgsqlSimpleTypeHandler<float>, INpgsqlSimpleTypeHandler<double>, INpgsqlSimpleTypeHandler<decimal>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace Npgsql.Internal.TypeHandlers.NumericHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("bigint", NpgsqlDbType.Bigint, DbType.Int64, typeof(long))]
public class Int64Handler : NpgsqlSimpleTypeHandler<long>,
INpgsqlSimpleTypeHandler<byte>, INpgsqlSimpleTypeHandler<short>, INpgsqlSimpleTypeHandler<int>,
INpgsqlSimpleTypeHandler<float>, INpgsqlSimpleTypeHandler<double>, INpgsqlSimpleTypeHandler<decimal>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ namespace Npgsql.Internal.TypeHandlers.NumericHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("money", NpgsqlDbType.Money, dbType: DbType.Currency)]
public class MoneyHandler : NpgsqlSimpleTypeHandler<decimal>
{
const int MoneyScale = 2;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ namespace Npgsql.Internal.TypeHandlers.NumericHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("numeric", NpgsqlDbType.Numeric, new[] { DbType.Decimal, DbType.VarNumeric }, typeof(decimal), DbType.Decimal)]
public class NumericHandler : NpgsqlSimpleTypeHandler<decimal>,
INpgsqlSimpleTypeHandler<byte>, INpgsqlSimpleTypeHandler<short>, INpgsqlSimpleTypeHandler<int>, INpgsqlSimpleTypeHandler<long>,
INpgsqlSimpleTypeHandler<float>, INpgsqlSimpleTypeHandler<double>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace Npgsql.Internal.TypeHandlers.NumericHandlers
/// should be considered somewhat unstable, and may change in breaking ways, including in non-major releases.
/// Use it at your own risk.
/// </remarks>
[TypeMapping("real", NpgsqlDbType.Real, DbType.Single, typeof(float))]
public class SingleHandler : NpgsqlSimpleTypeHandler<float>, INpgsqlSimpleTypeHandler<double>
{
/// <inheritdoc />
Expand Down
Loading