Package de.uka.ipd.sdq.scheduler
Interface ISchedulableProcess
-
- All Superinterfaces:
de.uka.ipd.sdq.simulation.abstractsimengine.IEntity
public interface ISchedulableProcess extends de.uka.ipd.sdq.simulation.abstractsimengine.IEntityProcess that can be scheduled for execution on an active resource or can acquire and release passive resources.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidactivate()Notifies the process to resume its execution.voidaddTerminatedObserver(IActiveResource o)voidfireTerminated()StringgetId()Unique identifier of the process.intgetPriority()ISchedulableProcessgetRootProcess()Returns the root process that spawned this processes (directly or indirectly).booleanisFinished()Return whether this process is finishedvoidpassivate()Notifies the process to suspend its execution.voidremoveTerminatedObserver(IActiveResource o)voidsetPriority(int prio)voidtimeout(String timeoutFailureName)Forces a suspended process to run into a timeout failure.
-
-
-
Method Detail
-
activate
void activate()
Notifies the process to resume its execution. Is only called if the process has been passivated before.
-
passivate
void passivate()
Notifies the process to suspend its execution.
-
getId
String getId()
Unique identifier of the process.- Returns:
- A unique ID identifying this process
-
getRootProcess
ISchedulableProcess getRootProcess()
Returns the root process that spawned this processes (directly or indirectly). The root process is used to create this process' scheduling meta-data. The root process has to point to itself.- Returns:
- ISchedulableProcess which is the root process
-
isFinished
boolean isFinished()
Return whether this process is finished- Returns:
- true if the process has finished its execution
-
fireTerminated
void fireTerminated()
-
addTerminatedObserver
void addTerminatedObserver(IActiveResource o)
-
removeTerminatedObserver
void removeTerminatedObserver(IActiveResource o)
-
getPriority
int getPriority()
-
setPriority
void setPriority(int prio)
-
timeout
void timeout(String timeoutFailureName)
Forces a suspended process to run into a timeout failure. Used for passive resource timeouts- Parameters:
timeoutFailureName- the name of the triggered timeout failure
-
-