Class AddeImageParameterDataSource

java.lang.Object
ucar.unidata.collab.SharableImpl
ucar.unidata.data.DataSourceImpl
ucar.unidata.data.imagery.ImageDataSource
ucar.unidata.data.imagery.AddeImageDataSource
edu.wisc.ssec.mcidasv.data.adde.AddeImageParameterDataSource
All Implemented Interfaces:
ucar.unidata.collab.Sharable, ucar.unidata.data.DataSource, ucar.unidata.data.DataSourceFactory, ucar.unidata.xml.XmlPersistable

public class AddeImageParameterDataSource extends ucar.unidata.data.imagery.AddeImageDataSource
Abstract DataSource class for images files.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
     

    Nested classes/interfaces inherited from class ucar.unidata.data.imagery.ImageDataSource

    ucar.unidata.data.imagery.ImageDataSource.ImageDataInfo
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
    static final String
     
    static final String
     
    private String
     
    private String
     
    private Hashtable<String,ucar.unidata.data.DataSelection>
     
    (package private) AreaDirectory[][]
    _more_
    (package private) HashMap<Integer,Double>
     
    (package private) HashMap<Integer,Double>
     
    (package private) HashMap<Integer,Integer>
     
    private String
     
    static final String
     
    (package private) boolean
     
    (package private) boolean
     
    (package private) boolean
     
    private int
     
    private int
     
    private float
     
    private boolean
    Whether or not this DataSource was loaded from a bundle.
    private boolean
    Are any of the data choices based upon remote files?
    private boolean
     
    private List
     
    private Hashtable
     
    (package private) boolean
     
    (package private) boolean
     
    (package private) boolean
     
     
    private ucar.unidata.data.DataChoice
     
    private ucar.unidata.data.GeoSelection
     
    static final String
     
    static final String
     
    private int
     
    private int
     
    private static final org.slf4j.Logger
     
    private float
     
    static final String
     
    static final String
     
    static final String
     
    static final String
     
     
    private int
     
    private FlatField
     
    private int
     
    private AREAnav
     
     
     
     
    The first projection we find
    private String
     
    private int
     
    private List
     
    private double
     
    private int
     
    private double
     
    private int
     
    private int
     
    private String
     
    private Boolean
     
    private Hashtable
     
    private Boolean
     
    static final String
    Public keys for server, group, dataset, user, project.
    private String
     
    private Hashtable
     
    static final String
     
    static final String
     
    static final String
     
    protected List<ucar.unidata.data.DataChoice>
     
    static final String
     

    Fields inherited from class ucar.unidata.data.imagery.AddeImageDataSource

    addeImageDataSelection, allBandDirs

    Fields inherited from class ucar.unidata.data.imagery.ImageDataSource

    descriptorsToUse, imageList, imageTimes, myDataChoices, PROP_BANDINFO, PROP_IMAGETYPE, timeMap, TYPE_RADAR, TYPE_SATELLITE

    Fields inherited from class ucar.unidata.data.DataSourceImpl

    changeDataPathsCbx, dataCacheKey, dataChoices, geoSelectionPanel, haveBeenUnPersisted, okToContinue, PARAM_SHOW_HIDE, PARAM_SHOW_NO, PARAM_SHOW_YES

    Fields inherited from interface ucar.unidata.data.DataSource

    DATAPATH_DATE_FORMAT, DATAPATH_DATE_PATTERN, MOST_RECENT, ordinalNames, PROP_AUTOCREATEDISPLAY, PROP_BASEDIRECTORY, PROP_CACHEABLE, PROP_DATACHOICENAME, PROP_DISPLAYPROPERTIES, PROP_DOCUMENTLINKS, PROP_FILEPATTERN, PROP_GEOLOCATION, PROP_ICON, PROP_NAME, PROP_POLLINFO, PROP_RESOLVERURL, PROP_SERVICE_HTTP, PROP_SUBPROPERTIES, PROP_TIMELABELS, PROP_TIMESTRIDE, PROP_TITLE
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    AddeImageParameterDataSource(ucar.unidata.data.DataSourceDescriptor descriptor, String[] images, Hashtable properties)
    Create a new AddeImageParameterDataSource with an array of ADDE URL strings.
    AddeImageParameterDataSource(ucar.unidata.data.DataSourceDescriptor descriptor, String image, Hashtable properties)
    Creates a AddeImageParameterDataSource with a single ADDE URL.
    AddeImageParameterDataSource(ucar.unidata.data.DataSourceDescriptor descriptor, List images, Hashtable properties)
    Creates a new AddeImageParameterDataSource with an List of ADDE URL strings.
    AddeImageParameterDataSource(ucar.unidata.data.DataSourceDescriptor descriptor, ucar.unidata.data.imagery.ImageDataset ids, Hashtable properties)
    Create a new AddeImageParameterDataSource with the given dataset.
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    addDataChoice(ucar.unidata.data.DataChoice choice)
    Insert the new DataChoice into the dataChoice list.
    protected boolean
     
    boolean
    Is this data source capable of saving its data to local disk
    void
    Create the set of DataChoice that represent the data held by this data source.
    private void
     
    _more_
    private List
    getChoicesFromSubset(ucar.unidata.data.CompositeDataChoice choice, ucar.unidata.data.DataSelection subset)
    Get the subset of the composite based on the selection
    protected Data
    getDataInner(ucar.unidata.data.DataChoice dataChoice, ucar.unidata.data.DataCategory category, ucar.unidata.data.DataSelection dataSelection, Hashtable requestProperties)
    Create the actual data represented by the given DataChoice.
    protected String
    Get the file prefix to use for when saving data to local disk
    ucar.unidata.data.DataSelection
    Overridden so that McIDAS-V can attempt to return the correct DataSelection for the current DataChoice.
    Return the list of times held by the DataSelection member.
    ucar.unidata.data.imagery.AddeImageDescriptor
    A utility method that helps us deal with legacy bundles that used to have String file names as the id of a data choice.
    getDescriptors(ucar.unidata.data.DataChoice dataChoice, ucar.unidata.data.DataSelection subset)
    Get a list of descriptors from the choice and subset
     
    Overwrite base class method to return the name of this class.
    boolean
     
    static String
    getKey(String src, String key)
     
    private float[]
     
    boolean
     
    ucar.unidata.util.PollingInfo
    Get the PollingInfo property.
    getPreviewDirectories(ucar.unidata.data.imagery.AddeImageDescriptor imageDescriptor)
     
    private ucar.unidata.data.imagery.AddeImageDescriptor
    getPreviewDirectory(ucar.unidata.data.imagery.AddeImageDescriptor aid, ucar.unidata.data.DataChoice dataChoice)
     
    private void
     
    int
     
    double
     
    int
     
    double
     
    int
     
    int
     
     
    boolean
     
    ucar.unidata.data.DataSelection
    getSelForChoice(ucar.unidata.data.DataChoice choice)
     
    private String
    getServer(String urlString)
     
    boolean
    Whether or not the user decided to show a preview of their image.
     
     
    protected String
    Create the first part of the ADDE request URL
    protected void
    Show the given error to the user.
    private boolean
    hasBandInfo(ucar.unidata.data.DataChoice dataChoice)
    Check if the DataChoice has a BandInfo for its ID
    protected boolean
    Do we have polling info object
    boolean
    hasSelForChoice(ucar.unidata.data.DataChoice choice)
     
    void
    _more_
    protected boolean
    Method for intializing the data.
    protected void
    initDataSelectionComponents(List components, ucar.unidata.data.DataChoice dataChoice)
    _more_
    static boolean
    isFromFile(ucar.unidata.data.imagery.AddeImageDescriptor descriptor)
    Checks to see if a given AddeImageDescriptor is based upon a local (or remote) file.
    protected boolean
    Are we currently polling.
    private static String
    makeBandParam(ucar.unidata.data.imagery.AddeImageDescriptor descriptor)
     
    private static String
    makeBandParam(ucar.unidata.data.imagery.BandInfo bi)
    Make a parameter name for the BandInfo
    makeImage(ucar.unidata.data.imagery.AddeImageDescriptor aid, MathType rangeType, boolean fromSequence, String readLabel, ucar.unidata.data.DataSelection subset)
    Create the single image defined by the given AddeImageDescriptor.
    protected ImageSequence
    makeImageSequence(ucar.unidata.data.DataChoice dataChoice, ucar.unidata.data.DataSelection subset)
    Create the image sequence defined by the given dataChoice.
    private boolean
    makePreviewImage(ucar.unidata.data.DataChoice dataChoice)
    A hook to allow this data source to add data selection components to the IDV field selector
    protected void
    The user changed the properties.
    void
    putSelForChoice(ucar.unidata.data.DataChoice choice, ucar.unidata.data.DataSelection sel)
     
    protected List
    Read the adde text url and return the lines of text.
    static String
    removeKey(String src, String key)
     
    static String
    replaceKey(String sourceUrl, String key, Object value)
     
    static String
    replaceKey(String src, String oldKey, String newKey, Object value)
     
    private <T> void
    replaceKey(String key, T value)
     
    protected List
    saveDataToLocalDisk(String prefix, Object loadId, boolean changeLinks)
    Save files to local disk
    private boolean
    sensorIsABI(int sensorID)
    Return true if the Sensor is ABI variant (ABI, AHI, AMI) These sensors have MESO sectors which move around geospatially
    private boolean
    sensorIsGEO(int sensorID)
    Return true if the Sensor is Geostationary
    void
    setChoiceName(String choiceName)
    _more_
    void
    setDataSelection(ucar.unidata.data.DataSelection s)
    Overridden so that McIDAS-V can associate this data source's current DataChoice with the given DataSelection.
    void
    setDateTimeSelection(List selectedTimes)
    Set the list of selected times for this data source.
    void
     
    void
     
    private void
     
    void
    setPollingInfo(ucar.unidata.util.PollingInfo value)
    Set the PollingInfo property.
    void
    setSaveEleMag(int saveEleMag)
     
    void
    setSaveLat(double saveLat)
     
    void
    setSaveLineMag(int saveLineMag)
     
    void
    setSaveLon(double saveLon)
     
    void
    setSaveNumEle(int saveNumEle)
     
    void
    setSaveNumLine(int saveNumLine)
     
    void
    setSavePlace(String savePlace)
     
    void
    setSaveShowPreview(boolean saveShowPreview)
     
    void
    setShowPreview(boolean showPreview)
     
    void
    setSource(String source)
     
    void
     

    Methods inherited from class ucar.unidata.data.imagery.AddeImageDataSource

    calculateMagFactor, geoSpaceSubsetD, getAddeImageDataSelection, getBaseSource, getDataName, getEleMag, getEMag, getImageBoundingBox, getLatLonPoints, getLineMag, getLMag, getPreviewSource, getUnitString, initOldBundle, makeSamplingLabel, reloadData, reSetImageDataDescriptor, setEleMag, setLineMag

    Methods inherited from class ucar.unidata.data.imagery.ImageDataSource

    canCacheDataToDisk, doMakeDateTimes, doRemove, equals, getAllDateTimes, getBandCategories, getBandTimeSeriesCategories, getCacheDataToDisk, getCompositeDataChoices, getDataPaths, getDescriptorsToUse, getFullDescription, getImageList, getLocationsForPolling, getSelectedDateTimes, getTwoDCategories, getTwoDTimeSeriesCategories, getUniqueDayStrings, hashCode, isFileBased, makeImage, makeImageDataset, makeImageDescriptors, newFileFromPolling, reloadData, setBandInfo, setImageList, setNewFiles, updateState

    Methods inherited from class ucar.unidata.data.DataSourceImpl

    addActions, addDataChangeListener, addPropertiesTabs, addReloadTab, applyFieldMask, applyProperties, beginWritingDataToLocalDisk, canAddCurrentName, canChangeData, canDoAllLevels, canDoFieldMask, canDoGeoSelection, canDoGeoSelectionMap, canDoGeoSelectionStride, canPoll, canShowParameter, checkForInitAfterUnPersistence, clearCachedData, clearFileCache, clearTimes, convertSourceFile, convertToFilesIfDirectory, createAutoDisplay, createCacheKey, createElement, decrOutstandingGetDataCalls, doDirectory, doMakeGeoSelectionPanel, doMakeGeoSelectionPanel, doMakeGeoSelectionPanel, doMakeGeoSubsetPropertiesComponent, endWritingDataToLocalDisk, expandIfNeeded, findDataChoice, findDataChoices, flushCache, getAbsoluteDateTimes, getActions, getAlias, getAllDateTimes, getAllLevels, getAllLevels, getAllTimesForTimeDriver, getCache, getCache, getCacheClearDelay, getData, getData, getDataCachePath, getDataChangeListeners, getDataChoices, getDataContext, getDataInner, getDataIsEditable, getDataSelectionComponents, getDataSource, getDateTimes, getDefaultSave, getDescription, getDescriptor, getErrorMessage, getEverChangedName, getExtraGeoSelectionComponent, getExtraTimesComponent, getFileFilterForPolling, getid, getIdv, getInError, getLocalDirectory, getLocationForPolling, getMostRecentFiles, getName, getNameForDataSource, getNeedToShowErrorToUser, getNextId, getOutstandingGetDataCalls, getPartialDescription, getPassword, getPathsThatCanBeRelative, getProperties, getPropertiesComponents, getPropertiesHeader, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getRelativePaths, getSampleDataProjection, getSaveDataFileLabel, getSelectedDateTimes, getTimesFromDataSelection, getTmpPaths, getTypeName, getUserName, handlePropertiesAction, holdsDateTimes, holdsIndices, identifiedBy, identifiedByName, incrOutstandingGetDataCalls, initAfter, initAfterCreation, initDataChoice, initFromXml, loadFieldMask, loadFieldMask, loadLatestFile, logException, logException, makeDerivedDataChoices, makeSaveLocalActions, newFilesFromPolling, notifyDataChange, putCache, putCache, reloadProperties, removeCache, removeDataChangeListener, removeDataChoice, removeProperty, replaceDataChoice, resetTmpState, saveDataToLocalDisk, saveDataToLocalDisk, selectTimesFromList, setAlias, setAskToUpdate, setCacheClearDelay, setCacheDataToDisk, setDataEditableStrings, setDataIsEditable, setDataIsRelative, setDataRelativeStrings, setDefaultSave, setDescription, setDescriptor, setDirectory, setEverChangedName, setInError, setInError, setInError, setName, setObjectProperties, setObjectProperty, setPassword, setPollLocation, setProperties, setProperty, setProperty, setRelativePaths, setTemplateName, setTmpPaths, setUserName, shouldCache, shouldCache, showPasswordDialog, showPropertiesDialog, showPropertiesDialog, showPropertiesDialog, showWaitDialog, tick, toString, toStringTruncated, updateDetailsText, writeFieldMaskFile, writeFieldMaskFile

    Methods inherited from class ucar.unidata.collab.SharableImpl

    applySharableProperties, doShare, doShare, doShareExternal, doShareInternal, getReceiveShareTime, getSharablePropertiesComponent, getShareGroup, getSharing, getUniqueId, initSharable, receiveShareData, removeSharable, setReceiveShareTime, setShareGroup, setSharing, setUniqueId, showSharableDialog

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface ucar.unidata.data.DataSource

    getUniqueId
  • Field Details

  • Constructor Details

    • AddeImageParameterDataSource

    • AddeImageParameterDataSource

      public AddeImageParameterDataSource(ucar.unidata.data.DataSourceDescriptor descriptor, String image, Hashtable properties) throws VisADException
      Creates a AddeImageParameterDataSource with a single ADDE URL. Note: the URLs should point at "image" data.
      Parameters:
      descriptor - DataSourceDescriptor for this data source.
      image - ADDE URL
      properties - The properties for this data source.
      Throws:
      VisADException
    • AddeImageParameterDataSource

      public AddeImageParameterDataSource(ucar.unidata.data.DataSourceDescriptor descriptor, String[] images, Hashtable properties) throws VisADException
      Create a new AddeImageParameterDataSource with an array of ADDE URL strings. Note: the URLs should point at "image" data.
      Parameters:
      descriptor - DataSourceDescriptor for this data source.
      images - Array of ADDE URLs.
      properties - Properties for this data source.
      Throws:
      VisADException
    • AddeImageParameterDataSource

      public AddeImageParameterDataSource(ucar.unidata.data.DataSourceDescriptor descriptor, List images, Hashtable properties) throws VisADException
      Creates a new AddeImageParameterDataSource with an List of ADDE URL strings. Note: the URLs should point at "image" data.
      Parameters:
      descriptor - DataSourceDescriptor for this data source.
      images - List of ADDE URL strings.
      properties - Properties for this data source.
      Throws:
      VisADException
    • AddeImageParameterDataSource

      public AddeImageParameterDataSource(ucar.unidata.data.DataSourceDescriptor descriptor, ucar.unidata.data.imagery.ImageDataset ids, Hashtable properties) throws VisADException
      Create a new AddeImageParameterDataSource with the given dataset.
      Parameters:
      descriptor - DataSourceDescriptor for this data source.
      ids - Dataset.
      properties - Properties for this data source.
      Throws:
      VisADException
  • Method Details

    • propertiesChanged

      protected void propertiesChanged()
      Description copied from class: ucar.unidata.data.imagery.ImageDataSource
      The user changed the properties. Update me.
      Overrides:
      propertiesChanged in class ucar.unidata.data.imagery.ImageDataSource
    • initDataFromPollingInfo

      protected boolean initDataFromPollingInfo()
      Description copied from class: ucar.unidata.data.imagery.ImageDataSource
      Method for intializing the data.
      Overrides:
      initDataFromPollingInfo in class ucar.unidata.data.imagery.ImageDataSource
      Returns:
      result
    • isPolling

      protected boolean isPolling()
      Description copied from class: ucar.unidata.data.DataSourceImpl
      Are we currently polling.
      Overrides:
      isPolling in class ucar.unidata.data.DataSourceImpl
      Returns:
      Are we polling
    • setPollingInfo

      public void setPollingInfo(ucar.unidata.util.PollingInfo value)
      Description copied from class: ucar.unidata.data.DataSourceImpl
      Set the PollingInfo property.
      Overrides:
      setPollingInfo in class ucar.unidata.data.DataSourceImpl
      Parameters:
      value - The new value for PollingInfo
    • hasPollingInfo

      protected boolean hasPollingInfo()
      Description copied from class: ucar.unidata.data.DataSourceImpl
      Do we have polling info object
      Overrides:
      hasPollingInfo in class ucar.unidata.data.DataSourceImpl
      Returns:
      have polling info object
    • getPollingInfo

      public ucar.unidata.util.PollingInfo getPollingInfo()
      Description copied from class: ucar.unidata.data.DataSourceImpl
      Get the PollingInfo property.
      Overrides:
      getPollingInfo in class ucar.unidata.data.DataSourceImpl
      Returns:
      The PollingInfo
    • initAfterUnpersistence

      public void initAfterUnpersistence()
      Description copied from class: ucar.unidata.data.imagery.AddeImageDataSource
      _more_
      Specified by:
      initAfterUnpersistence in interface ucar.unidata.data.DataSource
      Overrides:
      initAfterUnpersistence in class ucar.unidata.data.imagery.AddeImageDataSource
    • canSaveDataToLocalDisk

      public boolean canSaveDataToLocalDisk()
      Description copied from class: ucar.unidata.data.imagery.ImageDataSource
      Is this data source capable of saving its data to local disk
      Specified by:
      canSaveDataToLocalDisk in interface ucar.unidata.data.DataSource
      Overrides:
      canSaveDataToLocalDisk in class ucar.unidata.data.imagery.ImageDataSource
      Returns:
      Can save to local disk
    • getSelForChoice

      public ucar.unidata.data.DataSelection getSelForChoice(ucar.unidata.data.DataChoice choice)
    • hasSelForChoice

      public boolean hasSelForChoice(ucar.unidata.data.DataChoice choice)
    • putSelForChoice

      public void putSelForChoice(ucar.unidata.data.DataChoice choice, ucar.unidata.data.DataSelection sel)
    • saveDataToLocalDisk

      protected List saveDataToLocalDisk(String prefix, Object loadId, boolean changeLinks) throws Exception
      Save files to local disk
      Overrides:
      saveDataToLocalDisk in class ucar.unidata.data.imagery.AddeImageDataSource
      Parameters:
      prefix - destination dir and file prefix
      loadId - For JobManager
      changeLinks - Change internal file references
      Returns:
      Files copied
      Throws:
      Exception - On badness
    • getDataPrefix

      protected String getDataPrefix()
      Description copied from class: ucar.unidata.data.DataSourceImpl
      Get the file prefix to use for when saving data to local disk
      Overrides:
      getDataPrefix in class ucar.unidata.data.DataSourceImpl
      Returns:
      File prefix to use
    • getDescriptor

      public ucar.unidata.data.imagery.AddeImageDescriptor getDescriptor(Object object)
      A utility method that helps us deal with legacy bundles that used to have String file names as the id of a data choice.
      Overrides:
      getDescriptor in class ucar.unidata.data.imagery.ImageDataSource
      Parameters:
      object - May be an AddeImageDescriptor (for new bundles) or a String that is converted to an image descriptor.
      Returns:
      The image descriptor.
    • getImageDataSourceName

      Overwrite base class method to return the name of this class.
      Overrides:
      getImageDataSourceName in class ucar.unidata.data.imagery.AddeImageDataSource
      Returns:
      The name.
    • setMag

      private void setMag()
    • getAreaDirectory

      private void getAreaDirectory(Hashtable properties)
    • initDataSelectionComponents

      protected void initDataSelectionComponents(List components, ucar.unidata.data.DataChoice dataChoice)
      Description copied from class: ucar.unidata.data.imagery.AddeImageDataSource
      _more_
      Overrides:
      initDataSelectionComponents in class ucar.unidata.data.imagery.AddeImageDataSource
      Parameters:
      components - _more_
      dataChoice - _more_
    • makePreviewImage

      private boolean makePreviewImage(ucar.unidata.data.DataChoice dataChoice)
      A hook to allow this data source to add data selection components to the IDV field selector
      Parameters:
      dataChoice - the data choice
      Returns:
      list of components
    • sensorIsABI

      private boolean sensorIsABI(int sensorID)
      Return true if the Sensor is ABI variant (ABI, AHI, AMI) These sensors have MESO sectors which move around geospatially
      Parameters:
      sensorID - McIDAS Sensor Source number. See https://www.ssec.wisc.edu/mcidas/doc/users_guide/2017.2/app_c-1.html
      Returns:
      true if ID matches a defined ABI sensor
    • sensorIsGEO

      private boolean sensorIsGEO(int sensorID)
      Return true if the Sensor is Geostationary
      Parameters:
      sensorID - McIDAS Sensor Source number. See https://www.ssec.wisc.edu/mcidas/doc/users_guide/2017.2/app_c-1.html
      Returns:
      true if ID matches a defined GEO sensor
    • handlePreviewImageError

      protected void handlePreviewImageError(int flag, Exception excp)
      Show the given error to the user.
      Overrides:
      handlePreviewImageError in class ucar.unidata.data.imagery.AddeImageDataSource
      Parameters:
      flag - _more_
      excp - The exception
    • removeKey

      public static String removeKey(String src, String key)
    • replaceKey

      public static String replaceKey(String sourceUrl, String key, Object value)
    • replaceKey

      public static String replaceKey(String src, String oldKey, String newKey, Object value)
    • replaceKey

      private <T> void replaceKey(String key, T value)
    • getKey

      public static String getKey(String src, String key)
    • doMakeDataChoices

      public void doMakeDataChoices()
      Create the set of DataChoice that represent the data held by this data source. We create one top-level CompositeDataChoice that represents all of the image time steps. We create a set of children DirectDataChoice, one for each time step.
      Overrides:
      doMakeDataChoices in class ucar.unidata.data.imagery.ImageDataSource
    • getDataSelection

      public ucar.unidata.data.DataSelection getDataSelection()
      Overridden so that McIDAS-V can attempt to return the correct DataSelection for the current DataChoice.
      Specified by:
      getDataSelection in interface ucar.unidata.data.DataSource
      Overrides:
      getDataSelection in class ucar.unidata.data.DataSourceImpl
      Returns:
      the DataSelection for this DataSource
    • setDataSelection

      public void setDataSelection(ucar.unidata.data.DataSelection s)
      Overridden so that McIDAS-V can associate this data source's current DataChoice with the given DataSelection.
      Overrides:
      setDataSelection in class ucar.unidata.data.DataSourceImpl
      Parameters:
      s - new selection
    • addDataChoice

      protected void addDataChoice(ucar.unidata.data.DataChoice choice)
      Insert the new DataChoice into the dataChoice list.
      Overrides:
      addDataChoice in class ucar.unidata.data.imagery.AddeImageDataSource
      Parameters:
      choice - new choice to add
    • isFromFile

      public static boolean isFromFile(ucar.unidata.data.imagery.AddeImageDescriptor descriptor)
      Checks to see if a given AddeImageDescriptor is based upon a local (or remote) file.

      The check is pretty simple: is descriptor.getSource() a valid path?

      Parameters:
      descriptor - AddeImageDescriptor of questionable origins. Shouldn't be null.
      Returns:
      true if descriptor's source is a valid path.
    • getDataInner

      protected Data getDataInner(ucar.unidata.data.DataChoice dataChoice, ucar.unidata.data.DataCategory category, ucar.unidata.data.DataSelection dataSelection, Hashtable requestProperties) throws VisADException, RemoteException
      Create the actual data represented by the given DataChoice.
      Overrides:
      getDataInner in class ucar.unidata.data.imagery.AddeImageDataSource
      Parameters:
      dataChoice - Either the CompositeDataChoice representing all time steps or a DirectDataChoice representing a single time step.
      category - Not really used.
      dataSelection - Defines any time subsets.
      requestProperties - extra request properties
      Returns:
      The image or image sequence data.
      Throws:
      RemoteException - Java RMI problem
      VisADException - VisAD problem
    • hasBandInfo

      private boolean hasBandInfo(ucar.unidata.data.DataChoice dataChoice)
      Check if the DataChoice has a BandInfo for its ID
      Parameters:
      dataChoice - choice to check
      Returns:
      true if the choice ID is a BandInfo
    • makeImageSequence

      protected ImageSequence makeImageSequence(ucar.unidata.data.DataChoice dataChoice, ucar.unidata.data.DataSelection subset) throws VisADException, RemoteException
      Create the image sequence defined by the given dataChoice.
      Overrides:
      makeImageSequence in class ucar.unidata.data.imagery.ImageDataSource
      Parameters:
      dataChoice - The choice.
      subset - any time subsets.
      Returns:
      The image sequence.
      Throws:
      RemoteException - Java RMI problem
      VisADException - VisAD problem
    • makeImage

      private SingleBandedImage makeImage(ucar.unidata.data.imagery.AddeImageDescriptor aid, MathType rangeType, boolean fromSequence, String readLabel, ucar.unidata.data.DataSelection subset) throws VisADException, RemoteException
      Create the single image defined by the given AddeImageDescriptor.
      Parameters:
      aid - Holds image directory and location of the desired image.
      rangeType - "rangeType" to use (if non-null).
      fromSequence - _more_
      readLabel -
      subset - geographical subsetting info
      Returns:
      The data.
      Throws:
      RemoteException - Java RMI problem
      VisADException - VisAD problem
    • makeBandParam

      private static String makeBandParam(ucar.unidata.data.imagery.BandInfo bi)
      Make a parameter name for the BandInfo
      Parameters:
      bi - the BandInfo in question
      Returns:
      a name for the parameter
    • makeBandParam

      private static String makeBandParam(ucar.unidata.data.imagery.AddeImageDescriptor descriptor)
    • getDescriptors

      public List getDescriptors(ucar.unidata.data.DataChoice dataChoice, ucar.unidata.data.DataSelection subset)
      Get a list of descriptors from the choice and subset
      Overrides:
      getDescriptors in class ucar.unidata.data.imagery.AddeImageDataSource
      Parameters:
      dataChoice - Data choice
      subset - subsetting info
      Returns:
      list of descriptors matching the selection
    • getChoicesFromSubset

      private List getChoicesFromSubset(ucar.unidata.data.CompositeDataChoice choice, ucar.unidata.data.DataSelection subset)
      Get the subset of the composite based on the selection
      Parameters:
      choice - composite choice
      subset - time selection
      Returns:
      subset list
    • getPreviewDirectories

      private List<AreaDirectory> getPreviewDirectories(ucar.unidata.data.imagery.AddeImageDescriptor imageDescriptor)
    • getPreviewDirectory

      private ucar.unidata.data.imagery.AddeImageDescriptor getPreviewDirectory(ucar.unidata.data.imagery.AddeImageDescriptor aid, ucar.unidata.data.DataChoice dataChoice)
    • getServer

      private String getServer(String urlString)
    • setDisplaySource

      public void setDisplaySource(String src, Hashtable props)
    • getDisplaySource

    • getLineEleResolution

      private float[] getLineEleResolution(AreaDirectory ad)
    • readTextLines

      protected List readTextLines(String url)
      Read the adde text url and return the lines of text. If unsuccessful return null.
      Parameters:
      url - adde url to a text file
      Returns:
      List of lines or null if in error.
    • getUrl

      protected String getUrl()
      Create the first part of the ADDE request URL
      Returns:
      ADDE URL prefix
    • getSourceProps

    • setSourceProps

      public void setSourceProps(Hashtable sourceProps)
    • getChoiceName

      Description copied from class: ucar.unidata.data.imagery.AddeImageDataSource
      _more_
      Overrides:
      getChoiceName in class ucar.unidata.data.imagery.AddeImageDataSource
      Returns:
      _more_
    • setChoiceName

      public void setChoiceName(String choiceName)
      Description copied from class: ucar.unidata.data.imagery.AddeImageDataSource
      _more_
      Overrides:
      setChoiceName in class ucar.unidata.data.imagery.AddeImageDataSource
      Parameters:
      choiceName - _more_
    • getSavePlace

      public String getSavePlace()
    • setSavePlace

      public void setSavePlace(String savePlace)
    • getSaveLat

      public double getSaveLat()
    • setSaveLat

      public void setSaveLat(double saveLat)
    • getSaveLon

      public double getSaveLon()
    • setSaveLon

      public void setSaveLon(double saveLon)
    • getSaveNumLine

      public int getSaveNumLine()
    • setSaveNumLine

      public void setSaveNumLine(int saveNumLine)
    • getSaveNumEle

      public int getSaveNumEle()
    • setSaveNumEle

      public void setSaveNumEle(int saveNumEle)
    • getSaveLineMag

      public int getSaveLineMag()
    • setSaveLineMag

      public void setSaveLineMag(int saveLineMag)
    • getSaveEleMag

      public int getSaveEleMag()
    • setSaveEleMag

      public void setSaveEleMag(int saveEleMag)
    • getSource

      public String getSource()
    • setSource

      public void setSource(String source)
    • getShowPreview

      public boolean getShowPreview()
      Description copied from class: ucar.unidata.data.imagery.AddeImageDataSource
      Whether or not the user decided to show a preview of their image.
      Overrides:
      getShowPreview in class ucar.unidata.data.imagery.AddeImageDataSource
      Returns:
    • setShowPreview

      public void setShowPreview(boolean showPreview)
    • getSaveShowPreview

      public boolean getSaveShowPreview()
    • setSaveShowPreview

      public void setSaveShowPreview(boolean saveShowPreview)
    • getSaveComponents

      private void getSaveComponents()
    • getDateTimeSelection

      Return the list of times held by the DataSelection member.
      Specified by:
      getDateTimeSelection in interface ucar.unidata.data.DataSource
      Overrides:
      getDateTimeSelection in class ucar.unidata.data.DataSourceImpl
      Returns:
      DataSelection times
    • setDateTimeSelection

      public void setDateTimeSelection(List selectedTimes)
      Set the list of selected times for this data source. This is used for XML persistence.
      Specified by:
      setDateTimeSelection in interface ucar.unidata.data.DataSource
      Overrides:
      setDateTimeSelection in class ucar.unidata.data.DataSourceImpl
      Parameters:
      selectedTimes - List of selected times
    • canDoProgressiveResolution

      protected boolean canDoProgressiveResolution()
    • getIsProgressiveResolution

      public boolean getIsProgressiveResolution()
    • setIsProgressiveResolution

      public void setIsProgressiveResolution(boolean isPG)
    • getMatchDisplayRegion

      public boolean getMatchDisplayRegion()