gov.noaa.pmel.sgt.dm
Class SimplePoint

java.lang.Object
  |
  +--gov.noaa.pmel.sgt.dm.SimplePoint
All Implemented Interfaces:
Cartesian, java.lang.Cloneable, CoordinateSystem, SGTData, SGTPoint

public class SimplePoint
extends java.lang.Object
implements SGTPoint, Cartesian, java.lang.Cloneable

SimplePoint provides an implementation of the SGTPoint and Cartesian interfaces.

Since:
1.0
Version:
$Revision: 1.11 $, $Date: 2001/12/13 19:07:05 $
Author:
Donald Denbo
See Also:
SGTPoint, Cartesian

Constructor Summary
SimplePoint()
          Default constructor.
SimplePoint(double xloc, double yloc, java.lang.String title)
          Simple Point constructor.
 
Method Summary
 void addPropertyChangeListener(java.beans.PropertyChangeListener l)
          Add a PropertyChangeListener to the listener list.
 SGTData copy()
          Create a copy.
 java.lang.String getId()
          Get the unique identifier.
 SGLabel getKeyTitle()
          Get a title formatted for a Key.
 GeoDate getTime()
          Get the time coordinate.
 java.lang.String getTitle()
          Get the title.
 double getValue()
          Get the associated value.
 SGTMetaData getValueMetaData()
          Get the associated value SGTMetaData.
 double getX()
          Get the X coordinate.
 SGTMetaData getXMetaData()
          Returns the X SGTMetaData.
 SoTRange getXRange()
          Returns the range of the X coordinates.
 double getY()
          Get the Y coordinate
 SGTMetaData getYMetaData()
          Returns the Y SGTMetaData.
 SoTRange getYRange()
          Returns the range of the Y coordinates.
 boolean hasValue()
          Is there an associated value?
 boolean isXTime()
          Is the X coordinate Time?
 boolean isYTime()
          Is the Y coordinate Time?
 void removePropertyChangeListener(java.beans.PropertyChangeListener l)
          Remove a PropertyChangeListener from the listener list.
 void setId(java.lang.String ident)
          Set the unique identifier.
 void setKeyTitle(SGLabel title)
          Set the title formatted for the VectorKey.
 void setTitle(java.lang.String title)
          Set the title.
 void setValue(double value, java.lang.String name, java.lang.String units)
          The the associated value and basic metadata.
 void setX(double xloc)
          Set the X coordinate.
 void setXMetaData(SGTMetaData md)
          Set the SGTMetaData associated with the x coordinate
 void setY(double yloc)
          Set the Y coordinate.
 void setYMetaData(SGTMetaData md)
          Set the SGTMetaData associated with the y coordinate
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimplePoint

public SimplePoint()
Default constructor.

SimplePoint

public SimplePoint(double xloc,
                   double yloc,
                   java.lang.String title)
Simple Point constructor.
Parameters:
xloc - X coordinate
yloc - Y coordinate
title - the title
Method Detail

copy

public SGTData copy()
Create a copy.
Specified by:
copy in interface SGTData
Since:
2.0
See Also:
SGTData

getX

public double getX()
Get the X coordinate.
Specified by:
getX in interface SGTPoint

getY

public double getY()
Get the Y coordinate
Specified by:
getY in interface SGTPoint

getValue

public double getValue()
Get the associated value.
Specified by:
getValue in interface SGTPoint

hasValue

public boolean hasValue()
Is there an associated value?
Specified by:
hasValue in interface SGTPoint

getTime

public GeoDate getTime()
Get the time coordinate.
Specified by:
getTime in interface SGTPoint

isXTime

public boolean isXTime()
Is the X coordinate Time?
Specified by:
isXTime in interface SGTData

isYTime

public boolean isYTime()
Is the Y coordinate Time?
Specified by:
isYTime in interface SGTData

getTitle

public java.lang.String getTitle()
Get the title.
Specified by:
getTitle in interface SGTData

setTitle

public void setTitle(java.lang.String title)
Set the title.

getKeyTitle

public SGLabel getKeyTitle()
Description copied from interface: SGTData
Get a title formatted for a Key. JPlotLayout will use this if an explicit Key title is not given in the addData method.
Specified by:
getKeyTitle in interface SGTData
Following copied from interface: gov.noaa.pmel.sgt.dm.SGTData
See Also:
SGLabel, ColorKey, LineKey, PointCollectionKey, VectorKey

setKeyTitle

public void setKeyTitle(SGLabel title)
Set the title formatted for the VectorKey.

getId

public java.lang.String getId()
Get the unique identifier. The presence of the identifier is optional, but if it is present it should be unique. This field is used to search for the layer that contains the data.
Specified by:
getId in interface SGTData
Returns:
unique identifier
Since:
2.0
See Also:
Pane, Layer

setId

public void setId(java.lang.String ident)
Set the unique identifier.

getValueMetaData

public SGTMetaData getValueMetaData()
Get the associated value SGTMetaData.
Specified by:
getValueMetaData in interface SGTPoint

setX

public void setX(double xloc)
Set the X coordinate.
Property Change: dataModified.

setY

public void setY(double yloc)
Set the Y coordinate.
Property Change: dataModified.

setValue

public void setValue(double value,
                     java.lang.String name,
                     java.lang.String units)
The the associated value and basic metadata.
Property Change: associatedDataModified.
Parameters:
value - associated data
name - values name
units - values units

setXMetaData

public void setXMetaData(SGTMetaData md)
Set the SGTMetaData associated with the x coordinate
Since:
2.0

setYMetaData

public void setYMetaData(SGTMetaData md)
Set the SGTMetaData associated with the y coordinate
Since:
2.0

getXMetaData

public SGTMetaData getXMetaData()
Description copied from interface: SGTData
Returns the X SGTMetaData.
Specified by:
getXMetaData in interface SGTData

getYMetaData

public SGTMetaData getYMetaData()
Description copied from interface: SGTData
Returns the Y SGTMetaData.
Specified by:
getYMetaData in interface SGTData

getXRange

public SoTRange getXRange()
Description copied from interface: SGTData
Returns the range of the X coordinates. If all the data in the array is missing, this method will return Double.NaN as the start and end values for data of type double and return GeoDate(Long.MIN_VALUE) for data of type GeoDate.
Specified by:
getXRange in interface SGTData
Following copied from interface: gov.noaa.pmel.sgt.dm.SGTData
See Also:
GeoDate.isMissing()

getYRange

public SoTRange getYRange()
Description copied from interface: SGTData
Returns the range of the Y coordinates.
Specified by:
getYRange in interface SGTData
Following copied from interface: gov.noaa.pmel.sgt.dm.SGTData
See Also:
SGTData.getXRange()

addPropertyChangeListener

public void addPropertyChangeListener(java.beans.PropertyChangeListener l)
Description copied from interface: SGTData
Add a PropertyChangeListener to the listener list.
Specified by:
addPropertyChangeListener in interface SGTData

removePropertyChangeListener

public void removePropertyChangeListener(java.beans.PropertyChangeListener l)
Description copied from interface: SGTData
Remove a PropertyChangeListener from the listener list.
Specified by:
removePropertyChangeListener in interface SGTData


Send comments about the Scientific Graphics toolkit to dwd@pmel.noaa.gov. For more information about Java Development in the EPIC Group see the EPIC Software Page
Generated on December 13 2001