Package com.anylogic.engine.markup
- Field Summary
- Constructor Summary
- Method Summary
- Methods inherited from class com.anylogic.engine.markup.AreaNode
- Methods inherited from class com.anylogic.engine.markup.Node
- Methods inherited from class com.anylogic.engine.markup.NetworkMarkupElement
- Methods inherited from class com.anylogic.engine.markup.MarkupShape
- Methods inherited from class com.anylogic.engine.markup.AbstractMarkup
- Methods inherited from class java.lang.Object
- Methods inherited from interface com.anylogic.engine.markup.AbstractPositionalMarkup
- Methods inherited from interface com.anylogic.engine.markup.AggregatableAnimationElement
- Methods inherited from interface com.anylogic.engine.markup.AnimationStaticLocationProvider
- Methods inherited from interface com.anylogic.engine.markup.HasLevel
- Methods inherited from interface com.anylogic.engine.markup.material_handling.IMaterialMarkupLibraryDescriptor
- Methods inherited from interface com.anylogic.engine.markup.INetworkMarkupElement
- Methods inherited from interface com.anylogic.engine.markup.INode
- Methods inherited from interface java.lang.Iterable
- Methods inherited from interface com.anylogic.engine.markup.LevelElement
- Methods inherited from interface com.anylogic.engine.presentation.SVGElement
- Methods inherited from interface com.anylogic.engine.presentation.UsdElement
- Constructor Details
- Method Details
- java.lang.Object
- com.anylogic.engine.markup.AbstractMarkup
- com.anylogic.engine.markup.MarkupShape
- com.anylogic.engine.markup.NetworkMarkupElement
- com.anylogic.engine.markup.Node
- com.anylogic.engine.markup.AreaNode<T>
- com.anylogic.engine.markup.RectangularNode<T>
- All Implemented Interfaces:
AbstractPositionalMarkup
,AggregatableAnimationElement
,AnimationStaticLocationProvider
,IAreaNodeDescriptor<T>
,IDescriptor
,HasLevel
,IMarkupLibraryDescriptor
,INetworkMarkupElement
,INode<Node,
,Path> LevelElement
,LevelMarkup
,com.anylogic.engine.markup.material_handling.IMaterialMarkupLibraryDescriptor
,com.anylogic.engine.markup.material_handling.INodeDescriptor<Agent>
,SVGElement
,UsdElement
,Serializable
,Iterable<T>
public class RectangularNode<T extends Agent> extends AreaNode<T>
- See Also:
- Serialized Form
Constructor | Description |
---|---|
RectangularNode() | |
RectangularNode | |
RectangularNode |
Deprecated.
deprecated in version 8.4, will be removed in the future releases
|
RectangularNode |
Deprecated.
deprecated in version 8.4, will be removed in the future releases
|
RectangularNode |
Deprecated.
deprecated in version 8.4, will be removed in the future releases
|
RectangularNode |
Deprecated.
deprecated in version 8.4, will be removed in the future releases
|
RectangularNode |
Deprecated.
deprecated in version 8.4, will be removed in the future releases
|
RectangularNode |
Deprecated.
deprecated in version 8.4, will be removed in the future releases
|
RectangularNode | |
RectangularNode |
Modifier and Type | Method | Description |
---|---|---|
double | area |
Returns the area of this area, measured in area units
|
boolean | contains |
Test if the shape contains the point with the given coordinates (relative
to this shape's container, i.e.
|
BoundingRectangle | getBoundingRectangle() | |
Point | getCenter() |
Returns coordinates of the rectangle center.
|
Point | getCenter |
Returns coordinates of the rectangle center.
|
double | getHeight() |
Returns the height of the markup shape.
|
double | getNearestPoint |
Calculates (using the
output object) the point in this space markup element
nearest to the given (x, y, z) point. |
double | getNearestPoint |
Calculates (using the
output object) the point in this space markup element
nearest to the given (x, y) point. |
Point[] | getPoints() | |
Position | getPosition |
Returns the item position with the given index.
In case of any wrong argument returns zero-index position (position for index=0 with totalNumber=1). |
double | getRotation() |
Returns the rotation of the shape.
|
double | getWidth() |
Returns the width of the markup shape.
|
Point | randomPointInside |
Returns the randomly chosen point inside/along the given space markup element.
|
void | setRotation |
Sets the rotation of the shape.
|
void | setSize |
Sets the width and height of the markup shape.
|
Area3D | toArea3D() |
Returns the 3D representation of this area
|
accessRestrictionCondition, addAgent, addAreaDataSource, addAttractor, addAttractor, agents, close, contains, density, getAccessRestrictionType, getAdmittedTransporters, getAgentsWaitingToEnter, getAttractors, getCapacity, getFillColor, getFillTexture, getLineColor, getLineStyle, getLineTexture, getLineWidth, getMaxSpeed, getNumberOfAdmittedAgents, getNumberOfAdmittedTransporters, getPeds, getPositionChoiceMode, getRestrictedAgentClass, getSchedule, getSlope, getThroughput, getX, getY, getZ, getZ, isAccessRestricted, isAllowedToEnter, isApplied, isAvoidedIfClosed, isLimitSpeed, isOpen, isReadyToEnter, isSpeedRestricted, iterator, notifyCancelReadyToEnter, notifyReadyToEnter, notifyReadyToEnter2, notifyReadyToExit, onClose, onEnter, onEnterDenied, onExit, onOpen, open, recalculateAccessibility, removeAgent, removeAreaDataSource, removeFromQueue, restrictAccessByCapacity, restrictAccessBySchedule, restrictAccessByThroughput, restrictAccessManually, restrictSpeed, setAccessRestricted, setAccessRestrictionType, setAvoidedIfClosed, setCapacity, setLimitSpeed, setLineColor, setLineColor, setLineStyle, setLineWidth, setMaxSpeed, setOpen, setPos, setPositionChoiceMode, setRestrictedAgentClass, setSchedule, setSlope, setSpeedRestricted, setThroughput
addConnection, getCompatibleAgentExtensionClass, getConnection, getConnectionsCount, getMaterialLibraryDescriptor, getNumberOfTransporters, getTransferDistance, getTransferPositionByPercent, getTransporter, getTransporters, setFillColor, setFillColor
error, getFullName, getOutsideLevelZ, getPresentable, getSpace, initialize, isClickHandled, isPublic, onClick, remove, setDrawMode, setOwner
discardOwner, executeUserAction, findSVGElement, getName, getOrGenerateUSDId, getSVGId, initializeInternal, isVisible, onAggregatorInitialized, onAggregatorVisibilityChanged, removeSVGFromOwner, resetSVGState, setVisible, updateDynamicProperties, updateDynamicPropertiesStructural, updateSVGProperties
Methods inherited from interface com.anylogic.engine.markup.material_handling.IMaterialMarkupLibraryDescriptor
getMarkup, setMarkup
public RectangularNode()
public RectangularNode(Agent owner)
@Deprecated public RectangularNode(Agent owner, ShapeDrawMode drawMode, boolean isPublic, double x, double y, double z, double width, double height, double rotation, Slope slope, Paint fillColor, Paint lineColor, double lineWidth, LineStyle lineStyle, PositionChoiceMode positionChoiceMode, PathEnd<Path>[] pathEnds, Attractor... attractors)
Deprecated.
deprecated in version 8.4, will be removed in the future releases
- Parameters:
owner
-drawMode
-isPublic
-x
-y
-z
-width
-height
-rotation
-slope
-fillColor
-lineColor
-lineWidth
-lineStyle
-positionChoiceMode
-pathEnds
-attractors
-
@AnyLogicInternalCodegenAPI public RectangularNode(Agent owner, ShapeDrawMode drawMode, boolean isPublic, IAreaNodeDescriptor<T> descriptor, double x, double y, double z, double width, double height, double rotation, Slope slope, Paint fillColor, Paint lineColor, double lineWidth, LineStyle lineStyle, PositionChoiceMode positionChoiceMode, PathEnd<Path>[] pathEnds, Attractor... attractors)
@AnyLogicInternalCodegenAPI public RectangularNode(Agent owner, ShapeDrawMode drawMode, boolean isPublic, IAreaNodeDescriptor<T> descriptor, double x, double y, double z, double width, double height, double rotation, Paint fillColor, Paint lineColor, double lineWidth, LineStyle lineStyle, PositionChoiceMode positionChoiceMode, PathEnd<Path>[] pathEnds, Attractor... attractors)
@Deprecated public RectangularNode(Agent owner, ShapeDrawMode drawMode, boolean isPublic, double x, double y, double z, double width, double height, double rotation, Slope slope, Paint fillColor, Paint lineColor, double lineWidth, LineStyle lineStyle, PositionChoiceMode positionChoiceMode, boolean limitSpeed, double maxSpeedInMPS, PathEnd<Path>[] pathEnds, Attractor... attractors)
Deprecated.
deprecated in version 8.4, will be removed in the future releases
- Parameters:
owner
-drawMode
-isPublic
-x
-y
-z
-width
-height
-rotation
-slope
-fillColor
-lineColor
-lineWidth
-lineStyle
-positionChoiceMode
-limitSpeed
-maxSpeedInMPS
-pathEnds
-attractors
-
@Deprecated public RectangularNode(Agent owner, ShapeDrawMode drawMode, boolean isPublic, double x, double y, double z, double width, double height, double rotation, Paint fillColor, Paint lineColor, double lineWidth, LineStyle lineStyle, PositionChoiceMode positionChoiceMode, PathEnd<Path>[] pathEnds, Attractor... attractors)
Deprecated.
deprecated in version 8.4, will be removed in the future releases
- Parameters:
owner
-drawMode
-isPublic
-x
-y
-z
-width
-height
-rotation
-fillColor
-lineColor
-lineWidth
-lineStyle
-positionChoiceMode
-pathEnds
-attractors
-
@Deprecated public RectangularNode(Agent owner, ShapeDrawMode drawMode, boolean isPublic, double x, double y, double z, double width, double height, double rotation, Paint fillColor, Paint lineColor, double lineWidth, LineStyle lineStyle, PositionChoiceMode positionChoiceMode, boolean limitSpeed, double maxSpeedInMPS, PathEnd<Path>[] pathEnds, Attractor... attractors)
Deprecated.
deprecated in version 8.4, will be removed in the future releases
- Parameters:
owner
-drawMode
-isPublic
-x
-y
-z
-width
-height
-rotation
-fillColor
-lineColor
-lineWidth
-lineStyle
-positionChoiceMode
-limitSpeed
-maxSpeedInMPS
-pathEnds
-attractors
-
@Deprecated public RectangularNode(Agent owner, ShapeDrawMode drawMode, boolean isPublic, double x, double y, double z, double width, double height, double rotation, Slope slope, Paint fillColor, Paint lineColor, double lineWidth, LineStyle lineStyle, PositionChoiceMode positionChoiceMode, Attractor... attractors)
Deprecated.
deprecated in version 8.4, will be removed in the future releases
- Parameters:
owner
-drawMode
-isPublic
-x
-y
-z
-width
-height
-rotation
-slope
-fillColor
-lineColor
-lineWidth
-lineStyle
-positionChoiceMode
-attractors
-
@Deprecated public RectangularNode(Agent owner, ShapeDrawMode drawMode, boolean isPublic, double x, double y, double z, double width, double height, double rotation, Paint fillColor, Paint lineColor, double lineWidth, LineStyle lineStyle, PositionChoiceMode positionChoiceMode, Attractor... attractors)
Deprecated.
deprecated in version 8.4, will be removed in the future releases
- Parameters:
owner
-drawMode
-isPublic
-x
-y
-z
-width
-height
-rotation
-fillColor
-lineColor
-lineWidth
-lineStyle
-positionChoiceMode
-attractors
-
public double getWidth()
Returns the width of the markup shape.
- Returns:
- the width of the markup shape
public double getHeight()
Returns the height of the markup shape.
- Returns:
- the height of the markup shape
public void setSize(double width, double height)
Sets the width and height of the markup shape.
- Parameters:
width
- the new width of the markup shapeheight
- the new height of the markup shape
public void setRotation(double rotation)
Sets the rotation of the shape.
- Parameters:
r
- the new value of rotation in radians
public double getRotation()
Returns the rotation of the shape.
- Specified by:
getRotation
in interfaceAbstractPositionalMarkup
- Returns:
- the rotation of the shape in radians, clockwise
public Point randomPointInside(Random rng, Point out)
Description copied from interface:
INetworkMarkupElement
Returns the randomly chosen point inside/along the given space markup element.
This method utilises the given Random Number Generator.
- Specified by:
randomPointInside
in interfaceINetworkMarkupElement
- Parameters:
rng
- the random number generator.out
- output object to write to, may benull
- Returns:
- the randomly chosen point
public double getNearestPoint(double px, double py, Point output)
Description copied from class:
NetworkMarkupElement
Calculates (using the
output
object) the point in this space markup element
nearest to the given (x, y) point. Returns the square of distance to the point
(in the XY-projection).
All the calculations are performed in the horizontal projection (z-coordinates aren't used,
as if all of the z coordinates were zero).- Specified by:
getNearestPoint
in classNetworkMarkupElement
- Parameters:
px
- x coordinate of the pointpy
- y coordinate of the pointoutput
- the output point to write result to. Note thatoutput.z
is left unchanged.- Returns:
- the square of distance to the nearest point in the horizontal (XY) projection
public double getNearestPoint(double x, double y, double z, Point output)
Description copied from class:
NetworkMarkupElement
Calculates (using the
output
object) the point in this space markup element
nearest to the given (x, y, z) point. Returns the square of distance to the point.- Specified by:
getNearestPoint
in classNetworkMarkupElement
- Parameters:
x
- x coordinate of the pointy
- y coordinate of the pointz
- z coordinate of the pointoutput
- the output point to write result to.- Returns:
- the square of distance to the nearest point
@AnyLogicInternalAPI public double area(AreaUnits units)
Description copied from class:
AreaNode
Returns the area of this area, measured in area units
public boolean contains(double px, double py)
Description copied from class:
MarkupShape
Test if the shape contains the point with the given coordinates (relative
to this shape's container, i.e. in the same system with the coordinates
of this shape, x and y)
- Specified by:
contains
in interfaceINetworkMarkupElement
- Specified by:
contains
in classMarkupShape
- Parameters:
px
- the x coordinate relative to this shape's containerpy
- the y coordinate relative to this shape's container- Returns:
true
if the shape contains the point with the given coordinates
public Point getCenter()
Returns coordinates of the rectangle center.
- Returns:
- coordinates of the rectangle center
public Point getCenter(Point p)
Returns coordinates of the rectangle center.
- Returns:
- coordinates of the rectangle center
public Position getPosition(int index, int totalNumber, Position out)
Description copied from interface:
AnimationStaticLocationProvider
Returns the item position with the given index.
In case of any wrong argument returns zero-index position (position for index=0 with totalNumber=1).
In case of any wrong argument returns zero-index position (position for index=0 with totalNumber=1).
- Specified by:
getPosition
in interfaceAnimationStaticLocationProvider
- Overrides:
getPosition
in classAreaNode<T extends Agent>
- Parameters:
index
- the index of some item positions, should be not negative and less thantotalNumber
totalNumber
- the total number of item positions, should be positiveout
- output object to write to, may benull
- Returns:
- the Position object with coordinates of the requested item position
@AnyLogicInternalAPI public BoundingRectangle getBoundingRectangle()
@AnyLogicInternalAPI public Point[] getPoints()
public Area3D toArea3D()
Returns the 3D representation of this area
- Returns:
- the 3D representation of this area