gov.noaa.pmel.sgt.dm
Class SGTFull3DVector

java.lang.Object
  extended by gov.noaa.pmel.sgt.dm.SGTFull3DVector
All Implemented Interfaces:
SGTData, java.io.Serializable, java.lang.Cloneable

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

Defines a data object to be a Vector. Interpretation of U and V is determined by the CoordinateSystem. For Cartesian, U and V are the Cartesian vector components. For Polar , U and V are R (radius) and Theta (angle) vector components, respectively.

Since:
1.0
Version:
$Revision$, $Date$
Author:
Donald Denbo
See Also:
SGTData, CoordinateSystem, Serialized Form

Constructor Summary
SGTFull3DVector()
          Default constructor.
SGTFull3DVector(ThreeDGrid uComp, ThreeDGrid vComp, ThreeDGrid wComp)
          Construct a SGT3DVector from three components.
 
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.
 java.lang.String getTitle()
          Get the vector's title.
 ThreeDGrid getU()
          Get the U component.
 ThreeDGrid getV()
          Get the V component.
 ThreeDGrid getW()
          Get the W component.
 SGTMetaData getXMetaData()
          Returns the X SGTMetaData.
 SoTRange getXRange()
          Returns the range of the X coordinates.
 SGTMetaData getYMetaData()
          Returns the Y SGTMetaData.
 SoTRange getYRange()
          Returns the range of the Y coordinates.
 SGTMetaData getZMetaData()
           
 SoTRange getZRange()
           
 boolean isXTime()
          Returns true if the X coordinate is Time.
 boolean isYTime()
          Returns true if the Y coordinate is Time.
 boolean isZTime()
           
 void removePropertyChangeListener(java.beans.PropertyChangeListener l)
          Remove a PropertyChangeListener from the listener list.
 void setComponents(ThreeDGrid uComp, ThreeDGrid vComp, ThreeDGrid wComp)
          Set the vector components.
 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 vector's title.
 void setU(ThreeDGrid uComp)
          Set the U component.
 void setV(ThreeDGrid vComp)
          Set the V component.
 void setW(ThreeDGrid wComp)
          Set the W component.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SGTFull3DVector

public SGTFull3DVector()
Default constructor.


SGTFull3DVector

public SGTFull3DVector(ThreeDGrid uComp,
                       ThreeDGrid vComp,
                       ThreeDGrid wComp)
Construct a SGT3DVector from three components. The three components must match in both SGTData and CoordinateSystem Interfaces. All components must be the same shape.

Parameters:
uComp - U component of the vector
vComp - V component of the vector
wComp - W component of the vector
Method Detail

copy

public SGTData copy()
Create a copy. Creates a shallow copy.

Specified by:
copy in interface SGTData
Returns:
shallow copy
See Also:
SGTData

getU

public ThreeDGrid getU()
Get the U component.

Returns:
U component

getV

public ThreeDGrid getV()
Get the V component.

Returns:
V component

getW

public ThreeDGrid getW()
Get the W component.

Returns:
W component

setU

public void setU(ThreeDGrid uComp)
Set the U component.

Parameters:
uComp - U component

setV

public void setV(ThreeDGrid vComp)
Set the V component.

Parameters:
vComp - V component

setW

public void setW(ThreeDGrid wComp)
Set the W component.

Parameters:
vComp - W component

setComponents

public void setComponents(ThreeDGrid uComp,
                          ThreeDGrid vComp,
                          ThreeDGrid wComp)
Set the vector components.

Parameters:
uComp - U component
vComp - V component

setTitle

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

Parameters:
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
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
See Also:
Pane, Layer

setId

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


getTitle

public java.lang.String getTitle()
Get the vector's title.

Specified by:
getTitle in interface SGTData
Returns:
the title

isXTime

public boolean isXTime()
Description copied from interface: SGTData
Returns true if the X coordinate is Time.

Specified by:
isXTime in interface SGTData

isYTime

public boolean isYTime()
Description copied from interface: SGTData
Returns true if the Y coordinate is Time.

Specified by:
isYTime in interface SGTData

isZTime

public boolean isZTime()

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

getZMetaData

public SGTMetaData getZMetaData()

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
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
See Also:
SGTData.getXRange()

getZRange

public SoTRange getZRange()

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