All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class convexHull.CPoint

java.lang.Object
   |
   +----convexHull.CPoint

public class CPoint
extends Object
Type point.


Variable Index

 o x
X coordinate
 o y
Y coordinate

Constructor Index

 o CPoint()
sets default coordinates to 0.0
 o CPoint(float, float)
sets coordinates as requested

Method Index

 o isEqual(CPoint)
compares to another CPoint instance
 o toString()
converts the point coordinates to a string of format [x,y]

Variables

 o x
 public float x
X coordinate

 o y
 public float y
Y coordinate

Constructors

 o CPoint
 public CPoint()
sets default coordinates to 0.0

 o CPoint
 public CPoint(float x,
               float y)
sets coordinates as requested

Parameters:
x - new X coordinate
y - new Y coordinate

Methods

 o isEqual
 public boolean isEqual(CPoint p2)
compares to another CPoint instance

Parameters:
p2 - - the other instance of CPoint
Returns:
- returns true if the two instances are the same points, otherwise returns false
 o toString
 public String toString()
converts the point coordinates to a string of format [x,y]

Returns:
String - string representation of the point
Overrides:
toString in class Object

All Packages  Class Hierarchy  This Package  Previous  Next  Index