Package com.anylogic.engine.markup
- Constructor Summary
- Method Summary
- Methods inherited from class com.anylogic.engine.markup.AbstractDrawableMarkupAggregator
- Methods inherited from class com.anylogic.engine.markup.AbstractMarkupAggregator
- Methods inherited from class java.lang.Object
- Constructor Detail
- Method Detail
- initialize
- addAll
- add
- add
- setDensityMap
- getZ
- getZ
- getGates
- getNodes
- getAreas
- getWalls
- getTargetLines
- getPedFlowStatistics
- getDensityMap
- getDensityMaps
- getDensityMap
- getPathways
- getServices
- getEscalators
- getLifts
- getCranes
- getStorages
- getBulkConveyorBelts
- getPipes
- getStorageTanks
- getNetworks
- getConveyorNetworks
- getRailwayNetworks
- getRoadNetworks
- getShapes
- getObstacles
- elementsInternal
- getSpace
- setDataSource
- getPeds
- size
- pedestriansCount
- getCompatibleAgentExtensionClass
- getBoundingRectangle
- getMarkups
- toString
- java.lang.Object
-
- com.anylogic.engine.markup.AbstractMarkupAggregator<Agent>
-
- com.anylogic.engine.markup.AbstractDrawableMarkupAggregator
-
- com.anylogic.engine.markup.Level
- All Implemented Interfaces:
java.io.Serializable
public class Level extends AbstractDrawableMarkupAggregator
Level logically groups other animation elements like shapes, space markup elements, controls and charts.
Levels operate with top-level elements, e.g. a shape inside a group knows about level from that group,
and a path inside a network knows about level from that network.
- Author:
- AnyLogic North America, LLC https://anylogic.com
- See Also:
- Serialized Form
Level(Agent owner,
java.lang.String name,
ShapeDrawMode drawMode,
double z) |
|
Level(Agent owner,
java.lang.String name,
ShapeDrawMode drawMode,
double z,
boolean isPublic,
boolean visible) |
|
Level(Agent owner,
java.lang.String name,
ShapeDrawMode drawMode,
double z,
boolean isPublic,
boolean visible,
LevelMarkup... markupShapes) |
|
Constructor | Description |
---|
void |
add(LevelElement shape) |
Add shape to this level
|
void |
add(LevelMarkup markup) |
Add markup element to this level
|
void |
addAll(LevelElement... elements) |
Adds specified elements to the level.
|
java.util.stream.Stream<? extends AggregatableAnimationElement> |
elementsInternal() |
This method is internal and shouldn't be called by user.
it may be removed/renamed in future. |
java.util.List<AreaNode> |
getAreas() |
Deprecated.
|
BoundingRectangle |
getBoundingRectangle() |
|
java.util.List<BulkConveyorBelt> |
getBulkConveyorBelts() |
Returns a list of all conveyor belts on this level
|
java.lang.Class<? extends ExtAgentWithSpatialMetrics> |
getCompatibleAgentExtensionClass() |
|
java.util.List<ConveyorNetwork> |
getConveyorNetworks() |
Returns a list of all conveyor networks on this level
|
java.util.List<Crane<?>> |
getCranes() |
Returns a list of all cranes on this level
|
DensityMap |
getDensityMap() |
Deprecated.
deprecated in version 8.5.0, will be removed in the future releases.
|
DensityMap |
getDensityMap(DensityMapType type) |
Returns the density map of a particular type from this level
|
java.util.List<DensityMap> |
getDensityMaps() |
Returns a list of all density maps on this level
|
java.util.List<EscalatorGroup> |
getEscalators() |
Returns a list of all escalator groups on this level
|
java.util.List<LevelGate> |
getGates() |
Returns a list of all gates on this level
|
java.util.List<Lift<?>> |
getLifts() |
Returns a list of all lifts on this level
|
java.util.List<LevelMarkup> |
getMarkups() |
|
java.util.List<Network> |
getNetworks() |
Returns a list of all networks on this level
|
java.util.List<Node> |
getNodes() |
Returns a list of all nodes on this level
|
java.util.List<Obstacle> |
getObstacles() |
This method is internal and shouldn't be called by user.
it may be removed/renamed in future. |
java.util.List<Pathway> |
getPathways() |
Returns a list of all pathways on this level
|
java.util.List<PedFlowStatistics> |
getPedFlowStatistics() |
Returns a list of all elements that collect pedestrian statistics on this level.
|
java.util.Collection<Agent> |
getPeds() |
Return unmodifiable list of all the pedestrians in this level.
|
java.util.List<Pipe> |
getPipes() |
Returns a list of all pipes on this level
|
java.util.List<RailwayNetwork> |
getRailwayNetworks() |
Returns a list of all railway networks on this level
|
java.util.List<RoadNetwork> |
getRoadNetworks() |
Returns a list of all road networks on this level
|
java.util.List<ServiceBase<?,?>> |
getServices() |
Returns a list of all services on this level
|
java.util.List<java.lang.Object> |
getShapes() |
Returns the collection of shapes in the level.
|
Agent |
getSpace() |
Returns the space where the markup element is defined
|
java.util.List<Storage> |
getStorages() |
Returns a list of all storages on this level
|
java.util.List<StorageTank> |
getStorageTanks() |
Returns a list of all storage tanks on this level
|
java.util.List<TargetLine> |
getTargetLines() |
Returns a list of all target lines on this level
|
java.util.List<AbstractWall> |
getWalls() |
Returns a list of all walls on this level
|
double |
getZ() |
Returns the base level z coordinate.
|
double |
getZ(double x,
double y) |
Returns the z coordinate of the given point
|
void |
initialize() |
This method finalizes creation of level.
|
int |
pedestriansCount() |
Returns number of pedestrians currently on this level.
|
void |
setDataSource(LevelDataSource dataSource) |
|
void |
setDensityMap(DensityMap densityMap) |
Deprecated.
deprecated in version 8.5.0, will be removed in the future releases.
|
int |
size() |
Deprecated.
deprecated in version 8.5.0, will be removed in the future releases.
|
java.lang.String |
toString() |
|
Modifier and Type | Method | Description |
---|
getDrawMode, setDrawMode
error, getName, getOwner, initializeInternal, isVisible, onAggregatorVisibilityChanged, setVisible
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
public Level(Agent owner, java.lang.String name, ShapeDrawMode drawMode, double z)
public Level(Agent owner, java.lang.String name, ShapeDrawMode drawMode, double z, boolean isPublic, boolean visible)
public Level(Agent owner, java.lang.String name, ShapeDrawMode drawMode, double z, boolean isPublic, boolean visible, LevelMarkup... markupShapes)
public void initialize()
This method finalizes creation of level. Should be called for levels created using
short versions of constructors (without markup shapes) - after all the elements are added to the level.
Invokes initialization for all the contained elements.
public void addAll(LevelElement... elements)
Adds specified elements to the level. The level should be uninitialized.
- Parameters:
elements
- elements to be added. Pass an array of elements or specify them separated by commas
public void add(LevelMarkup markup)
Add markup element to this level
- Parameters:
markup
- markup element
public void add(LevelElement shape)
Add shape to this level
- Parameters:
shape
- shape element
@Deprecated public void setDensityMap(DensityMap densityMap)
Deprecated.
deprecated in version 8.5.0, will be removed in the future releases. Please use
add(LevelMarkup markup)
instead- Parameters:
densityMap
- the density map
public double getZ()
Returns the base level z coordinate. Areas in this level may modify the level
- Returns:
- the base level z coordinate
- See Also:
getZ(double, double)
public double getZ(double x, double y)
Returns the z coordinate of the given point
- Returns:
- the z coordinate of the given point
public java.util.List<LevelGate> getGates()
Returns a list of all gates on this level
public java.util.List<Node> getNodes()
Returns a list of all nodes on this level
@Deprecated public java.util.List<AreaNode> getAreas()
Deprecated.
NB: the returned list also contains areas from services
- Returns:
public java.util.List<AbstractWall> getWalls()
Returns a list of all walls on this level
public java.util.List<TargetLine> getTargetLines()
Returns a list of all target lines on this level
public java.util.List<PedFlowStatistics> getPedFlowStatistics()
Returns a list of all elements that collect pedestrian statistics on this level.
@Deprecated public DensityMap getDensityMap()
Deprecated.
deprecated in version 8.5.0, will be removed in the future releases. Please use
getDensityMaps()
instead- Returns:
- pedestrian density map
public java.util.List<DensityMap> getDensityMaps()
Returns a list of all density maps on this level
public DensityMap getDensityMap(DensityMapType type)
Returns the density map of a particular type from this level
- Parameters:
type
- the type of the density map: either pedestrian or transporter
public java.util.List<Pathway> getPathways()
Returns a list of all pathways on this level
public java.util.List<ServiceBase<?,?>> getServices()
Returns a list of all services on this level
public java.util.List<EscalatorGroup> getEscalators()
Returns a list of all escalator groups on this level
public java.util.List<Lift<?>> getLifts()
Returns a list of all lifts on this level
public java.util.List<Crane<?>> getCranes()
Returns a list of all cranes on this level
public java.util.List<Storage> getStorages()
Returns a list of all storages on this level
public java.util.List<BulkConveyorBelt> getBulkConveyorBelts()
Returns a list of all conveyor belts on this level
public java.util.List<Pipe> getPipes()
Returns a list of all pipes on this level
public java.util.List<StorageTank> getStorageTanks()
Returns a list of all storage tanks on this level
public java.util.List<Network> getNetworks()
Returns a list of all networks on this level
public java.util.List<ConveyorNetwork> getConveyorNetworks()
Returns a list of all conveyor networks on this level
public java.util.List<RailwayNetwork> getRailwayNetworks()
Returns a list of all railway networks on this level
public java.util.List<RoadNetwork> getRoadNetworks()
Returns a list of all road networks on this level
public java.util.List<java.lang.Object> getShapes()
Returns the collection of shapes in the level. The
collection can contain either members of class
Shape
for shapes,
and of class ReplicatedShape
for replicated shapes.
It may also contain 3D lights and cameras.- Returns:
- the collection of shapes in the level
@AnyLogicInternalAPI public java.util.List<Obstacle> getObstacles()
This method is internal and shouldn't be called by user.
it may be removed/renamed in future.
it may be removed/renamed in future.
@AnyLogicInternalAPI public java.util.stream.Stream<? extends AggregatableAnimationElement> elementsInternal()
Description copied from class:
AbstractMarkupAggregator
This method is internal and shouldn't be called by user.
it may be removed/renamed in future.
it may be removed/renamed in future.
- Specified by:
elementsInternal
in classAbstractMarkupAggregator<Agent>
public Agent getSpace()
Returns the space where the markup element is defined
- Returns:
- the space associated with this element
@AnyLogicInternalAPI public void setDataSource(LevelDataSource dataSource)
public java.util.Collection<Agent> getPeds()
Return unmodifiable list of all the pedestrians in this level.
- Returns:
- list of all the pedestrians in this level
@Deprecated public int size()
Deprecated.
deprecated in version 8.5.0, will be removed in the future releases. Please use
pedestriansCount()
instead
Returns number of pedestrians currently on this level.- Returns:
- number of pedestrians currently on this level.
public int pedestriansCount()
Returns number of pedestrians currently on this level.
- Returns:
- number of pedestrians currently on this level.
@AnyLogicInternalAPI public final java.lang.Class<? extends ExtAgentWithSpatialMetrics> getCompatibleAgentExtensionClass()
@AnyLogicInternalAPI public BoundingRectangle getBoundingRectangle()
@AnyLogicInternalAPI public java.util.List<LevelMarkup> getMarkups()
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
How can we improve this article?
-