Class EntityRef<M>
- java.lang.Object
-
- akka.cluster.sharding.typed.javadsl.EntityRef<M>
-
- All Implemented Interfaces:
RecipientRef<M>
- Direct Known Subclasses:
EntityRefImpl
public abstract class EntityRef<M> extends java.lang.Object implements RecipientRef<M>
Send a message to the entity referenced by this EntityRef using *at-most-once* messaging semantics.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface akka.actor.typed.RecipientRef
RecipientRef.RecipientRefOps<T>, RecipientRef.RecipientRefOps$
-
-
Constructor Summary
Constructors Constructor Description EntityRef()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract <U> java.util.concurrent.CompletionStage<U>ask(Function<ActorRef<U>,M> message, Timeout timeout)Allows to "ask" theEntityReffor a reply.EntityRef<M>asScala()INTERNAL APIabstract voidtell(M msg)Send a message to the destination referenced by thisRecipientRefusing *at-most-once* messaging semantics.
-
-
-
Method Detail
-
ask
public abstract <U> java.util.concurrent.CompletionStage<U> ask(Function<ActorRef<U>,M> message, Timeout timeout)
Allows to "ask" theEntityReffor a reply. SeeAskPatternfor a complete write-up of this patternNote that if you are inside of an actor you should prefer
akka.actor.typed.javadsl.ActorContext.askas that provides better safety.- Parameters:
message- (undocumented)timeout- (undocumented)- Returns:
- (undocumented)
-
tell
public abstract void tell(M msg)
Description copied from interface:RecipientRefSend a message to the destination referenced by thisRecipientRefusing *at-most-once* messaging semantics.- Specified by:
tellin interfaceRecipientRef<M>- Parameters:
msg- (undocumented)
-
-