public class Gates extends ModelComponent
Truck
s
enter and leave the terminal. It has a ceratin number of the entrance and
exit lanes. Both must be not negative. The lanes are implemented as
Res
with FIFO-strategy and unlimited capacity. The Gates is
derived from ModelComponent.ModelComponent
Constructor and Description |
---|
Gates(Model owner,
java.lang.String name,
int nEntLanes,
int nExitLanes,
boolean showInTrace)
Constructor for a Gates of a container terminal where the trucks enter
and leave the terminal.
|
Modifier and Type | Method and Description |
---|---|
void |
enterEntrance()
A process is using this method to enter the entrance of the Gates and get
one of free lanes of this Gates.
|
void |
enterExit()
A process is using this method to enter the exit of the Gates and get one
of free exit lanes of this Gates.
|
double |
getTurnAroundTime()
Returns the turn around time of users (trucks) of this Gates.
|
long |
getUsers()
Returns the number of users (trucks) of this Gates.
|
void |
leaveEntrance()
A process is using this method to leave the enter of the Gates and put
used entrance lane back.
|
void |
leaveExit()
A process is using this method to leave the exit of the Gates and put a
used exit lane back.
|
current, currentEntity, currentEntityAll, currentEvent, currentModel, currentSimProcess, debugIsOn, debugOff, debugOn, getModel, isExperimentCompatible, isModelCompatible, presentTime, sendDebugNote, sendMessage, sendTraceNote, sendWarning, skipTraceNote, skipTraceNote, traceIsOn, traceOff, traceOn
getName, getQuotedName, toString
public Gates(Model owner, java.lang.String name, int nEntLanes, int nExitLanes, boolean showInTrace)
owner
- desmoj.Model : The model this Gates is associated to.name
- java.lang.String : The name of this Gates.int
- nEntLanes: the number of the entrance lanes of this Gates.int
- nExitLanes: the number of the exit lanes of this Gates.showInTrace
- boolean : Flag, if trace messages of this Gates should be
displayed in the trace file.public void enterEntrance() throws SuspendExecution
SuspendExecution
public void leaveEntrance()
public void enterExit() throws SuspendExecution
SuspendExecution
public void leaveExit()
public long getUsers()
public double getTurnAroundTime()