Share via


IEntityMaterializerSource Interface

Definition

Caution

This interface has been obsoleted, use IStructuralTypeMaterializerSource instead.

This interface has been obsoleted, use IStructuralTypeMaterializerSource instead.

[System.Obsolete("This interface has been obsoleted, use IStructuralTypeMaterializerSource instead.", true)]
public interface IEntityMaterializerSource
public interface IEntityMaterializerSource
[<System.Obsolete("This interface has been obsoleted, use IStructuralTypeMaterializerSource instead.", true)>]
type IEntityMaterializerSource = interface
type IEntityMaterializerSource = interface
Public Interface IEntityMaterializerSource
Derived
Attributes

Remarks

The service lifetime is Singleton. This means a single instance is used by many DbContext instances. The implementation must be thread-safe. This service cannot depend on services registered as Scoped.

See Implementation of database providers and extensions and How EF Core queries work for more information and examples.

Methods

Name Description
CreateMaterializeExpression(EntityMaterializerSourceParameters, Expression)

Creates an Expression tree representing creating an entity instance.

This method is typically used by database providers (and other extensions). It is generally not used in application code.

CreateMaterializeExpression(IEntityType, String, Expression)
Obsolete.

Creates an Expression tree representing creating an entity instance.

This method is typically used by database providers (and other extensions). It is generally not used in application code.

CreateReadValueExpression(Expression, Type, Int32, IPropertyBase)

Creates an Expression tree representing reading a value from a ValueBuffer

This method is typically used by database providers (and other extensions). It is generally not used in application code.

GetEmptyMaterializer(IEntityType)

Returns a cached delegate that creates empty instances of the given entity type.

This method is typically used by database providers (and other extensions). It is generally not used in application code.

GetMaterializer(IEntityType)

Returns a cached delegate that creates instances of the given entity type.

This method is typically used by database providers (and other extensions). It is generally not used in application code.

Applies to