Class ScalarQuantity

java.lang.Object
ucar.visad.quantities.Quantity
ucar.visad.quantities.ScalarQuantity
Direct Known Subclasses:
Acceleration, Altitude, CAPE, CIN, Density, Direction, GasConstant, GeopotentialAltitude, LatentHeatOfEvaporation, Length, MassicEnergy, MassicVolume, MolecularWeightOfDryAir, MolecularWeightOfWater, Pressure, PseudoAdiabaticLapseRate, RelativeHumidity, SpecificHeatCapacityOfDryAir, SpecificHumidity, Speed, Temperature, WaterVaporMixingRatio, WindComponent

public abstract class ScalarQuantity extends Quantity
Provides support for scalar quantities.
Version:
$Id: ScalarQuantity.java,v 1.11 2005/05/13 18:35:44 jeffmc Exp $
Author:
Steven R. Emmerson
  • Constructor Details

    • ScalarQuantity

      protected ScalarQuantity(String name, Unit unit, Set set) throws VisADException
      Constructs from a name, default unit, and default sampling set.
      Parameters:
      name - The name.
      unit - The default unit.
      set - The default sampling set.
      Throws:
      VisADException - if a core VisAD failure occurs.
    • ScalarQuantity

      protected ScalarQuantity(RealType realType) throws VisADException
      Constructs from an existing RealType.
      Parameters:
      realType - The existing RealType.
      Throws:
      VisADException - if a core VisAD failure occurs.
    • ScalarQuantity

      protected ScalarQuantity(RealType realType, CoordinateSystem defaultCS) throws VisADException
      Constructs from an existing RealType and default CoordinateSystem.
      Parameters:
      realType - The existing RealType.
      defaultCS - The default CoordinateSystem.
      Throws:
      VisADException - if a core VisAD failure occurs.
    • ScalarQuantity

      protected ScalarQuantity(RealType realType, CoordinateSystem defaultCS, Set defaultSet) throws VisADException
      Constructs from an existing RealType, default CoordinateSystem, and default sampling set.
      Parameters:
      realType - The existing RealType.
      defaultCS - The default CoordinateSystem.
      defaultSet - The default sampling set.
      Throws:
      VisADException - if a core VisAD failure occurs.
    • ScalarQuantity

      protected ScalarQuantity(RealTupleType realTupleType)
      Constructs from an existing RealTupleType.
      Parameters:
      realTupleType - The existing RealTupleType.
  • Method Details

    • getRealType

      protected static RealType getRealType(String name, Unit unit) throws TypeException, VisADException
      Returns a RealType that is compatible with this class given a name and a compatible unit.
      Parameters:
      name - The name for the RealType.
      unit - A compatible unit for the RealType.
      Returns:
      A corresponding RealType.
      Throws:
      TypeException - if a necessary RealType can't be created.
      VisADException - if a core VisAD failure occurs.
    • getRealType

      protected static RealType getRealType(String name, Unit unit, Set set) throws TypeException, VisADException
      Returns a RealType that is compatible with this class given a name, a compatible unit, and a compatible sampling set.
      Parameters:
      name - The name for the RealType.
      unit - A compatible unit for the RealType.
      set - A compatible sampling set for the RealType.
      Returns:
      A corresponding RealType.
      Throws:
      TypeException - if a necessary RealType can't be created.
      VisADException - if a core VisAD failure occurs.
    • realType

      protected final RealType realType() throws VisADException
      Returns the associated RealType.
      Returns:
      The associated RealType.
      Throws:
      VisADException