Package PamUtils
Class Coordinate3d
java.lang.Object
PamUtils.Coordinate3d
- All Implemented Interfaces:
Serializable
,Cloneable
,ManagedParameters
,PamCoordinate
public class Coordinate3d
extends Object
implements Serializable, Cloneable, PamCoordinate, ManagedParameters
Class definition for a x,y coordinate number type.
- Author:
- David McLaren
- See Also:
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
clone()
double
Get the geometric distance between two coordinates.double
getCoordinate
(int iCoordinate) Get an indexed coordinate.int
Get a set of data that describes all of the parameters in a classGet a double precision pointjavafx.geometry.Point2D
Get a double precision point output as a JavaFX library Point2D object.void
setCoordinate
(int iCoordinate, double value) Set a coordinate valuetoString()
-
Field Details
-
x
public double x -
y
public double y -
z
public double z
-
-
Constructor Details
-
Coordinate3d
public Coordinate3d() -
Coordinate3d
public Coordinate3d(double x, double y) -
Coordinate3d
public Coordinate3d(double x, double y, double z) -
Coordinate3d
-
-
Method Details
-
assign
-
getXYPoint
-
getPoint2D
Get a double precision point- Returns:
- Doube precision Point2D.
-
getPoint2DFX
public javafx.geometry.Point2D getPoint2DFX()Get a double precision point output as a JavaFX library Point2D object.- Returns:
- Doube precision Point2D.
-
distance
Get the geometric distance between two coordinates.- Parameters:
o
- other coordinate.- Returns:
- geometric distance.
-
getCoordinate
public double getCoordinate(int iCoordinate) Description copied from interface:PamCoordinate
Get an indexed coordinate.- Specified by:
getCoordinate
in interfacePamCoordinate
- Parameters:
iCoordinate
- coordinate index.- Returns:
- coordinate value.
-
setCoordinate
public void setCoordinate(int iCoordinate, double value) Description copied from interface:PamCoordinate
Set a coordinate value- Specified by:
setCoordinate
in interfacePamCoordinate
- Parameters:
iCoordinate
- index of coordinate (0,1,2)value
- value to set.
-
getNumCoordinates
public int getNumCoordinates()- Specified by:
getNumCoordinates
in interfacePamCoordinate
- Returns:
- the number of coordinates.
-
clone
-
toString
-
getParameterSet
Description copied from interface:ManagedParameters
Get a set of data that describes all of the parameters in a class- Specified by:
getParameterSet
in interfaceManagedParameters
- Returns:
- description of the parameters in a class.
-