Receive

org.apache.pekko.actor.AbstractActor.Receive
final class Receive(val onMessage: PartialFunction[Any, BoxedUnit])

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.

Attributes

Source
AbstractActor.scala
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def orElse(other: Receive): Receive

Composes this Receive with a fallback which gets applied where this partial function is not defined.

Composes this Receive with a fallback which gets applied where this partial function is not defined.

Attributes

Source
AbstractActor.scala

Concrete fields