Package org.apache.pekko.actor
Class AbstractActor.Receive
java.lang.Object
org.apache.pekko.actor.AbstractActor.Receive
- Enclosing class:
- AbstractActor
Defines which messages the Actor can handle, along with the implementation of
how the messages should be processed. You can build such behavior with the
pekko.japi.pf.ReceiveBuilder
but it can be implemented in other ways than
using the ReceiveBuilder
since it in the end is just a wrapper around a
Scala PartialFunction
. In Java, you can implement PartialFunction
by
extending AbstractPartialFunction
.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionscala.PartialFunction<Object,
scala.runtime.BoxedUnit> orElse
(AbstractActor.Receive other) Composes thisReceive
with a fallback which gets applied where this partial function is not defined.
-
Constructor Details
-
Receive
-
-
Method Details
-
onMessage
-
orElse
Composes thisReceive
with a fallback which gets applied where this partial function is not defined.
-