Logo Search packages:      
Sourcecode: scala version File versions  Download package

final void scala::actors::FJTaskRunner::taskYield (  )  [inline, protected]

Execute a task in this thread. Generally called when current task cannot otherwise continue.

Definition at line 843 of file FJTaskRunner.java.

References COLLECT_STATS, scala::actors::FJTask::isDone(), pop(), runs, scan(), and scala::actors::FJTask::setDone().

Referenced by scala::actors::FJTask::yield().

                                   {
    FJTask task = pop();
    if (task != null) {
      if (!task.isDone()) {
        if (COLLECT_STATS) ++runs;
        task.run(); 
        task.setDone(); 
      }
    }
    else
      scan(null);
  }


Generated by  Doxygen 1.6.0   Back to index