Class AddeSoundingAdapter

All Implemented Interfaces:
Serializable, PropertiedBean, SoundingAdapter

public class AddeSoundingAdapter extends SoundingAdapterImpl implements SoundingAdapter
Class for retrieving upper air data from an ADDE remote server. Creates a SoundingOb for each of the stations on the remote server for the latest available data.
See Also:
  • Constructor Details

    • AddeSoundingAdapter

      public AddeSoundingAdapter()
      Construct an empty AddeSoundingAdapter
    • AddeSoundingAdapter

      public AddeSoundingAdapter(String server) throws Exception
      Retreive upper air data from a remote ADDE server using only mandatory data.
      Parameters:
      server - name or IP address of remote server
      Throws:
      Exception - (AddeException) if there is no data available or there is trouble connecting to the remote server
    • AddeSoundingAdapter

      public AddeSoundingAdapter(String server, String dataset) throws Exception
      Retreive upper air data from a remote ADDE server using only mandatory data.
      Parameters:
      server - name or IP address of remote server
      dataset - name of ADDE dataset (group/descriptor)
      Throws:
      Exception - (AddeException) if there is no data available or there is trouble connecting to the remote server
    • AddeSoundingAdapter

      public AddeSoundingAdapter(String server, String mandDataset, String sigDataset) throws Exception
      Retreive upper air data from a remote ADDE server using only mandatory data.
      Parameters:
      server - name or IP address of remote server
      mandDataset - name of mandatory level upper air ADDE dataset (group/descriptor)
      sigDataset - name of significant level upper air ADDE dataset (group/descriptor)
      Throws:
      Exception - (AddeException) if there is no data available or there is trouble connecting to the remote server
    • AddeSoundingAdapter

      public AddeSoundingAdapter(String server, String mandDataset, String sigDataset, boolean mainHours) throws Exception
      Retreive upper air data from a remote ADDE server using only mandatory data.
      Parameters:
      server - name or IP address of remote server
      mandDataset - name of mandatory level upper air ADDE dataset (group/descriptor)
      sigDataset - name of significant level upper air ADDE dataset (group/descriptor)
      mainHours - only get data for main (00 & 12Z) hours
      Throws:
      Exception - (AddeException) if there is no data available or there is trouble connecting to the remote server
  • Method Details

    • init

      protected void init() throws Exception
      Initialize the class. Populate the variable list and get the server and dataset information.
      Overrides:
      init in class SoundingAdapterImpl
      Throws:
      Exception - problem occurred
    • update

      public void update()
      Update this adapter for new data
      Specified by:
      update in interface SoundingAdapter
    • setSource

      public void setSource(String server)
      Set the ADDE server name
      Specified by:
      setSource in interface SoundingAdapter
      Parameters:
      server - server name or IP address
    • getSource

      public String getSource()
      Get the source of the data (server)
      Specified by:
      getSource in interface SoundingAdapter
      Returns:
      server name or IP address
    • setMandDataset

      public void setMandDataset(String value)
      Set the mandatory data set name
      Parameters:
      value - mandatory data set name
    • getMandDataset

      public String getMandDataset()
      Set the mandatory data set name
      Returns:
      the mandatory data set name
    • setSigDataset

      public void setSigDataset(String value)
      Set the significant data set name
      Parameters:
      value - the significant data set name
    • getSigDataset

      public String getSigDataset()
      Get the significant data set name
      Returns:
      the significant data set name
    • initSoundingOb

      public SoundingOb initSoundingOb(SoundingOb sound)
      Check to see if the RAOB has any data
      Specified by:
      initSoundingOb in interface SoundingAdapter
      Specified by:
      initSoundingOb in class SoundingAdapterImpl
      Parameters:
      sound - sounding to check
      Returns:
      a sounding with data
    • getMandatoryURL

      public String getMandatoryURL(SoundingOb sound)
      Make the mandatory levels URL for the given sounding
      Parameters:
      sound - sounding
      Returns:
      mandatory url
    • getSigURL

      public String getSigURL(SoundingOb sound)
      Make the url for the significant levels for the sounding
      Parameters:
      sound - the sounding
      Returns:
      sig url
    • main

      public static void main(String[] args)
      test by running java ucar.unidata.data.sounding.AddeSoundingAdapter
      Parameters:
      args - array of arguments. Takes up to 3 arguments as "server mandatory dataset significant dataset" Use "x" for any of these arguments to use the default.
    • toString

      public String toString()
      The string representation
      Overrides:
      toString in class Object
      Returns:
      The string