Table of Contents

Class ValueConverter<TModel, TProvider>

Namespace
LinqToDB.Common
Assembly
linq2db.dll
public class ValueConverter<TModel, TProvider> : IValueConverter

Type Parameters

TModel
TProvider
Inheritance
ValueConverter<TModel, TProvider>
Implements
Extension Methods

Constructors

ValueConverter(Expression<Func<TModel, TProvider>>, Expression<Func<TProvider, TModel>>, bool)

public ValueConverter(Expression<Func<TModel, TProvider>> convertToProviderExpression, Expression<Func<TProvider, TModel>> convertFromProviderExpression, bool handlesNulls)

Parameters

convertToProviderExpression Expression<Func<TModel, TProvider>>
convertFromProviderExpression Expression<Func<TProvider, TModel>>
handlesNulls bool

Properties

FromProviderExpression

Gets the expression to convert objects when reading data from the database.

public LambdaExpression FromProviderExpression { get; }

Property Value

LambdaExpression

HandlesNulls

Identifies that convert expressions can handle null values.

public bool HandlesNulls { get; }

Property Value

bool

ToProviderExpression

Gets the expression to convert objects when writing data to the database.

public LambdaExpression ToProviderExpression { get; }

Property Value

LambdaExpression