#include <SMalleableJob.h>
Inherits SParallelJob.
Inheritance diagram for SMalleableJob:
Public Types | |
enum | State { HIDDEN, RELEASED, RUNNING, FINISHED, REJECTED } |
Public Methods | |
SMalleableJob (SProbabilityDist *dist) | |
SMalleableJob (double proctime) | |
virtual | ~SMalleableJob () |
virtual const STopology * | getMaxTop () const |
virtual const STopology * | getMinTop () const |
virtual void | process (SMachines &machines, double duration) |
SJobMod & | getModifier () |
void | setCurrentTopology (STopology *top) |
virtual double | getProcTime () |
virtual double | getProcTimeOnTopology (const STopology &rTopo) |
virtual void | reset () |
int | getIndex () const |
virtual double | getRemProcTime () const |
bool | isFinished () const |
double | getReleaseTime () const |
double | getDueTime () const |
double | getStartTime (int operation=0) const |
const leda_array< double > & | getStartTimes () const |
const STopology & | getTopology () const |
const double | getWeight () const |
State | getState () const |
virtual void | setState (State s) |
bool | getOverDue () const |
virtual void | setOverDue () |
virtual double | getNextEventTime (double currTime) const |
void | simulate (double oldTime, double newTime) |
double | getExpProcTime () |
SProbabilityDist * | getProcTimeDist () |
bool | hasRandProcTime () |
virtual leda_string | getClassifier () const=0 |
virtual bool | isInstanceOf (const leda_string &classifier) const=0 |
virtual void | assureInstanceOf (const leda_string &classifier) const=0 |
void | addObserver (SObserver &obs) |
void | deleteObserver (SObserver &obs) |
void | notifyObservers (const SEvent &event) |
Public Attributes | |
SPref & | _pref |
Protected Methods | |
void | advanceProcTime (double by) |
const SPref & | getPref () const |
Friends | |
class | SMalleableJobMod |
|
Defined states of a job: HIDDEN (not yet released and so cannot be scheduled), RELEASED (can be scheduled, but is not running at the moment), RUNNING, FINISHED (job is completely finished i.e. for shop jobs all operations are finished) |
|
|
|
|
|
|
|
Here another component can register himself as observer of this component
|
|
Record the amount of time for which the job has already been processed. The job is finished if the total processing time is reached. Called by process() |
|
The same as isInstanceOf(), only that the program is stopped with an error in case of failure
|
|
Here another component can delete himself from the list of observers of this component
|
|
Get the classifier of the object, using the classification scheme. E.g. "P" for Identical Processors
|
|
Get time when the execution of the job must be finished (= due date). |
|
|
|
Get the index of the job. |
|
|
|
|
|
Get access to the modifier. Here you can change properties of the job.
Reimplemented from SParallelJob. |
|
Return the next time an event will happen after the current time
|
|
Return if job has passed its due date |
|
get read-only access to the preferences instance |
|
Get total relative processing time of the job. Interpreted according to the job model: it is assumed that the whole job is executed with normalized speed Reimplemented from SJob. |
|
No descriptions |
|
|
|
Get time when the job becomes released. |
|
Get remaining relative processing time of the job. I Interpreted according to the job model. |
|
Get time when the job gets running. |
|
Get all start times. |
|
Get the state of the job |
|
Get topology of job |
|
|
|
No descriptions |
|
Return if job is finished. A job is finished if its remaining relative processing time is zero. |
|
Checks whether the object is an instance of the specified or a specialized class
|
|
Inform all observers of this component about an event. The Observers will receive this event by their SObserver::update()-method.
|
|
This method is called by SMachines during simulatedUntil(). It records which part of the job has already been processed and changes the state of the job if appropriate.
Reimplemented from SParallelJob. |
|
Reset job. Set remaining processing time to the processing time of the job, set state to HIDDEN, set it to be "in due time" and notify observers of JOBRESET Reimplemented in SShopJob. |
|
checks whether top fits in _pMaxTop, explodes if top is too big! |
|
Do not call this from the outside. Should only be called by simulate() |
|
Do not call this from the outside. Set the new state and generate JOBSTATECHANGED, only used by SMachines!! |
|
Advance the simulation time until the next time step. CAUTION: This method does not simulate the processing of the job on a machine. This is done by process() which is called by SMachines::simulate(). simulate() only handles events which concern the job itself (not the pair job/machine), e.g. release time and due date
|
|
|
|
reference to preference instance |