Class StageActor
Minimal actor to work with other actors and watch them in a synchronous ways.
Inherited Members
Namespace: Akka.Streams.Stage
Assembly: Akka.Streams.dll
Syntax
public sealed class StageActor
Constructors
| Edit this page View SourceStageActor(ActorMaterializer, Func<Receive, Action<(IActorRef, object)>>, Receive, string)
Declaration
public StageActor(ActorMaterializer materializer, Func<StageActorRef.Receive, Action<(IActorRef, object)>> getAsyncCallback, StageActorRef.Receive initialReceive, string name = null)
Parameters
Type | Name | Description |
---|---|---|
ActorMaterializer | materializer | |
Func<StageActorRef.Receive, Action<(IActorRef, object)>> | getAsyncCallback | |
StageActorRef.Receive | initialReceive | |
string | name |
Properties
| Edit this page View SourceRef
The IActorRef by which this StageActor can be contacted from the outside. This is a full-fledged IActorRef that supports watching and being watched as well as location transparent (remote) communication.
Declaration
public IActorRef Ref { get; }
Property Value
Type | Description |
---|---|
IActorRef |
Methods
| Edit this page View SourceBecome(Receive)
Special Become
allowing to swap the behaviour of this StageActor.
Unbecome is not available.
Declaration
public void Become(StageActorRef.Receive receive)
Parameters
Type | Name | Description |
---|---|---|
StageActorRef.Receive | receive |
Stop()
Stops current StageActor.
Declaration
public void Stop()
Unwatch(IActorRef)
Makes current StageActor stop watching previously Watch(IActorRef)ed actorRef
.
If actorRef
was not watched over, this method has no result.
Declaration
public void Unwatch(IActorRef actorRef)
Parameters
Type | Name | Description |
---|---|---|
IActorRef | actorRef |
Watch(IActorRef)
Makes current StageActor watch over given actorRef
.
It will be notified when an underlying actor is Terminated.
Declaration
public void Watch(IActorRef actorRef)
Parameters
Type | Name | Description |
---|---|---|
IActorRef | actorRef |