#include <SAtomarJob.h>
Inherits SShopJob, and SParallelJob.
Inheritance diagram for SAtomarJob:
Public Types | |
enum | State { HIDDEN, RELEASED, RUNNING, FINISHED, REJECTED } |
Public Methods | |
SAtomarJob (SProbabilityDist *dist) | |
SAtomarJob (double proctime) | |
virtual | ~SAtomarJob () |
virtual void | process (SMachines &machines, double duration) |
virtual SJobMod & | getModifier () |
virtual void | reset () |
bool | isOpFinished (int op) const |
int | getFinishedOper () const |
int | getCurrOper () const |
void | setCurrOper (int newOp, const SMachines &mach) |
double | getRemOpProcTime () const |
int | getIndex () const |
virtual double | getProcTime () |
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 | SAtomarJobMod |
|
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) |
|
Constructor. |
|
Constructor |
|
Destructor. |
|
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 the operation, which is currently processed if job is running, or get the operation, which will be processed next if job is not running
|
|
Get time when the execution of the job must be finished (= due date). |
|
|
|
Get the number of operations which have already been executed.
|
|
Get the index of the job. |
|
Get access to the modifier. 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 in SMalleableJob. |
|
No descriptions |
|
Get time when the job becomes released. |
|
Get the time remaining in this operation |
|
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
|
|
Returns, if the specified operation of job is finished. Note: If you call this method when simulation is not running, you will always get false.
|
|
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 simulateUntil(). See SJob::process() for more details.
Reimplemented from SParallelJob. |
|
Reset shop job and call SJob::reset() Reimplemented from SJob. |
|
Prepares the job for the execution of the next operation. Attention: The settings must correspond to the type of the environment (this is checked by process() ) |
|
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 |