本文整理汇总了C#中ActorSystem.DI方法的典型用法代码示例。如果您正苦于以下问题:C# ActorSystem.DI方法的具体用法?C# ActorSystem.DI怎么用?C# ActorSystem.DI使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ActorSystem
的用法示例。
在下文中一共展示了ActorSystem.DI方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: RegisterActorSystem
private static void RegisterActorSystem()
{
//Warning:
//When the hosting inside of IIS the applicationpool the app lives in could be stopped and started at the whim of IIS.
//This in turn means your ActorSystem could be stopped at any given time.
//http://getakka.net/docs/deployment-scenarios/ASP%20NET
ActorSystem = ActorSystem.Create("ticketStore");
var resolver = new UnityDependencyResolver(UnityConfig.GetConfiguredContainer(), ActorSystem);
OrderProcessorActor = ActorSystem.ActorOf(ActorSystem.DI().Props<OrderProcessorActor>(), "OrderProcessor");
}
示例2: CreateActors
protected override void CreateActors(ActorSystem system)
{
SqlitePersistence.Get(system);
system.ActorOf(system.DI().Props<TellStickActor>(), "tellstick");
}
示例3: StatsActorSystemService
public StatsActorSystemService(IActorSystemFactory actorSystemFactory)
{
StatsActorSystem = actorSystemFactory.Create("StatsCoordinatorActor");
statActorRef = StatsActorSystem.ActorOf(StatsActorSystem.DI().Props<StatsCoordinatorActor>()
.WithRouter(new RoundRobinPool(2)), "StatsCoordinatorActor");
}
示例4: Init
public static void Init(IKernel kernel)
{
System = ActorSystem.Create("BotSystem");
var propsResolver = new NinjectDependencyResolver(kernel, System);
System.ActorOf(System.DI().Props<UserDispatcherActor>(), "UserDispatcher");
}