- java.lang.Object
-
- org.arakhne.afc.math.geometry.d3.d.PathElement3d
-
- All Implemented Interfaces:
Serializable,Cloneable,PathElement3afp,PathElement3D
- Direct Known Subclasses:
PathElement3d.ClosePathElement3d,PathElement3d.CurvePathElement3d,PathElement3d.LinePathElement3d,PathElement3d.MovePathElement3d,PathElement3d.QuadPathElement3d
public abstract class PathElement3d extends Object implements PathElement3afp
An element of the path with 2 double precision floating-point numbers.- Since:
- 13.0
- Version:
- 17.0 2020-01-04 14:41:43
- Author:
- Stéphane GALLAND, Thomas PIOTROWSKI
- See Also:
- Serialized Form
- Maven Group Id:
- org.arakhne.afc.core
- Maven Artifact Id:
- mathgeom
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classPathElement3d.ClosePathElement3dAn element of the path that represents aCLOSE.(package private) static classPathElement3d.CurvePathElement3dAn element of the path that represents aCURVE_TO.(package private) static classPathElement3d.LinePathElement3dAn element of the path that represents aLINE_TO.(package private) static classPathElement3d.MovePathElement3dAn element of the path that represents aMOVE_TO.(package private) static classPathElement3d.QuadPathElement3dAn element of the path that represents aQUAD_TO.
-
Field Summary
Fields Modifier and Type Field Description protected doubletoXTarget point.protected doubletoYTarget point.protected doubletoZTarget point.protected PathElementTypetypeType of the element.
-
Constructor Summary
Constructors Constructor Description PathElement3d(PathElementType type, double tox, double toy, double toz)Constructor.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract booleanequals(Object obj)doublegetToX()Replies the x coordinate of the target point.doublegetToY()Replies the y coordinate of the target point.doublegetToZ()Replies the z coordinate of the target point.PathElementTypegetType()Replies the type of the element.abstract inthashCode()abstract double[]toArray()Copy the coords into an array, except the source point.StringtoString()-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.arakhne.afc.math.geometry.d3.afp.PathElement3afp
getCtrlX1, getCtrlX2, getCtrlY1, getCtrlY2, getCtrlZ1, getCtrlZ2, getFromX, getFromY, getFromZ, toArray, toArray
-
Methods inherited from interface org.arakhne.afc.math.geometry.d3.PathElement3D
isDrawable, isEmpty
-
-
-
-
Field Detail
-
type
protected final PathElementType type
Type of the element.
-
toX
protected final double toX
Target point.
-
toY
protected final double toY
Target point.
-
toZ
protected final double toZ
Target point.
-
-
Constructor Detail
-
PathElement3d
PathElement3d(PathElementType type, double tox, double toy, double toz)
Constructor.- Parameters:
type- is the type of the element.tox- the x coordinate of the target point.toy- the y coordinate of the target point.toz- the z coordinate of the target point.
-
-
Method Detail
-
getToX
@Pure public final double getToX()
Description copied from interface:PathElement3afpReplies the x coordinate of the target point.- Specified by:
getToXin interfacePathElement3afp- Returns:
- the x coordinate.
-
getToY
@Pure public final double getToY()
Description copied from interface:PathElement3afpReplies the y coordinate of the target point.- Specified by:
getToYin interfacePathElement3afp- Returns:
- the y coordinate.
-
getToZ
@Pure public final double getToZ()
Description copied from interface:PathElement3afpReplies the z coordinate of the target point.- Specified by:
getToZin interfacePathElement3afp- Returns:
- the z coordinate.
-
getType
@Pure public final PathElementType getType()
Description copied from interface:PathElement3DReplies the type of the element.- Specified by:
getTypein interfacePathElement3afp- Specified by:
getTypein interfacePathElement3D- Returns:
trueif the points are the same; otherwisefalse.
-
toArray
@Pure public abstract double[] toArray()
Copy the coords into an array, except the source point.- Returns:
- the array of the points, except the source point.
-
-