Class SequentialBatchAssembler

java.lang.Object
  extended byswarm.BaseImpl
      extended byswarm.objectbase.SwarmObjectImpl
          extended bySequentialBatchAssembler
All Implemented Interfaces:
swarm.defobj.Create, swarm.defobj.CreateS, swarm.defobj.Customize, swarm.defobj.CustomizeS, swarm.defobj.DefinedObject, swarm.defobj.DefinedObjectS, swarm.defobj.Drop, swarm.defobj.DropS, swarm.defobj.GetName, swarm.defobj.GetNameS, PTHistogramPlottable, swarm.objectbase.SwarmObject, swarm.objectbase.SwarmObjectS

public class SequentialBatchAssembler
extends swarm.objectbase.SwarmObjectImpl
implements PTHistogramPlottable

The SequentialBatchAssembler class instances are unit assembling sequential batch processes

Author:
Pietro Terna

Field Summary
 boolean compareDisregardingUnits
          in sequential batch two orders can stay in the same batch if several criteria match; one of them is that of having the same state vector, which contains the number of the units that made the various steps; if we consider more simply the state as 0 or non 0, we disregard the unit number (also the 'or', case with -1 values in not used branches, receives the same treatment)
 swarm.collections.ListImpl myUnitWaitingList
          the waiting list of myUnit
 swarm.collections.ListImpl waitingList
          the local list of the order to be assembled with a sequential batch process
 swarm.collections.ListIndex waitingListIndex_i
          its iterators
 swarm.collections.ListIndex waitingListIndex_ii
           
 
Constructor Summary
SequentialBatchAssembler(swarm.defobj.Zone aZone, boolean c)
          the constructor for SequentialBatchAssembler
 
Method Summary
 void checkingSequentialBatchAndFreeingOrders()
          verifying sequential batches and eliminating the orders from our waitingList in scheduling
 void clearToProduce()
          if the whole batch exists, we can clear it to the production
 java.lang.String getLabel()
          PTHistogramPlottable interface method: getLabel()
 double getValueToPlot()
          PTHistogramPlottable interface method: getValueToPlot()
 int getWaitingListLength()
          return the waiting list length
 void removeThisOrderFromTheWaitingList(Order o)
          removing the order from the waitingList
 boolean sameOrderInSequentialBatch(Order o1, Order o2)
          checking if two orders are in the same batch
 boolean setSequentialBatchWaitingList(Order anOrder)
          adding an order to the waitingList
 void setUnit(Unit u)
          setting the unit we are assembling for and its waitingList
 boolean thisOrderIsInTheWaitingList(Order o)
          checking if an order is in the waitingList
 
Methods inherited from class swarm.objectbase.SwarmObjectImpl
compare, describe, describeID, drop, getCompleteProbeMap, getDisplayName, getName, getProbeForMessage, getProbeForVariable, getProbeMap, getTypeName, getZone, perform, perform$with, perform$with$with, perform$with$with$with, respondsTo, setDisplayName, xfprint, xfprintid, xprint, xprintid
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

myUnitWaitingList

public swarm.collections.ListImpl myUnitWaitingList
the waiting list of myUnit


waitingList

public swarm.collections.ListImpl waitingList
the local list of the order to be assembled with a sequential batch process


waitingListIndex_i

public swarm.collections.ListIndex waitingListIndex_i
its iterators


waitingListIndex_ii

public swarm.collections.ListIndex waitingListIndex_ii

compareDisregardingUnits

public boolean compareDisregardingUnits
in sequential batch two orders can stay in the same batch if several criteria match; one of them is that of having the same state vector, which contains the number of the units that made the various steps; if we consider more simply the state as 0 or non 0, we disregard the unit number (also the 'or', case with -1 values in not used branches, receives the same treatment)

Constructor Detail

SequentialBatchAssembler

public SequentialBatchAssembler(swarm.defobj.Zone aZone,
                                boolean c)
the constructor for SequentialBatchAssembler

Method Detail

setUnit

public void setUnit(Unit u)
setting the unit we are assembling for and its waitingList


setSequentialBatchWaitingList

public boolean setSequentialBatchWaitingList(Order anOrder)
adding an order to the waitingList


checkingSequentialBatchAndFreeingOrders

public void checkingSequentialBatchAndFreeingOrders()
verifying sequential batches and eliminating the orders from our waitingList in scheduling


getWaitingListLength

public int getWaitingListLength()
return the waiting list length


thisOrderIsInTheWaitingList

public boolean thisOrderIsInTheWaitingList(Order o)
checking if an order is in the waitingList


removeThisOrderFromTheWaitingList

public void removeThisOrderFromTheWaitingList(Order o)
removing the order from the waitingList


clearToProduce

public void clearToProduce()
if the whole batch exists, we can clear it to the production


sameOrderInSequentialBatch

public boolean sameOrderInSequentialBatch(Order o1,
                                          Order o2)
checking if two orders are in the same batch


getLabel

public java.lang.String getLabel()
PTHistogramPlottable interface method: getLabel()

Specified by:
getLabel in interface PTHistogramPlottable

getValueToPlot

public double getValueToPlot()
PTHistogramPlottable interface method: getValueToPlot()

Specified by:
getValueToPlot in interface PTHistogramPlottable