本文整理汇总了Java中akka.actor.ActorContext.actorOf方法的典型用法代码示例。如果您正苦于以下问题:Java ActorContext.actorOf方法的具体用法?Java ActorContext.actorOf怎么用?Java ActorContext.actorOf使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类akka.actor.ActorContext
的用法示例。
在下文中一共展示了ActorContext.actorOf方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: create
import akka.actor.ActorContext; //导入方法依赖的package包/类
static ShardSnapshotCohort create(final ActorContext actorContext, final MemberName memberName,
final ShardDataTree store, final Logger log, final String logId) {
final LocalHistoryIdentifier applyHistoryId = new LocalHistoryIdentifier(ClientIdentifier.create(
FrontendIdentifier.create(memberName, SNAPSHOT_APPLY), 0), 0);
final String snapshotActorName = "shard-" + memberName.getName() + ':' + "snapshot-read";
// Create a snapshot actor. This actor will act as a worker to offload snapshot serialization for all
// requests.
final ActorRef snapshotActor = actorContext.actorOf(ShardSnapshotActor.props(), snapshotActorName);
return new ShardSnapshotCohort(applyHistoryId, snapshotActor, store, log, logId);
}
示例2: actorRef
import akka.actor.ActorContext; //导入方法依赖的package包/类
public ActorRef actorRef(String actorId, ActorContext context) {
return context.actorOf(create(actorId));
}
示例3: create_generic_fsm
import akka.actor.ActorContext; //导入方法依赖的package包/类
public static ActorRef create_generic_fsm(ActorContext ctx, QueryGenericArgument request, String description) {
return ctx.actorOf(Props.create(GenericDBMSQueryingActor.class, request), description);
}