scala.actors.scheduler

class SingleThreadedScheduler

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

class SingleThreadedScheduler
extends IScheduler
This scheduler executes actor tasks on the current thread.
Author
Philipp Haller
Value Summary
protected val maxNesting : Int
The maximum number of nested tasks that are run without unwinding the call stack.
Method Summary
def execute (fun : => Unit) : Unit
Submits a closure for execution.
def execute (task : java.lang.Runnable) : Unit
Submits a Runnable for execution.
def isActive : Boolean
When the scheduler is active, it can execute tasks.
def managedBlock (blocker : ManagedBlocker) : Unit
def newActor (actor : Reactor) : Unit
Registers a newly created actor with this scheduler.
def onTerminate (actor : Reactor)(f : => Unit) : Unit
Registers a closure to be executed when the specified actor terminates.
def shutdown : Unit
Shuts down the scheduler.
def terminated (actor : Reactor) : Unit
Unregisters an actor from this scheduler, because it has terminated.
Methods inherited from IScheduler
executeFromActor, tick, onLockup, onLockup, printActorDump
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 val maxNesting : Int
The maximum number of nested tasks that are run without unwinding the call stack.

Method Details
def execute(task : java.lang.Runnable) : Unit
Submits a Runnable for execution.
Parameters
task - the task to be executed
Overrides
IScheduler.execute

def execute(fun : => Unit) : Unit
Submits a closure for execution.
Parameters
fun - the closure to be executed
Overrides
IScheduler.execute

def shutdown : Unit
Shuts down the scheduler.
Overrides
IScheduler.shutdown

def newActor(actor : Reactor) : Unit
Registers a newly created actor with this scheduler.
Parameters
a - the actor to be registered
Overrides
IScheduler.newActor

def terminated(actor : Reactor) : Unit
Unregisters an actor from this scheduler, because it has terminated.
Parameters
a - the actor to be registered
Overrides
IScheduler.terminated

def onTerminate(actor : 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
Overrides
IScheduler.onTerminate

def isActive : Boolean
When the scheduler is active, it can execute tasks.
Overrides
IScheduler.isActive

def managedBlock(blocker : ManagedBlocker) : Unit
Overrides
IScheduler.managedBlock