gov.noaa.pmel.util
Class SoTPoint

java.lang.Object
  extended by gov.noaa.pmel.util.SoTPoint
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable

public class SoTPoint
extends java.lang.Object
implements java.io.Serializable, java.lang.Cloneable

SoTPoint has two coordinates which are of type SoTValue. SoT stands for space or time, but being basically lazy I've abbreviated it.

Version:
$Revision$, $Date$
Author:
Donald Denbo
See Also:
Serialized Form

Constructor Summary
SoTPoint()
          Default constructor.
SoTPoint(double x, double y)
          Construct a SoTPoint from doubles.
SoTPoint(double x, GeoDate y)
          Construct a SoTPoint from a double and a GeoDate.
SoTPoint(double x, long y)
           
SoTPoint(GeoDate x, double y)
          Construct a SoTPoint from a GeoDate and a double.
SoTPoint(long x, double y)
           
SoTPoint(SoTPoint pt)
          Construct a SoTPoint from a SoTPoint.
SoTPoint(SoTValue x, SoTValue y)
          Construct a SoTPoint from SoTValues.
 
Method Summary
 void add(SoTPoint point)
          Add to point.
 SoTPoint copy()
          Make a copy of the SoTRange.
 boolean equals(SoTPoint stp)
          Test for equality.
 SoTValue getX()
          Get x value
 SoTValue getY()
          Get y value
 boolean isXTime()
          Test if x value is time
 boolean isYTime()
          Test if y value is time
 void setX(SoTValue x)
          Set x value
 void setY(SoTValue y)
          Set y value
 java.lang.String toString()
          Convert SoTPoint to a default string
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SoTPoint

public SoTPoint()
Default constructor.


SoTPoint

public SoTPoint(SoTValue x,
                SoTValue y)
Construct a SoTPoint from SoTValues.

Parameters:
x - space or time coordinate
y - space or time coordinate

SoTPoint

public SoTPoint(double x,
                double y)
Construct a SoTPoint from doubles.


SoTPoint

public SoTPoint(double x,
                GeoDate y)
Construct a SoTPoint from a double and a GeoDate.


SoTPoint

public SoTPoint(double x,
                long y)
Since:
sgt 3.0

SoTPoint

public SoTPoint(GeoDate x,
                double y)
Construct a SoTPoint from a GeoDate and a double.


SoTPoint

public SoTPoint(long x,
                double y)
Since:
sgt 3.0

SoTPoint

public SoTPoint(SoTPoint pt)
Construct a SoTPoint from a SoTPoint.

Method Detail

getX

public SoTValue getX()
Get x value


setX

public void setX(SoTValue x)
Set x value

Since:
sgt 3.0

getY

public SoTValue getY()
Get y value


setY

public void setY(SoTValue y)
Set y value

Since:
sgt 3.0

equals

public boolean equals(SoTPoint stp)
Test for equality. For equality both x and y values must be equal.


isXTime

public boolean isXTime()
Test if x value is time


isYTime

public boolean isYTime()
Test if y value is time


add

public void add(SoTPoint point)
Add to point.

Since:
sgt 3.0

copy

public SoTPoint copy()
Make a copy of the SoTRange.

Since:
sgt 3.0

toString

public java.lang.String toString()
Convert SoTPoint to a default string

Overrides:
toString in class java.lang.Object
Returns:
string representation of the SoTPoint.