lt.monarch.math.geom
Class Point3D

java.lang.Object
  extended by java.awt.geom.Point2D
      extended by java.awt.geom.Point2D.Double
          extended by lt.monarch.math.geom.Point2D
              extended by lt.monarch.math.geom.Point3D
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, GeneralPoint

public class Point3D
extends Point2D

3D point

See Also:
Serialized Form

Nested Class Summary
Modifier and Type Class and Description
 
Nested classes/interfaces inherited from class java.awt.geom.Point2D
java.awt.geom.Point2D.Double, java.awt.geom.Point2D.Float
 
Field Summary
Modifier and Type Field and Description
 double z
           
 
Fields inherited from class java.awt.geom.Point2D.Double
x, y
 
Constructor Summary
Constructor and Description
Point3D()
          Point3D constructor
Point3D(double x, double y, double z)
          Point3D constructor
Point3D(Point3D p)
          Constructs a new Point3D using coordinate values of the specified point.
 
Method Summary
Modifier and Type Method and Description
 Point3D clone()
           
 boolean equals(java.lang.Object o)
           
 double getZ()
          Gets z coordinate
 void set(double x, double y, double z)
          Sets the specified coordinate values to the point
 void set(Point3D p)
          Set coordinate of point
 void setZ(double z)
          Sets z coordinate
 java.lang.String toString()
          Returns a string representation of this Point2D object.
 
Methods inherited from class lt.monarch.math.geom.Point2D
set, setX, setY
 
Methods inherited from class java.awt.geom.Point2D.Double
getX, getY, setLocation
 
Methods inherited from class java.awt.geom.Point2D
distance, distance, distance, distanceSq, distanceSq, distanceSq, hashCode, setLocation
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface lt.monarch.math.geom.GeneralPoint
getX, getY
 

Field Detail

z

public double z
Constructor Detail

Point3D

public Point3D(double x,
               double y,
               double z)
Point3D constructor

Parameters:
x - x coordinate
y - y coordinate
z - z coordinate

Point3D

public Point3D()
Point3D constructor


Point3D

public Point3D(Point3D p)
Constructs a new Point3D using coordinate values of the specified point.

Parameters:
p - the Point3D to take coordinate values from
Method Detail

set

public void set(Point3D p)
Set coordinate of point

Parameters:
p - 3D point

getZ

public double getZ()
Gets z coordinate

Returns:
z coordinate

setZ

public void setZ(double z)
Sets z coordinate

Parameters:
z - z coordinate

set

public void set(double x,
                double y,
                double z)
Sets the specified coordinate values to the point

Parameters:
x - the x coordinate value; has to be in range [0,1]
y - the y coordinate value; has to be in range [0,1]
z - the z coordinate value; has to be in range [0,1]

toString

public java.lang.String toString()
Description copied from class: Point2D
Returns a string representation of this Point2D object.

Overrides:
toString in class Point2D
Returns:
a string representation of this point

clone

public Point3D clone()
Overrides:
clone in class java.awt.geom.Point2D

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.awt.geom.Point2D