Package com.anylogic.engine.markup
- java.lang.Object
- com.anylogic.engine.markup.ShortestPathData<N,
- All Implemented Interfaces:
IPathData
,Serializable
- Direct Known Subclasses:
ContinuousShortestPathData
,GISShortestPathData
public abstract class ShortestPathData<N extends INode<N,P>, extends Object implements IPathDataP extends IPath<N>>
This class keeps data to move an agent through a network.
- Author:
- AnyLogic North America, LLC https://anylogic.com
- See Also:
- Serialized Form
Modifier and Type | Field | Description |
---|---|---|
double | distance | |
SimpleDirection | fromDirection |
Tells, where to go from (
fromPath , fromOffset ) |
N | fromNode | |
double | fromOffset | |
P | fromPath | |
double | fromX | |
double | fromY | |
double | fromZ | |
INetwork<N, | network | |
Point | source | |
double | sourceRotation | |
double | sourceSegmentDistance | |
double | sourceVerticalRotation | |
Point | target | |
double | targetRotation | |
double | targetSegmentDistance | |
double | targetVerticalRotation | |
SimpleDirection | toDirectionReverse | |
P | toHubIncomingPath | |
N | toNode | |
double | toOffset | |
P | toPath | |
double | toX | |
double | toY | |
double | toZ |
Constructor | Description |
---|---|
ShortestPathData() |
Modifier and Type | Method | Description |
---|---|---|
abstract Position | getFromTargetPosition |
Returns the Position object that corresponds to the point that lies
at a certain distance from target point in the direction to the end point
|
INetwork<N, | getNetwork() |
Returns the network for this path data
|
abstract Position | getToSourcePosition |
Returns the Position object that corresponds to the point that lies
at a certain distance from start point in the direction to source point
|
boolean | isPlainMovement() |
Checks if this shortest path data corresponds to plain movement
|
void | reset() | |
abstract void | resetFromTargetDirection() |
Resets the direction from target to the stored toPoint
|
abstract void | resetToSourceDirection() |
Resets the direction from the stored fromPoint to the source
|
abstract void | setFromTargetDirection |
Sets the direction and rotations from the target point to the specified argument point
|
abstract void | setToSourceDirection |
Sets the direction and rotations from the specified argument point to the source point
|
public P extends IPath<N> fromPath
public double fromOffset
public N extends INode<N,P> fromNode
public double fromX
public double fromY
public double fromZ
public SimpleDirection fromDirection
Tells, where to go from (
fromPath
, fromOffset
)public P extends IPath<N> toPath
public double toOffset
public N extends INode<N,P> toNode
public double toX
public double toY
public double toZ
public SimpleDirection toDirectionReverse
public P extends IPath<N> toHubIncomingPath
public double distance
public Point source
public double sourceRotation
public double sourceVerticalRotation
public double sourceSegmentDistance
public Point target
public double targetRotation
public double targetVerticalRotation
public double targetSegmentDistance
public INetwork<N extends INode<N,P>, networkP extends IPath<N>>
public ShortestPathData()
public void reset()
public INetwork<N,P> getNetwork()
Returns the network for this path data
- Returns:
- the network for this path data
public boolean isPlainMovement()
Checks if this shortest path data corresponds to plain movement
- Returns:
- true if this data corresponds to plain movement, false otherwise
public abstract void setFromTargetDirection(Point toPoint)
Sets the direction and rotations from the target point to the specified argument point
- Parameters:
toPoint
- point to set direction to
public abstract void setToSourceDirection(Point fromPoint)
Sets the direction and rotations from the specified argument point to the source point
- Parameters:
fromPoint
- point to set direction from
public abstract void resetFromTargetDirection()
Resets the direction from target to the stored toPoint
public abstract void resetToSourceDirection()
Resets the direction from the stored fromPoint to the source
public abstract Position getToSourcePosition(double offset, Position out)
Returns the Position object that corresponds to the point that lies
at a certain distance from start point in the direction to source point
- Parameters:
offset
- the distanceout
- output object, may be null- Returns:
- position at offset from start point towards source point
public abstract Position getFromTargetPosition(double offset, Position out)
Returns the Position object that corresponds to the point that lies
at a certain distance from target point in the direction to the end point
- Parameters:
offset
- the distanceout
- output object, may be null- Returns:
- position at offset from target point towards end point