org.objectweb.dream.control.activity.scheduler
Class MultiThreadForwarderSchedulerImpl
java.lang.Object
org.objectweb.dream.control.activity.scheduler.MultiThreadForwarderSchedulerImpl
- All Implemented Interfaces:
- InterruptTask, Scheduler, BindingController
public class MultiThreadForwarderSchedulerImpl
- extends Object
- implements Scheduler, InterruptTask, BindingController
This scheduler is only bound to one upper-level that it executes. The
schedule
method only executes the upper-level task to which
this scheduler is bound. This scheduler can be multi threaded.
Fields inherited from interface org.objectweb.dream.control.activity.scheduler.Scheduler |
ITF_NAME |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
executingThreads
protected Set<Thread> executingThreads
interrupted
protected boolean interrupted
taskItf
protected Task taskItf
endOfTaskItf
protected EndOfTask endOfTaskItf
logger
protected Logger logger
MultiThreadForwarderSchedulerImpl
public MultiThreadForwarderSchedulerImpl()
schedule
public Object schedule(int executionQuanta,
Object hints)
throws InterruptedException
- Description copied from interface:
Scheduler
- Scheduling method.
- Specified by:
schedule
in interface Scheduler
- Parameters:
executionQuanta
- the amount of execution time the scheduler can use.
if negative, the scheduler can loop until until it has no task to
execute.hints
- scheduling parameters.
- Returns:
- An object that represents the scheduling result.
- Throws:
InterruptedException
- if the scheduller was interrupted.- See Also:
Scheduler.schedule(int, Object)
interruptTask
public void interruptTask(Task task)
throws IllegalTaskException
- Description copied from interface:
InterruptTask
- Interrupts the given task. When the task ends its execution the activity
manager will be notified using the
EndOfTask
interface.
- Specified by:
interruptTask
in interface InterruptTask
- Parameters:
task
- the task to interrupt.
- Throws:
IllegalTaskException
- if the given task is unknown.- See Also:
InterruptTask.interruptTask(Task)
bindFc
public void bindFc(String clientItfName,
Object serverItf)
throws NoSuchInterfaceException,
IllegalBindingException,
IllegalLifeCycleException
- Specified by:
bindFc
in interface BindingController
- Throws:
NoSuchInterfaceException
IllegalBindingException
IllegalLifeCycleException
- See Also:
BindingController.bindFc(String, Object)
lookupFc
public Object lookupFc(String clientItfName)
throws NoSuchInterfaceException
- Specified by:
lookupFc
in interface BindingController
- Throws:
NoSuchInterfaceException
- See Also:
BindingController.lookupFc(String)
unbindFc
public void unbindFc(String clientItfName)
throws NoSuchInterfaceException,
IllegalBindingException,
IllegalLifeCycleException
- Specified by:
unbindFc
in interface BindingController
- Throws:
NoSuchInterfaceException
IllegalBindingException
IllegalLifeCycleException
- See Also:
BindingController.unbindFc(String)
listFc
public String[] listFc()
- Specified by:
listFc
in interface BindingController
- See Also:
BindingController.listFc()
Copyright © 2003, 2005 - INRIA Rhone-Alpes - All Rights Reserved.