Skip to content

DbProviderTypeMapBase`1 ​

Namespace: MJCZone.DapperMatic.Providers

Assembly: MJCZone.DapperMatic

Summary ​

Manages mappings between .NET types and database types.

Inheritance ​

Implemented Interfaces:

abstract public

Note: This is an abstract base class. Concrete implementations can be found in provider-specific namespaces.

Contents ​

Methods (11)

Methods ​

MethodSummary
TryGetDotnetTypeDescriptorMatchingFullSqlTypeNameTries to get the .NET type descriptor that matches the specified full SQL type name.
TryGetDotnetTypeDescriptorMatchingFullSqlTypeNameTries to get the .NET type descriptor that matches the specified SQL type descriptor.
TryGetProviderSqlTypeMatchingDotnetTypeTries to get the SQL type descriptor that matches the specified .NET type.
TryGetProviderSqlTypeMatchingDotnetTypeTries to get the SQL type descriptor that matches the specified .NET type descriptor.
RegisterConverterRegisters a converter for a given .NET type to a SQL type.
RegisterConverterRegisters a converter for a given .NET type to a SQL type.
RegisterConverterRegisters a converter for a given SQL type to a .NET type.
GetType
ToString
Equals
GetHashCode

TryGetDotnetTypeDescriptorMatchingFullSqlTypeName ​

Tries to get the .NET type descriptor that matches the specified full SQL type name.

csharp
void TryGetDotnetTypeDescriptorMatchingFullSqlTypeName(string sqlTypeName, DotnetTypeDescriptor dotnetTypeDescriptor)

Parameters ​

  • sqlTypeName (string) - The full SQL type name.
  • dotnetTypeDescriptor (DotnetTypeDescriptor) - The .NET type descriptor, if found.

Returns ​

True if a matching .NET type descriptor is found; otherwise, false.

TryGetDotnetTypeDescriptorMatchingFullSqlTypeName ​

Tries to get the .NET type descriptor that matches the specified SQL type descriptor.

csharp
void TryGetDotnetTypeDescriptorMatchingFullSqlTypeName(SqlTypeDescriptor sqlTypeDescriptor, DotnetTypeDescriptor dotnetTypeDescriptor)

Parameters ​

Returns ​

True if a matching .NET type descriptor is found; otherwise, false.

TryGetProviderSqlTypeMatchingDotnetType ​

Tries to get the SQL type descriptor that matches the specified .NET type.

csharp
void TryGetProviderSqlTypeMatchingDotnetType(Type type, SqlTypeDescriptor sqlTypeDescriptor)

Parameters ​

  • type (Type) - The .NET type.
  • sqlTypeDescriptor (SqlTypeDescriptor) - The SQL type descriptor, if found.

Returns ​

True if a matching SQL type descriptor is found; otherwise, false.

TryGetProviderSqlTypeMatchingDotnetType ​

Tries to get the SQL type descriptor that matches the specified .NET type descriptor.

csharp
void TryGetProviderSqlTypeMatchingDotnetType(DotnetTypeDescriptor dotnetTypeDescriptor, SqlTypeDescriptor sqlTypeDescriptor)

Parameters ​

Returns ​

True if a matching SQL type descriptor is found; otherwise, false.

RegisterConverter ​

Registers a converter for a given .NET type to a SQL type.

csharp
void RegisterConverter(Type type, DotnetTypeToSqlTypeConverter converter, bool prepend)

Parameters ​

  • type (Type) - The .NET type to convert to a SQL type.
  • converter (DotnetTypeToSqlTypeConverter) - The converter to register.
  • prepend (bool) - Whether to prepend the converter to the list of converters.

RegisterConverter ​

Registers a converter for a given .NET type to a SQL type.

csharp
void RegisterConverter(DotnetTypeToSqlTypeConverter converter)

Parameters ​

RegisterConverter ​

Registers a converter for a given SQL type to a .NET type.

csharp
void RegisterConverter(string baseTypeName, SqlTypeToDotnetTypeConverter converter, bool prepend)

Parameters ​

  • baseTypeName (string) - The base type name to convert to a .NET type.
  • converter (SqlTypeToDotnetTypeConverter) - The converter to register.
  • prepend (bool) - Whether to prepend the converter to the list of converters.

GetType ​

csharp
void GetType()

ToString ​

csharp
void ToString()

Equals ​

csharp
void Equals()

GetHashCode ​

csharp
void GetHashCode()