本文整理汇总了C#中IContext.Install方法的典型用法代码示例。如果您正苦于以下问题:C# IContext.Install方法的具体用法?C# IContext.Install怎么用?C# IContext.Install使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IContext
的用法示例。
在下文中一共展示了IContext.Install方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Start
public void Start()
{
context = new Context ();
context.Install<UnitySingleContextBundle> () // Install MVCS Framework
.Configure<HelloWorldConfig> () // Setup our hello world config
.Configure (new TransformContextView (this.transform)); // Set this transform to boot up the application when it's alive
}
示例2: Start
public void Start()
{
// A parent context, handles relationship of child / parent communication
// It becomes parent when it's child contexts boot up and find that this context's view is parent of them
parentContext = new Context ();
parentContext.Install<UnityMultiContextBundle> () // Install MVCS Framework
.Configure(new TransformContextView(transform));
}
示例3: Start
public void Start()
{
context = new Context ();
context.Install<UnityMultiContextBundle> () // Install MVCS Framework
.Configure<SendMessageConfig>() // Configure Send Message Mediation
.Configure<MessageEventReceive>() // Receives message events from the channel and passes it to it's own event dispatcher
.Configure<HelloWorldMappingConfig>() // Sets up the hello world model & mediator
.Configure<AddReceiveMessageButton>() // Adds the receive message view
.Configure<AddHelloWorldButtons>() // Adds the hello world click and display button
.Configure (new TransformContextView (this.transform)); // Set this transform to boot up the application when it's alive
}
示例4: Extend
/*============================================================================*/
/* Public Functions */
/*============================================================================*/
public void Extend(IContext context)
{
/**
* Robotlegs
*/
context.LogLevel = LogLevel.INFO;
context.Install(typeof(ConsoleLoggingExtension));
context.Install(typeof(VigilanceExtension));
context.Install(typeof(InjectableLoggerExtension));
context.Install(typeof(EventDispatcherExtension));
context.Install(typeof(ModularityExtension));
context.Install(typeof(DirectCommandMapExtension));
context.Install(typeof(EventCommandMapExtension));
context.Install(typeof(LocalEventMapExtension));
context.Install(typeof(ViewManagerExtension));
context.Install(typeof(MediatorMapExtension));
context.Install(typeof(ViewProcessorMapExtension));
context.Configure(typeof(FallbackContainerConfig));
}
示例5: Extend
/*============================================================================*/
/* Public Functions */
/*============================================================================*/
public void Extend (IContext context)
{
context.LogLevel = LogLevel.INFO;
if (Application.isEditor)
{
context.Install (typeof(UnitySingletonsExtension));
context.Install (typeof(UnityMediatorManagerExtension));
}
context.Install(typeof(DebugLoggingExtension));
context.Install(typeof(VigilanceExtension));
context.Install(typeof(InjectableLoggerExtension));
context.Install(typeof(UnityParentFinderExtension));
context.Install(typeof(ContextViewExtension));
context.Install(typeof(ContextViewTransformExtension));
context.Install(typeof(EventDispatcherExtension));
context.Install(typeof(ModularityExtension));
context.Install(typeof(DirectCommandMapExtension));
context.Install(typeof(EventCommandMapExtension));
context.Install(typeof(LocalEventMapExtension));
context.Install(typeof(ViewManagerExtension));
context.Install(typeof(MediatorMapExtension));
context.Install(typeof(ViewProcessorMapExtension));
context.Install(typeof(StageCrawlerExtension));
context.Install(typeof(StageSyncExtension));
context.Install(typeof(UnityViewStateWatcherExtension));
context.Configure(typeof(UnityStageCrawlerConfig));
context.Configure(typeof(ContextViewListenerConfig));
}