scala.actors.scheduler

trait TerminationMonitor

[source: scala/actors/scheduler/TerminationMonitor.scala]

trait TerminationMonitor
extends AnyRef
Direct Known Subclasses:
ActorGC, ForkJoinScheduler, ResizableThreadPoolScheduler, TerminationService, ThreadPoolScheduler

Value Summary
protected var activeActors : Int
protected val terminationHandlers : HashMap[Reactor, () => Unit]
Method Summary
def allTerminated : Boolean
Checks whether all actors have terminated.
protected def gc : Unit
Checks for actors that have become garbage.
def newActor (a : Reactor) : Unit
newActor is invoked whenever a new actor is started.
def onTerminate (a : Reactor)(f : => Unit) : Unit
Registers a closure to be executed when the specified actor terminates.
def terminated (a : Reactor) : Unit
Registers that the specified actor has terminated.
Methods inherited from AnyRef
getClass, hashCode, equals, clone, toString, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized
Methods inherited from Any
==, !=, isInstanceOf, asInstanceOf
Value Details
protected var activeActors : Int

protected val terminationHandlers : HashMap[Reactor, () => Unit]

Method Details
def newActor(a : Reactor) : Unit
newActor is invoked whenever a new actor is started.

def onTerminate(a : Reactor)(f : => Unit) : Unit
Registers a closure to be executed when the specified actor terminates.
Parameters
a - the actor
f - the closure to be registered

def terminated(a : Reactor) : Unit
Registers that the specified actor has terminated.
Parameters
a - the actor that has terminated

@deprecated("this method is going to be removed in a future release")

def allTerminated : Boolean
Checks whether all actors have terminated.

protected def gc : Unit
Checks for actors that have become garbage.