ucar.unidata.view.sounding
Class AerologicalReadoutTable.PTDerivedReadout

java.lang.Object
  extended by ucar.unidata.view.sounding.RealReadout
      extended by ucar.unidata.view.sounding.AerologicalReadoutTable.MyReadout
          extended by ucar.unidata.view.sounding.AerologicalReadoutTable.PTDerivedReadout
All Implemented Interfaces:
PropertyChangeListener, EventListener
Direct Known Subclasses:
AerologicalReadoutTable.MixingRatioReadout, AerologicalReadoutTable.PotentialTemperatureReadout, AerologicalReadoutTable.SatEquivalentPotTempReadout
Enclosing class:
AerologicalReadoutTable

protected abstract static class AerologicalReadoutTable.PTDerivedReadout
extends AerologicalReadoutTable.MyReadout

Provides support for readouts derived from pressure and temperature.


Nested Class Summary
 
Nested classes/interfaces inherited from class ucar.unidata.view.sounding.RealReadout
RealReadout.FormatProperty, RealReadout.NameProperty, RealReadout.NumericValueProperty, RealReadout.UnitProperty
 
Field Summary
 
Fields inherited from class ucar.unidata.view.sounding.RealReadout
FORMAT, NAME, NUMERIC_STRING, REAL_UNIT, REALTYPE_NAME, REALTYPE_UNIT, SPECIFIED_NAME, SPECIFIED_UNIT, UNIT_STRING
 
Constructor Summary
protected AerologicalReadoutTable.PTDerivedReadout(String name, String unitString, int fractionDigitCount)
          Constructs from a name, unit, and display accuracy.
 
Method Summary
protected  void compute()
          Computes the derived quantity.
protected abstract  Real compute(Real pressure, Real temperature)
          Computes the derived quantity from the pressure and temperature.
 Real getPressure()
          Returns the pressure property.
 Real getTemperature()
          Returns the temperature property.
 void setPressure(Real pressure)
          Sets the pressure property.
 void setTemperature(Real temperature)
          Sets the temperature property.
 
Methods inherited from class ucar.unidata.view.sounding.RealReadout
addPropertyChangeListener, getName, getNumericString, getUnitString, propertyChange, setFormat, setNameUse, setReal, setSpecifiedName, setSpecifiedUnit, setUnitUse
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AerologicalReadoutTable.PTDerivedReadout

protected AerologicalReadoutTable.PTDerivedReadout(String name,
                                                   String unitString,
                                                   int fractionDigitCount)
                                            throws ParseException
Constructs from a name, unit, and display accuracy.

Parameters:
name - The name for the readout.
unitString - The unit specification for the readout.
fractionDigitCount - The number of digits to have after the decimal point.
Throws:
ParseException - Invalid unit specificatin.
Method Detail

setPressure

public void setPressure(Real pressure)
                 throws VisADException,
                        RemoteException
Sets the pressure property.

Parameters:
pressure - The new value.
Throws:
VisADException - VisAD failure.
RemoteException - Java RMI failure.

getPressure

public Real getPressure()
Returns the pressure property.

Returns:
The pressure.

setTemperature

public void setTemperature(Real temperature)
                    throws VisADException,
                           RemoteException
Sets the temperature property.

Parameters:
temperature - The new value.
Throws:
VisADException - VisAD failure.
RemoteException - Java RMI failure.

getTemperature

public Real getTemperature()
Returns the temperature property.

Returns:
The value of the temperature property.

compute

protected void compute()
                throws VisADException,
                       RemoteException
Computes the derived quantity.

Throws:
VisADException - VisAD failure.
RemoteException - Java RMI failure.

compute

protected abstract Real compute(Real pressure,
                                Real temperature)
                         throws VisADException,
                                RemoteException
Computes the derived quantity from the pressure and temperature.

Parameters:
pressure - The pressure.
temperature - The temperature.
Returns:
The value of the derived quantity.
Throws:
VisADException - VisAD failure.
RemoteException - Java RMI failure.