Attempts to locate the entity in the session-level cache.
Namespace: NHibernate.Event.DefaultAssembly: NHibernate (in NHibernate.dll) Version: 3.2.0.4000 (3.2.0.4000)
Syntax
C# |
---|
protected virtual Object LoadFromSessionCache( LoadEvent event, EntityKey keyToLoad, LoadType options ) |
Visual Basic |
---|
Protected Overridable Function LoadFromSessionCache ( _ event As LoadEvent, _ keyToLoad As EntityKey, _ options As LoadType _ ) As Object |
Visual C++ |
---|
protected: virtual Object^ LoadFromSessionCache( LoadEvent^ event, EntityKey^ keyToLoad, LoadType^ options ) |
Parameters
- event
- Type: NHibernate.Event..::..LoadEvent
The load event
- keyToLoad
- Type: NHibernate.Engine..::..EntityKey
The EntityKey representing the entity to be loaded.
- options
- Type: NHibernate.Event..::..LoadType
The load options.
Return Value
The entity from the session-level cache, or null.
Remarks
If allowed to return nulls, then if the entity happens to be found in
the session cache, we check the entity type for proper handling
of entity hierarchies.
If checkDeleted was set to true, then if the entity is found in the
session-level cache, it's current status within the session cache
is checked to see if it has previously been scheduled for deletion.