Akka.Actor.ActorCell.WatchedActorTerminated C# (CSharp) Method

WatchedActorTerminated() protected method

When this actor is watching the subject of Terminated message it will be propagated to user's receive.
protected WatchedActorTerminated ( IActorRef actor, bool existenceConfirmed, bool addressTerminated ) : void
actor IActorRef
existenceConfirmed bool
addressTerminated bool
return void
        protected void WatchedActorTerminated(IActorRef actor, bool existenceConfirmed, bool addressTerminated)
        {
            if (WatchingContains(actor))
            {
                MaintainAddressTerminatedSubscription(() =>
                {
                    _state = _state.RemoveWatching(actor);
                }, actor);
                if (!IsTerminating)
                {
                    Self.Tell(new Terminated(actor, existenceConfirmed, addressTerminated), actor);
                    TerminatedQueuedFor(actor);
                }
            }
            if (ChildrenContainer.Contains(actor))
            {
                HandleChildTerminated(actor);
            }
        }