abstract class ActorHandler[Envelope, T] extends Handler[Envelope] with ActorHandlerInit[T]
This Handler gives support for spawning an actor of a given Behavior to delegate
processing of the envelopes to the actor.
The lifecycle of the actor is managed by the Projection. The behavior is spawned when the
Projection is started and the ActorRef is passed in as a parameter to the process method.
The Actor is stopped when the Projection is stopped.
- Source
 - ActorHandler.scala
 
- Alphabetic
 - By Inheritance
 
- ActorHandler
 - ActorHandlerInit
 - Handler
 - HandlerLifecycle
 - AnyRef
 - Any
 
- Hide All
 - Show All
 
- Public
 - Protected
 
Abstract Value Members
-   abstract  def process(actor: ActorRef[T], envelope: Envelope): Future[Done]
The
processmethod is invoked for eachEnvelope.The
processmethod is invoked for eachEnvelope. One envelope is processed at a time. The returnedFutureis to be completed when the processing of theenvelopehas finished. It will not be invoked with the next envelope until after the returnedFuturehas been completed.The
behavioris spawned when theProjectionis started and theActorRefis passed in as a parameter here.You will typically use the
AskPattern.askto delegate the processing of theenvelopeto the actor and the returnedFuturecorresponds to the reply of theask. 
Concrete Value Members
-   final  def !=(arg0: Any): Boolean
- Definition Classes
 - AnyRef → Any
 
 -   final  def ##: Int
- Definition Classes
 - AnyRef → Any
 
 -   final  def ==(arg0: Any): Boolean
- Definition Classes
 - AnyRef → Any
 
 -   final  def asInstanceOf[T0]: T0
- Definition Classes
 - Any
 
 -    val behavior: Behavior[T]
INTERNAL API
INTERNAL API
- Definition Classes
 - ActorHandler → ActorHandlerInit
 
 -    def clone(): AnyRef
- Attributes
 - protected[lang]
 - Definition Classes
 - AnyRef
 - Annotations
 - @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
 
 -   final  def eq(arg0: AnyRef): Boolean
- Definition Classes
 - AnyRef
 
 -    def equals(arg0: AnyRef): Boolean
- Definition Classes
 - AnyRef → Any
 
 -   final  def getClass(): Class[_ <: AnyRef]
- Definition Classes
 - AnyRef → Any
 - Annotations
 - @IntrinsicCandidate() @native()
 
 -    def hashCode(): Int
- Definition Classes
 - AnyRef → Any
 - Annotations
 - @IntrinsicCandidate() @native()
 
 -   final  def isInstanceOf[T0]: Boolean
- Definition Classes
 - Any
 
 -   final  def ne(arg0: AnyRef): Boolean
- Definition Classes
 - AnyRef
 
 -   final  def notify(): Unit
- Definition Classes
 - AnyRef
 - Annotations
 - @IntrinsicCandidate() @native()
 
 -   final  def notifyAll(): Unit
- Definition Classes
 - AnyRef
 - Annotations
 - @IntrinsicCandidate() @native()
 
 -   final  def process(envelope: Envelope): Future[Done]
The
processmethod is invoked for eachEnvelope.The
processmethod is invoked for eachEnvelope. One envelope is processed at a time. The returnedFutureis to be completed when the processing of theenvelopehas finished. It will not be invoked with the next envelope until after the returnedFuturehas been completed.- Definition Classes
 - ActorHandler → Handler
 
 -    def start(): Future[Done]
Invoked when the projection is starting, before first envelope is processed.
Invoked when the projection is starting, before first envelope is processed. Can be overridden to implement initialization. It is also called when the
Projectionis restarted after a failure.- Definition Classes
 - HandlerLifecycle
 
 -    def stop(): Future[Done]
Invoked when the projection has been stopped.
Invoked when the projection has been stopped. Can be overridden to implement resource cleanup. It is also called when the
Projectionis restarted after a failure.- Definition Classes
 - HandlerLifecycle
 
 -   final  def synchronized[T0](arg0: => T0): T0
- Definition Classes
 - AnyRef
 
 -    def toString(): String
- Definition Classes
 - AnyRef → Any
 
 -   final  def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
 - AnyRef
 - Annotations
 - @throws(classOf[java.lang.InterruptedException])
 
 -   final  def wait(arg0: Long): Unit
- Definition Classes
 - AnyRef
 - Annotations
 - @throws(classOf[java.lang.InterruptedException]) @native()
 
 -   final  def wait(): Unit
- Definition Classes
 - AnyRef
 - Annotations
 - @throws(classOf[java.lang.InterruptedException])