Looking up actors
As shown, you look up actors with the
actorSelection
method, and can specify a full path to the actor in the manner shown. The actorSelection
method is available on anActorSystem
instance and on the context
object in an Actor
instance.
You can also look up actors using a relative path. If
kenny
had a sibling actor, it could have looked up kenny
using its own context
, like this:
No comments:
Post a Comment