edu.stanford.rsl.konrad.geometry.shapes.simple
Class Point3D

java.lang.Object
  extended by edu.stanford.rsl.konrad.geometry.shapes.simple.PointND
      extended by edu.stanford.rsl.konrad.geometry.shapes.simple.Point3D
All Implemented Interfaces:
Transformable, java.io.Serializable
Direct Known Subclasses:
VectorPoint3D

public class Point3D
extends PointND

Wrapper class to model a 3D point.

Author:
akmaier
See Also:
Serialized Form

Constructor Summary
Point3D(double... coordinates)
          Creates a new 3D Point from a list of coordinates.
Point3D(PointND point)
          Copy constructor.
 
Method Summary
 double getX()
          returns the x coordinate
 double getY()
          returns the y coordinate
 double getZ()
          returns the z coordinate
 void setX(double x)
          sets the x coordinate
 void setY(double y)
          sets the y coordinate
 void setZ(double z)
          sets the z coordinate
 
Methods inherited from class edu.stanford.rsl.konrad.geometry.shapes.simple.PointND
applyTransform, clone, equals, euclideanDistance, get, getAbstractVector, getCoordinates, getDimension, set, setCoordinates, toString, updateIfHigher, updateIfLower
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Point3D

public Point3D(double... coordinates)
Creates a new 3D Point from a list of coordinates. Asserts that the list id of length 3.

Parameters:
coordinates -

Point3D

public Point3D(PointND point)
Copy constructor. Asserts that the dimension is 3.

Parameters:
point -
Method Detail

getX

public double getX()
returns the x coordinate

Returns:
x

getY

public double getY()
returns the y coordinate

Returns:
y

getZ

public double getZ()
returns the z coordinate

Returns:
z

setX

public void setX(double x)
sets the x coordinate

Parameters:
x - coordinate

setY

public void setY(double y)
sets the y coordinate

Parameters:
y - coordinate

setZ

public void setZ(double z)
sets the z coordinate

Parameters:
z - coordinate