Interface ActorRefImpl<T>
- All Superinterfaces:
ActorRef<T>,Comparable<ActorRef<?>>,RecipientRef<T>,Serializable
Every ActorRef is also an ActorRefImpl, but these two methods shall be
completely hidden from client code. There is an implicit converter
available in the package object, enabling
ref.toImpl (or ref.toImplN
for ActorRef[Nothing]—Scala refuses to infer Nothing as a type parameter).-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.pekko.actor.typed.ActorRef
ActorRef.ActorRefOps<T>, ActorRef.ActorRefOps$Nested classes/interfaces inherited from interface org.apache.pekko.actor.typed.RecipientRef
RecipientRef.RecipientRefOps<T>, RecipientRef.RecipientRefOps$ -
Method Summary
Modifier and TypeMethodDescriptionintComparison takes path and the unique id of the actor cell into account.booleanEquals takes path and the unique id of the actor cell into account.inthashCode()booleanisLocal()narrow()Narrow the type of thisActorRef, which is always a safe operation.voidsendSystem(SystemMessage signal) toString()<U> ActorRef<U>Unsafe utility method for widening the type accepted by this ActorRef; provided to avoid having to useasInstanceOfon the full reference type, which would unfortunately also work on non-ActorRefs.Methods inherited from interface org.apache.pekko.actor.typed.ActorRef
path, tell, writeReplace
-
Method Details
-
compareTo
Comparison takes path and the unique id of the actor cell into account.- Specified by:
compareToin interfaceComparable<T>
-
equals
Equals takes path and the unique id of the actor cell into account. -
hashCode
int hashCode() -
isLocal
boolean isLocal() -
narrow
Description copied from interface:ActorRefNarrow the type of thisActorRef, which is always a safe operation. -
sendSystem
-
toString
String toString() -
unsafeUpcast
Description copied from interface:ActorRefUnsafe utility method for widening the type accepted by this ActorRef; provided to avoid having to useasInstanceOfon the full reference type, which would unfortunately also work on non-ActorRefs. Use it with caution,it may cause aClassCastExceptionwhen you send a message to the widenedActorRef[U].- Specified by:
unsafeUpcastin interfaceActorRef<T>
-