public class ConveyorSimpleStation<T extends Agent> extends ConveyorStation<T> implements com.anylogic.engine.markup.material_handling.IConveyorSimpleStationDescriptor<T>
The station can process more than 1 material item at a time. The number of items to process is defined in the Capacity parameter. If two or more material items must be processed simultaneously, the station will wait until the required number of agents arrives.
The time required to process the specified number of material items is defined by the Delay parameter.
Constructor and Description |
---|
ConveyorSimpleStation(ConveyorPath<? extends T> conveyor,
ShapeDrawMode drawMode,
boolean isPublic,
double offset,
double lengthInMeters)
Deprecated.
|
ConveyorSimpleStation(ConveyorPath<? extends T> conveyor,
ShapeDrawMode drawMode,
boolean isPublic,
double offsetInPixels,
double lengthInMeters,
java.awt.Paint fillColor,
java.awt.Paint lineColor,
com.anylogic.engine.markup.material_handling.IConveyorSimpleStationDescriptor<T> descriptor)
Constructor
|
Modifier and Type | Method and Description |
---|---|
boolean |
contains(Agent agent)
Returns true if the given agent (material item) is inside the station, returns false otherwise.
|
double |
delay(T agent,
java.util.List<T> allAgents,
TimeUnits units)
This method is internal and shouldn't be called by user.
|
void |
fail()
Initiates station failure.
|
T |
getAgent(int index)
Returns the agent (material item) that is currently located in the station
|
java.util.List<T> |
getAgents()
Returns the list of agents (material items) that are currently located in the station, returns null if none.
|
ConveyorSimpleStationDelayType |
getDelayType() |
java.awt.Color |
getFillColor() |
Texture |
getFillTexture() |
com.anylogic.engine.markup.material_handling.IConveyorSimpleStationDescriptor<T> |
getLibraryDescriptor() |
java.awt.Color |
getLineColor() |
Texture |
getLineTexture() |
ConveyorSimpleStationLoadingMode |
getLoadingMode() |
int |
getQuantity()
Returns the number of agents (material items) required to start the processing.
|
java.lang.Object |
getResourceDestinationType()
Returns the type of destination the resources are sent to.
|
boolean |
isFailed()
Returns true if the station failed (broke down) and is not operating, returns false otherwise.
|
boolean |
isProcessing()
Returns true if the station is processing agents (material items), returns false otherwise.
|
boolean |
isSeizeFromOnePool()
Returns true if the station will be using resource units of the same pool, returns false otherwise.
|
boolean |
isUseResources()
Returns true if the station is using resource units, returns false otherwise.
|
boolean |
movingGoHome(T agent,
java.util.List<T> allAgents,
Agent unit) |
void |
onFailed() |
void |
onLeadingEdgeEnter(T agent)
This method is internal and shouldn't be called by user.
|
void |
onLeadingEdgeExit(T agent)
This method is internal and shouldn't be called by user.
|
void |
onProcessFinished(T agent,
java.util.List<T> allAgents)
This method is internal and shouldn't be called by user.
|
void |
onProcessStarted(T agent,
java.util.List<T> allAgents)
This method is internal and shouldn't be called by user.
|
void |
onRepaired() |
void |
onTrailingEdgeEnter(T agent)
This method is internal and shouldn't be called by user.
|
void |
onTrailingEdgeExit(T agent)
This method is internal and shouldn't be called by user.
|
boolean |
removeAgent(Agent agent)
Removes the given agent from the station.
|
void |
repair()
Repairs station, makes it available again.
|
Attractor |
resourceDestinationAttractor(T agent,
java.util.List<T> allAgents,
Agent unit) |
INode<?,?> |
resourceDestinationNode(T agent,
java.util.List<T> allAgents,
Agent unit) |
double |
resourceDestinationX(T agent,
java.util.List<T> allAgents,
Agent unit) |
double |
resourceDestinationY(T agent,
java.util.List<T> allAgents,
Agent unit) |
double |
resourceDestinationZ(T agent,
java.util.List<T> allAgents,
Agent unit) |
java.lang.Object |
resourcePool(T agent,
java.util.List<T> allAgents) |
int |
resourceQuantity(T agent,
java.util.List<T> allAgents) |
java.lang.Object[][] |
resourceSets(T agent,
java.util.List<T> allAgents) |
boolean |
sendResources(T agent,
java.util.List<T> allAgents,
Agent unit) |
void |
setDelayType(ConveyorSimpleStationDelayType type) |
void |
setFillColor(java.awt.Paint fillColor) |
void |
setLineColor(java.awt.Paint lineColor) |
void |
setLoadingMode(ConveyorSimpleStationLoadingMode mode) |
void |
setQuantity(int quantity)
Sets the number of agents (material items) that must be processed simultaneously.
|
void |
setResourceDestinationType(java.lang.Object resourceDestinationType) |
void |
setSeizeFromOnePool(boolean seizeFromOnePool) |
void |
setUseResources(boolean useResources) |
int |
size()
Returns the current number of agents (material items) inside the station
|
void |
stopProcess()
Stops the station when called.
|
contains, getLength, getNearestPoint, randomPointInside, setNetwork
getConveyor, getOffset, getOffset, setConveyor, setOffset, setOffset
getNetwork
error, getDrawMode, getPresentable, getSpace, initialize, isClickHandled, onClick, setDrawMode, setOwner
executeUserAction, findSVGElement, getName, getSVGId, isVisible, resetSVGState, setVisible, updateDynamicProperties, updateSVGProperties
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getSpace, randomPointInside, randomPointInside, randomPointInside
@Deprecated public ConveyorSimpleStation(ConveyorPath<? extends T> conveyor, ShapeDrawMode drawMode, boolean isPublic, double offset, double lengthInMeters)
public ConveyorSimpleStation(ConveyorPath<? extends T> conveyor, ShapeDrawMode drawMode, boolean isPublic, double offsetInPixels, double lengthInMeters, java.awt.Paint fillColor, java.awt.Paint lineColor, com.anylogic.engine.markup.material_handling.IConveyorSimpleStationDescriptor<T> descriptor)
conveyor
- the conveyordrawMode
- isPublic
- offsetInPixels
- offset measured from the beginning of conveyor to the end of this station, in pixels.lengthInMeters
- the length of this station in meters.descriptor
- public java.awt.Color getLineColor()
public Texture getLineTexture()
public void setLineColor(java.awt.Paint lineColor)
public java.awt.Color getFillColor()
public Texture getFillTexture()
public void setFillColor(java.awt.Paint fillColor)
@AnyLogicInternalAPI public com.anylogic.engine.markup.material_handling.IConveyorSimpleStationDescriptor<T> getLibraryDescriptor()
public int getQuantity()
public void setQuantity(int quantity)
public ConveyorSimpleStationLoadingMode getLoadingMode()
public void setLoadingMode(ConveyorSimpleStationLoadingMode mode)
public ConveyorSimpleStationDelayType getDelayType()
public void setDelayType(ConveyorSimpleStationDelayType type)
public void stopProcess()
public boolean isProcessing()
@AnyLogicInternalCodegenAPI public double delay(T agent, java.util.List<T> allAgents, TimeUnits units)
delay
in interface com.anylogic.engine.markup.material_handling.IConveyorSimpleStationDescriptor<T extends Agent>
agent
- the agent if this station has only one agent. Otherwise - the first (nearest to the exit) agent.allAgents
- list of agents in this station, sorted: 0th element is the nearest to the exit.units
- requested units of the delay value@AnyLogicInternalCodegenAPI public void onProcessStarted(T agent, java.util.List<T> allAgents)
onProcessStarted
in interface com.anylogic.engine.markup.material_handling.IConveyorSimpleStationDescriptor<T extends Agent>
agent
- the agent if this station has only one agent. Otherwise - the first (nearest to the exit) agent.allAgents
- list of agents in this station, sorted: 0th element is the nearest to the exit.@AnyLogicInternalCodegenAPI public void onProcessFinished(T agent, java.util.List<T> allAgents)
onProcessFinished
in interface com.anylogic.engine.markup.material_handling.IConveyorSimpleStationDescriptor<T extends Agent>
agent
- the agent if this station has only one agent. Otherwise - the first (nearest to the exit) agent.allAgents
- list of agents in this station, sorted: 0th element is the nearest to the exit.public int size()
public T getAgent(int index)
public java.util.List<T> getAgents()
public boolean contains(Agent agent)
public boolean removeAgent(Agent agent)
public void onLeadingEdgeEnter(T agent)
com.anylogic.engine.markup.material_handling.IMaterialPointLocation
public void onTrailingEdgeEnter(T agent)
com.anylogic.engine.markup.material_handling.IMaterialAreaLocation
public void onLeadingEdgeExit(T agent)
com.anylogic.engine.markup.material_handling.IMaterialAreaLocation
public void onTrailingEdgeExit(T agent)
com.anylogic.engine.markup.material_handling.IMaterialPointLocation
public boolean isFailed()
isFailed
in interface com.anylogic.engine.markup.material_handling.IMaterialFallible
public void fail()
fail
in interface com.anylogic.engine.markup.material_handling.IMaterialFallible
public void repair()
repair
in interface com.anylogic.engine.markup.material_handling.IMaterialFallible
public void onFailed()
onFailed
in interface com.anylogic.engine.markup.material_handling.IMaterialFallible
public void onRepaired()
onRepaired
in interface com.anylogic.engine.markup.material_handling.IMaterialFallible
public boolean isUseResources()
public void setUseResources(boolean useResources)
public boolean isSeizeFromOnePool()
public void setSeizeFromOnePool(boolean seizeFromOnePool)
public java.lang.Object getResourceDestinationType()
Valid values:
public void setResourceDestinationType(java.lang.Object resourceDestinationType)
public INode<?,?> resourceDestinationNode(T agent, java.util.List<T> allAgents, Agent unit)
public Attractor resourceDestinationAttractor(T agent, java.util.List<T> allAgents, Agent unit)
public double resourceDestinationX(T agent, java.util.List<T> allAgents, Agent unit)
public double resourceDestinationY(T agent, java.util.List<T> allAgents, Agent unit)
public double resourceDestinationZ(T agent, java.util.List<T> allAgents, Agent unit)
Copyright © AnyLogic North America, LLC. All Rights Reserved.