Show / Hide Table of Contents

Class LLBLGenDataContext

A data context for the LLBLGen infrastructure.

Inheritance
System.Object
System.Dynamic.DynamicObject
ExpandoBase
Expando
Context
DataContextBase
LLBLGenDataContext
Implements
ILLBLGenDataContext
IDataContext
IContext
IExpando
System.Dynamic.IDynamicMetaObjectProvider
IIndexable
ILoggable
IIdentifiable
System.IDisposable
IInitializable
Inherited Members
DataContextBase.InitializationMonitor
DataContextBase.Id
DataContextBase.EntityActivator
DataContextBase.Initialize(IContext)
DataContextBase.Query<T>(IQueryOperationContext)
DataContextBase.CreateCommand(Type)
DataContextBase.GetEntityEntry(Object)
DataContextBase.Attach(Object)
DataContextBase.Detach(IEntityEntry)
DataContextBase.GetIdEqualityExpression<T>(Object)
DataContextBase.Initialize(IDataInitializationContext)
DataContextBase.AttachCore(Object, Boolean)
DataContextBase.DetachCore(IEntityEntry, Boolean)
Context.AmbientServices
Context.CompositionContext
Context.Identity
Context.Logger
Context.Dispose()
Context.ValidateIdentity(IIdentity, IIdentity)
Context.SetCompositionContext(ICompositionContext)
Context.SetAmbientServices(IAmbientServices)
Context.Dispose(Boolean)
ExpandoBase.Item[String]
ExpandoBase.GetDynamicMemberNames()
ExpandoBase.HasDynamicMember(String)
ExpandoBase.TryGetMember(GetMemberBinder, Object)
ExpandoBase.TrySetMember(SetMemberBinder, Object)
ExpandoBase.TryInvokeMember(InvokeMemberBinder, Object[], Object)
ExpandoBase.ToDictionary(Func<String, String>, Func<Object, Object>)
ExpandoBase.GetInnerObjectTypeInfo()
ExpandoBase.GetThisTypeInfo()
ExpandoBase.TryGetValue(String, Object)
ExpandoBase.TrySetValue(String, Object)
System.Dynamic.DynamicObject.GetMetaObject(System.Linq.Expressions.Expression)
System.Dynamic.DynamicObject.TryBinaryOperation(System.Dynamic.BinaryOperationBinder, System.Object, System.Object)
System.Dynamic.DynamicObject.TryConvert(System.Dynamic.ConvertBinder, System.Object)
System.Dynamic.DynamicObject.TryCreateInstance(System.Dynamic.CreateInstanceBinder, System.Object[], System.Object)
System.Dynamic.DynamicObject.TryDeleteIndex(System.Dynamic.DeleteIndexBinder, System.Object[])
System.Dynamic.DynamicObject.TryDeleteMember(System.Dynamic.DeleteMemberBinder)
System.Dynamic.DynamicObject.TryGetIndex(System.Dynamic.GetIndexBinder, System.Object[], System.Object)
System.Dynamic.DynamicObject.TryInvoke(System.Dynamic.InvokeBinder, System.Object[], System.Object)
System.Dynamic.DynamicObject.TrySetIndex(System.Dynamic.SetIndexBinder, System.Object[], System.Object)
System.Dynamic.DynamicObject.TryUnaryOperation(System.Dynamic.UnaryOperationBinder, System.Object)
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Kephas.Data.LLBLGen
Assembly: Kephas.Data.LLBLGen.dll
Syntax
[SupportedDataStoreKinds(new string[]{"LLBLGen"})]
public class LLBLGenDataContext : DataContextBase, ILLBLGenDataContext, IDataContext, IContext, IExpando, IDynamicMetaObjectProvider, IIndexable, ILoggable, IIdentifiable, IDisposable, IInitializable

Constructors

| Improve this Doc View Source

LLBLGenDataContext(ICompositionContext, IDataCommandProvider, IDataAccessAdapterFactory, IModelTypeResolver, IDataBehaviorProvider, IQueryFactoryProvider)

Initializes a new instance of the LLBLGenDataContext class.

Declaration
public LLBLGenDataContext(ICompositionContext compositionContext, IDataCommandProvider dataCommandProvider, IDataAccessAdapterFactory dataAccessAdapterFactory, IModelTypeResolver modelTypeResolver, IDataBehaviorProvider dataBehaviorProvider, IQueryFactoryProvider queryFactoryProvider)
Parameters
Type Name Description
ICompositionContext compositionContext

The composition context.

IDataCommandProvider dataCommandProvider

The data command provider.

IDataAccessAdapterFactory dataAccessAdapterFactory

The data access adapter factory.

IModelTypeResolver modelTypeResolver

The model type resolver.

IDataBehaviorProvider dataBehaviorProvider

The data behavior provider.

IQueryFactoryProvider queryFactoryProvider

The query factory provider.

Fields

| Improve this Doc View Source

LLBLGenDataStoreKind

The LLBLGen data store kind.

Declaration
public const string LLBLGenDataStoreKind = "LLBLGen"
Field Value
Type Description
System.String

Properties

| Improve this Doc View Source

DataAccessAdapter

Gets the data access adapter.

Declaration
public virtual DataAccessAdapterBase DataAccessAdapter { get; }
Property Value
Type Description
SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase
| Improve this Doc View Source

LocalCache

Gets the local cache where the session entities are stored.

Declaration
public IDataContextCache LocalCache { get; }
Property Value
Type Description
IDataContextCache

The local cache.

| Improve this Doc View Source

QueryFactory

Gets the meta-data for the construction of LINQ queries.

Declaration
public virtual IQueryFactory QueryFactory { get; }
Property Value
Type Description
IQueryFactory

Methods

| Improve this Doc View Source

CreateEntityEntry(Object, Nullable<ChangeState>)

Creates a new entity information.

Declaration
protected override IEntityEntry CreateEntityEntry(object entity, ChangeState? changeState = default(ChangeState? ))
Parameters
Type Name Description
System.Object entity

The entity.

System.Nullable<ChangeState> changeState

The entity's change state.

Returns
Type Description
IEntityEntry

The new entity information.

Overrides
DataContextBase.CreateEntityEntry(Object, Nullable<ChangeState>)
| Improve this Doc View Source

QueryCore<T>(IQueryOperationContext)

Gets a query over the entity type for the given query operation context, if any is provided (core implementation).

Declaration
protected override IQueryable<T> QueryCore<T>(IQueryOperationContext queryOperationContext)

    where T : class
Parameters
Type Name Description
IQueryOperationContext queryOperationContext

Context for the query.

Returns
Type Description
System.Linq.IQueryable<T>

A query over the entity type.

Type Parameters
Name Description
T

The entity type.

Overrides
DataContextBase.QueryCore<T>(IQueryOperationContext)
| Improve this Doc View Source

ResolveAttachConflict(IEntityEntry, Object, Boolean)

Resolves the attach conflict between an existing attached entity and a challenger.

Declaration
protected override IEntityEntry ResolveAttachConflict(IEntityEntry entityEntry, object entityChallenger, bool attachEntityGraph)
Parameters
Type Name Description
IEntityEntry entityEntry

The entity information.

System.Object entityChallenger

The entity challenger.

System.Boolean attachEntityGraph

true to attach the whole entity graph.

Returns
Type Description
IEntityEntry

An resolved IEntityEntry.

Overrides
DataContextBase.ResolveAttachConflict(IEntityEntry, Object, Boolean)
Remarks

By default, the entity challenger is ignored. A derived class may decide to update the existing entity with refreshed information.

Implements

ILLBLGenDataContext
IDataContext
IContext
IExpando
System.Dynamic.IDynamicMetaObjectProvider
IIndexable
ILoggable
IIdentifiable
System.IDisposable
IInitializable

Extension Methods

DynamicObjectExtensions.SetPropertyValue(Object, String, Object)
DynamicObjectExtensions.TrySetPropertyValue(Object, String, Object)
DynamicObjectExtensions.GetPropertyValue(Object, String)
DynamicObjectExtensions.TryGetPropertyValue(Object, String, out Object)
DynamicObjectExtensions.GetRuntimeTypeInfo(Object)
DynamicObjectExtensions.ToDynamic(Object)
DynamicObjectExtensions.ToExpando(Object)
BehaviorValue.ToBehaviorValue<TValue>(TValue)
CollectionExtensions.AddRange<T, TItem>(T, IEnumerable<TItem>)
LoggingExtensions.GetLogger(Object, IContext)
TypeExtensions.GetAbstractType(Object)
TypeExtensions.GetAbstractTypeInfo(Object)
ReflectionHelper.GetTypeInfo(Object)
ContextExtensions.InitialData(IContext)
ContextExtensions.WithInitialData<TContext>(TContext, IEnumerable<(Object entity, ChangeState changeState)>)
ContextExtensions.WithInitialData<TContext>(TContext, IEnumerable<Object>)
ContextExtensions.WithInitialData<TContext>(TContext, IEnumerable<IChangeStateTrackableEntityEntry>)
EntityEntryExtensions.TryGetAttachedEntityEntry(Object)
  • Improve this Doc
  • View Source
Back to top Generated by DocFX