Package com.anylogic.engine.markup
- Constructor Summary
- Method Summary
- 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.AggregatableAnimationElement
- Methods inherited from interface com.anylogic.engine.markup.INetworkMarkupElement
- Constructor Details
- Method Details
- java.lang.Object
- com.anylogic.engine.markup.AbstractMarkup
- com.anylogic.engine.markup.MarkupShape
- com.anylogic.engine.markup.NetworkMarkupElement
- All Implemented Interfaces:
AggregatableAnimationElement
,HasLevel
,INetworkMarkupElement
,SVGElement
,Serializable
- Direct Known Subclasses:
Node
,PalletRack
,Path
@AnyLogicInternalAPI public abstract class NetworkMarkupElement extends MarkupShape implements INetworkMarkupElement
- See Also:
- Serialized Form
Constructor | Description |
---|---|
NetworkMarkupElement() | |
NetworkMarkupElement | |
NetworkMarkupElement |
Modifier and Type | Method | Description |
---|---|---|
ShapeDrawMode | getDrawMode() |
Returns the drawing mode of the shape (where to draw this shape: 2D, 3D or 2D+3D).
If the shape has been created with no-argument constructor, and has no specific limitations (like 2D-only), and drawing mode hasn't yet been set, then it is initialized to default (2D + 3D). |
Level | getLevel() |
Returns level associated with this space markup element or
null
if this element has no level |
double | getNearestPoint |
Calculates (using the
output object) the point in this space markup element
nearest to the given (x, y, z) point. |
abstract 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. |
abstract double | getNearestPoint |
Calculates (using the
output object) the point in this space markup element
nearest to the given (x, y) point. |
double | getNearestPoint |
Calculates (using the
output object) the point in this space markup element
nearest to the given point. |
Network | getNetwork() | |
void | setLevel |
Sets the level of this element.
|
contains, error, getFullName, getOutsideLevelZ, getPresentable, getSpace, initialize, isClickHandled, isPublic, onClick, remove, setDrawMode, setOwner
discardOwner, executeUserAction, findSVGElement, getName, getSVGId, initializeInternal, isVisible, onAggregatorInitialized, onAggregatorVisibilityChanged, removeSVGFromOwner, resetSVGState, setVisible, updateDynamicProperties, updateDynamicPropertiesStructural, updateSVGProperties
public NetworkMarkupElement()
public NetworkMarkupElement(Agent owner)
public NetworkMarkupElement(Agent owner, ShapeDrawMode drawMode, boolean isPublic)
public ShapeDrawMode getDrawMode()
Description copied from class:
MarkupShape
Returns the drawing mode of the shape (where to draw this shape: 2D, 3D or 2D+3D).
If the shape has been created with no-argument constructor, and has no specific limitations (like 2D-only), and drawing mode hasn't yet been set, then it is initialized to default (2D + 3D).
If the shape has been created with no-argument constructor, and has no specific limitations (like 2D-only), and drawing mode hasn't yet been set, then it is initialized to default (2D + 3D).
- Overrides:
getDrawMode
in classMarkupShape
- Returns:
- the draw mode for this shape
public abstract double getNearestPoint(double x, double y, Point output)
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).- Parameters:
x
- x coordinate of the pointy
- 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, LengthUnits units, Point output)
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).- Parameters:
x
- x coordinate of the pointy
- y coordinate of the pointunits
- the units of lengthoutput
- 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
- Since:
- 7.1
public abstract double getNearestPoint(double x, double y, double z, Point output)
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.- 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
public double getNearestPoint(double x, double y, double z, LengthUnits units, Point output)
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.- Parameters:
x
- x coordinate of the pointy
- y coordinate of the pointz
- z coordinate of the pointunits
- the units of lengthoutput
- the output point to write result to.- Returns:
- the square of distance to the nearest point
- Since:
- 7.1
public double getNearestPoint(Point givenPoint, Point out)
Description copied from interface:
INetworkMarkupElement
Calculates (using the
output
object) the point in this space markup element
nearest to the given point. Returns the square of distance to the point.- Specified by:
getNearestPoint
in interfaceINetworkMarkupElement
- Parameters:
givenPoint
- given pointout
- the output point to write result to.- Returns:
- the square of distance to the nearest point
public Network getNetwork()
- Specified by:
getNetwork
in interfaceINetworkMarkupElement
- Returns:
- network this markup element belongs to
or
null
if this element isn't a part of a network
public Level getLevel()
Description copied from interface:
HasLevel
Returns level associated with this space markup element or
null
if this element has no level- Specified by:
getLevel
in interfaceHasLevel
- Specified by:
getLevel
in classMarkupShape
- Returns:
- the level associated with this space markup element
public void setLevel(Level level)
Sets the level of this element. The element should not be contained in any level before the call
of this method. Also sets the owner of the specified level as the owner of this element
- Parameters:
level
- new level