IdeaBlade.Core Assembly > IdeaBlade.Core.Composition Namespace : CompositionContext Class |
'Declaration
Public Class CompositionContext
'Usage
Dim instance As CompositionContext
public class CompositionContext
By default the Default context is used, which means that no special type or metadata filtering is performed. DevForce also provides a Fake context which is useful during testing to provide standardized fake implementations for 1) Id generation with the FakeIdGenerator; 2) an in-memory database with the EntityServerFakeBackingStore; 3) query functionality with the EdmQueryExecutorFake; and 4) save functionality with the EdmSaveExecutorFake.
You determine the composition context in use when you construct an EntityManager by optionally passing the name of the context wanted. When using any context other than the Default and Fake contexts provided, you can implement a custom ICompositionContextResolver to register and return the CompositionContext instance wanted. If you do not implement a custom resolver your custom contexts can also be registered automatically by the BaseCompositionContextResolver. When using a custom context you can determine the types to be exported for MEF composition, and include custom metadata filtering.
System.Object
IdeaBlade.Core.Composition.CompositionContext
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2