adams.gui.visualization.stats.core
Class Point

java.lang.Object
  extended by adams.gui.visualization.stats.core.Point
All Implemented Interfaces:
Serializable, Comparable

public class Point
extends Object
implements Comparable, Serializable

Class for points that contain a double x and y value, use for sorting.

Version:
$Revision: 4584 $
Author:
msf8
See Also:
Serialized Form

Field Summary
protected  double m_X
          x value of the point
protected  double m_Y
          y value of the point
protected static long serialVersionUID
          for serialization
 
Constructor Summary
Point(double x, double y)
          Constructor
 
Method Summary
 int compareTo(Object obj)
          Compares this point object to the parameter depending on the m_X fields
 double getX()
          Get the x value of the point
 double getY()
          get the y value of the point
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

protected static final long serialVersionUID
for serialization

See Also:
Constant Field Values

m_X

protected double m_X
x value of the point


m_Y

protected double m_Y
y value of the point

Constructor Detail

Point

public Point(double x,
             double y)
Constructor

Parameters:
x - x value
y - y value
Method Detail

compareTo

public int compareTo(Object obj)
Compares this point object to the parameter depending on the m_X fields

Specified by:
compareTo in interface Comparable
Parameters:
obj - Point to compare against this point

getX

public double getX()
Get the x value of the point

Returns:
x value

getY

public double getY()
get the y value of the point

Returns:
y value


Copyright © 2012 University of Waikato, Hamilton, NZ. All Rights Reserved.