Package jasima.shopSim.core
Class JobSource
- java.lang.Object
-
- jasima.core.simulation.SimComponentBase
-
- jasima.shopSim.core.JobSource
-
- All Implemented Interfaces:
SimComponent,SimLifecycleListener,SimOperations,Notifier<SimComponent,SimComponent.SimComponentEvent>,NotifierListener<Simulation,Simulation.SimLifecycleEvent>,ValueStore,Cloneable
- Direct Known Subclasses:
DynamicJobSource,StaticJobSource
public abstract class JobSource extends SimComponentBase
A job source is an abstract base class for classes producingJobs.- Author:
- Torsten Hildebrandt
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface jasima.core.simulation.SimComponent
SimComponent.ProduceResultsEvent, SimComponent.SimComponentEvent, SimComponent.SimComponentLifeCycleMessage
-
Nested classes/interfaces inherited from interface jasima.core.simulation.SimLifecycleListener
SimLifecycleListener.DoneListener, SimLifecycleListener.OtherListener, SimLifecycleListener.ResetStatsListener, SimLifecycleListener.ResultsListener, SimLifecycleListener.SimEndListener, SimLifecycleListener.SimInitialized, SimLifecycleListener.SimStartListener
-
Nested classes/interfaces inherited from interface jasima.core.simulation.util.SimOperations
SimOperations.SimEventType
-
-
Field Summary
Fields Modifier and Type Field Description static intARRIVE_PRIOintindexintjobsStartedbooleanstopArrivals-
Fields inherited from class jasima.core.simulation.SimComponentBase
sim
-
Fields inherited from interface jasima.core.simulation.SimComponent
NAME_SEPARATOR
-
-
Constructor Summary
Constructors Constructor Description JobSource()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description JobSourceclone()Public clone method.abstract JobcreateNextJob()ShopgetShop()voidinit()protected JobnewJobInstance()Factory method used increateNextJob()to create a new job instance.voidsetShop(Shop shop)-
Methods inherited from class jasima.core.simulation.SimComponentBase
getHierarchicalName, getName, getParent, getSim, isInitialized, notifierImpl, setInitialized, setName, setNameInternal, setParent, setSim, toString, valueStoreImpl
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface jasima.core.util.observer.Notifier
addListener, addListener, addListener, fire, fire, getListener, numListener, removeCurrentListener, removeListener
-
Methods inherited from interface jasima.core.simulation.SimComponent
addChild, addComponent, addResult, containsChild, done, getByHierarchicalName, getChild, getChildByName, getChildren, handleOther, inform, isValidName, numChildren, produceResults, removeChild, removeChildren, resetStats, simEnd, simStart
-
Methods inherited from interface jasima.core.simulation.util.SimOperations
activateEntity, currentPrio, end, getRootComponent, initRndGen, initRndGen, isEndRequested, isTraceEnabled, schedule, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleAt, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, scheduleIn, schedulePeriodically, schedulePeriodically, scheduleProcess, scheduleProcess, simTime, simTimeAbs, simTimeToInstant, toSimTime, toSimTime, toSimTime, trace
-
Methods inherited from interface jasima.core.util.ValueStore
valueStoreContains, valueStoreGet, valueStoreGet, valueStoreGetAllKeys, valueStoreGetNumKeys, valueStorePut, valueStoreRemove, valueStoreUpdate
-
-
-
-
Field Detail
-
ARRIVE_PRIO
public static final int ARRIVE_PRIO
- See Also:
- Constant Field Values
-
stopArrivals
public boolean stopArrivals
-
jobsStarted
public int jobsStarted
-
index
public int index
-
-
Method Detail
-
init
public void init()
-
createNextJob
public abstract Job createNextJob()
-
newJobInstance
protected Job newJobInstance()
Factory method used increateNextJob()to create a new job instance.- Returns:
- The new
Jobinstance.
-
getShop
public Shop getShop()
-
setShop
public void setShop(Shop shop)
-
clone
public JobSource clone()
Description copied from interface:SimComponentPublic clone method. Implementing classes should implement a suitable functionality or throw aCloneNotSupportedExceptionwrapped in aRuntimeException.- Specified by:
clonein interfaceSimComponent- Overrides:
clonein classSimComponentBase
-
-