haifa.shopsim
Class MachineFinishedEvent

java.lang.Object
  |
  +--java.util.EventObject
        |
        +--haifa.shopsim.ShopChangeEvent
              |
              +--haifa.shopsim.MachineFinishedEvent
All Implemented Interfaces:
java.io.Serializable

public class MachineFinishedEvent
extends ShopChangeEvent

Signifies that a machine finished processing a job. Also hold information regarding the next action to be performed.

Version:
1.1
See Also:
Serialized Form

Field Summary
private  Operation finishedOperation
          The operation that was just finished.
private  int machineNumber
          The machine that finished the processing.
private  int nextMachineNumber
          Has value of -1 if the next machine is a RouteEnd.
private  Operation nextOperation
          Has null value if the next operation is a route end.
 
Fields inherited from class haifa.shopsim.ShopChangeEvent
time
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
MachineFinishedEvent(java.lang.Object source, double time, int machineNumber_)
          Smaller Constructor, leaves some values as null or 0.
MachineFinishedEvent(java.lang.Object source, double time, int machineNumber_, int nextMachineNumber_, Operation finishedOperation_, Operation nextOperation_)
          Constructor.
 
Method Summary
 Operation getFinishedOperation()
           
 int getMachineNumber()
           
 int getNextMachineNumber()
           
 Operation getNextOperation()
           
 java.lang.String toString()
          Returns time.
 
Methods inherited from class haifa.shopsim.ShopChangeEvent
getTime
 
Methods inherited from class java.util.EventObject
getSource
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait
 

Field Detail

machineNumber

private int machineNumber
The machine that finished the processing.

nextMachineNumber

private int nextMachineNumber
Has value of -1 if the next machine is a RouteEnd.

finishedOperation

private Operation finishedOperation
The operation that was just finished.

nextOperation

private Operation nextOperation
Has null value if the next operation is a route end.
Constructor Detail

MachineFinishedEvent

public MachineFinishedEvent(java.lang.Object source,
                            double time,
                            int machineNumber_,
                            int nextMachineNumber_,
                            Operation finishedOperation_,
                            Operation nextOperation_)
Constructor.

MachineFinishedEvent

public MachineFinishedEvent(java.lang.Object source,
                            double time,
                            int machineNumber_)
Smaller Constructor, leaves some values as null or 0.
Method Detail

toString

public java.lang.String toString()
Description copied from class: ShopChangeEvent
Returns time.
Overrides:
toString in class ShopChangeEvent

getMachineNumber

public int getMachineNumber()

getNextMachineNumber

public int getNextMachineNumber()

getFinishedOperation

public Operation getFinishedOperation()

getNextOperation

public Operation getNextOperation()