C# Класс MicroLite.TypeConverters.TypeConverter

A class which allows access to ITypeConverters.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
For ( Type type ) : ITypeConverter

Gets the ITypeConverter for the specified type.

If For returns null, the TypeConverter.Default can be used.

IsNotEntityAndConvertible ( Type type ) : bool

Determines whether the type is not an entity type and is a convertible type.

RegisterTypeMapping ( Type type, DbType dbType ) : void

Registers the type mapping between a Type and DbType.

ResolveActualType ( Type type ) : Type

Resolves the actual type.

ResolveDbType ( Type type ) : DbType

Resolves the DbType mapped to the Type.

Описание методов

For() публичный статический Метод

Gets the ITypeConverter for the specified type.
If For returns null, the TypeConverter.Default can be used.
public static For ( Type type ) : ITypeConverter
type System.Type The type to get the converter for.
Результат ITypeConverter

IsNotEntityAndConvertible() публичный статический Метод

Determines whether the type is not an entity type and is a convertible type.
Thrown if type is null.
public static IsNotEntityAndConvertible ( Type type ) : bool
type System.Type The type to test.
Результат bool

RegisterTypeMapping() публичный статический Метод

Registers the type mapping between a Type and DbType.
public static RegisterTypeMapping ( Type type, DbType dbType ) : void
type System.Type The Type to be mapped.
dbType DbType The DbType to be mapped to.
Результат void

ResolveActualType() публичный статический Метод

Resolves the actual type.
Thrown if type is null.
public static ResolveActualType ( Type type ) : Type
type System.Type The type to resolve.
Результат System.Type

ResolveDbType() публичный статический Метод

Resolves the DbType mapped to the Type.
Thrown if the Type is not mapped to a DbType.
public static ResolveDbType ( Type type ) : DbType
type System.Type The Type to resolve the DbType from.
Результат DbType