edu.wisc.ssec.mcidasv.data.cyclone
Class StormDataSource

java.lang.Object
  extended by ucar.unidata.collab.SharableImpl
      extended by ucar.unidata.data.DataSourceImpl
          extended by edu.wisc.ssec.mcidasv.data.cyclone.StormDataSource
All Implemented Interfaces:
Sharable, DataSource, DataSourceFactory, XmlPersistable
Direct Known Subclasses:
AtcfStormDataSource, Diamond7StormDataSource, STIStormDataSource

public abstract class StormDataSource
extends DataSourceImpl

Created by IntelliJ IDEA. User: yuanho Date: Apr 9, 2008 Time: 4:57:58 PM To change this template use File | Settings | File Templates.


Field Summary
static String ATTR_CATEGORY
          _more_
static int CATEGORY_DB
          _more_
static int CATEGORY_DS
          _more_
static int CATEGORY_ET
          _more_
static int CATEGORY_EX
          _more_
static int CATEGORY_HU
          _more_
static int CATEGORY_IN
          _more_
static int CATEGORY_LO
          _more_
static String[] CATEGORY_NAMES
          _more_
static int CATEGORY_SD
          _more_
static int CATEGORY_SS
          _more_
static int CATEGORY_ST
          _more_
static int CATEGORY_TC
          _more_
static int CATEGORY_TD
          _more_
static int CATEGORY_TS
          _more_
static int CATEGORY_TY
          _more_
static int[] CATEGORY_VALUES
          _more_
static int CATEGORY_WV
          _more_
static int CATEGORY_XX
          _more_
protected  StormParam[] forecastParams
          _more_
protected  StormParam[] obsParams
          _more_
static StormParam PARAM_MAXWINDSPEED_KTS
          _more_
static StormParam PARAM_MINPRESSURE
          _more_
static StormParam PARAM_STORMCATEGORY
          _more_
private  Hashtable seenWays
          _more_
private  Hashtable<String,Way> wayMap
          _more_
private  List<Way> ways
          _more_
 
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_TITLE
 
Constructor Summary
StormDataSource()
          _more_
StormDataSource(DataSourceDescriptor descriptor, String name, String description, Hashtable properties)
          _more_
 
Method Summary
static void addDistanceError(StormTrack obsTrack, StormTrack fctTrack)
          _more_
protected  Way addWay(Way way)
          _more_
 boolean canAddCurrentName(DataChoice dataChoice)
          _more_
static StormTrack difference(StormTrack obsTrack, StormTrack fctTrack, StormParam param)
          _more_
protected  void doMakeDataChoices()
          _more_
 int getCategory(String name)
          _more_
static StormTrackPoint getClosestPoint(List<StormTrackPoint> aList, DateTime dt)
          _more_
static StormTrackPoint[] getClosestPointRange(List<StormTrackPoint> aList, DateTime dt)
          _more_
 Way getDefaultObservationWay()
          _more_
static double getDistance(StormTrackPoint p1, StormTrackPoint p2)
          _more_
abstract  String getId()
          _more_
 boolean getIsObservationWayChangeable()
          _more_
 StormInfo getStormInfo(String stormId)
          _more_
abstract  List<StormInfo> getStormInfos()
          _more_
 StormTrackCollection getTrackCollection(StormInfo stormInfo, Hashtable<String,Boolean> waysToUse, Way obsWay)
          _more_
abstract  StormTrackCollection getTrackCollectionInner(StormInfo stormInfo, Hashtable<String,Boolean> waysToUse, Way observationWay)
          _more_
protected  Way getWay(String w, String name)
          _more_
 String getWayName()
          _more_
 List<Way> getWays()
          _more_
 String getWaysName()
          _more_
static int getYear(DateTime dttm)
          _more_
protected  void initAfter()
          _more_
protected  void initializeStormData()
          _more_
protected  void initParams()
          _more_
 boolean isEditable()
          _more_
protected static RealType makeRealType(String id, String alias, Unit unit)
          _more_
 void reloadData()
          Re-initialize the storm data.
 
Methods inherited from class ucar.unidata.data.DataSourceImpl
addActions, addDataChangeListener, addDataChoice, addPropertiesTabs, addReloadTab, applyFieldMask, applyProperties, beginWritingDataToLocalDisk, canCacheDataToDisk, canChangeData, canDoAllLevels, canDoFieldMask, canDoGeoSelection, canDoGeoSelectionMap, canDoGeoSelectionStride, canPoll, canSaveDataToLocalDisk, canShowParameter, checkForInitAfterUnPersistence, clearCachedData, clearFileCache, clearTimes, convertSourceFile, convertToFilesIfDirectory, createAutoDisplay, createCacheKey, createElement, decrOutstandingGetDataCalls, doDirectory, doMakeDateTimes, doMakeGeoSelectionPanel, doMakeGeoSelectionPanel, doMakeGeoSelectionPanel, doMakeGeoSubsetPropertiesComponent, doRemove, endWritingDataToLocalDisk, equals, expandIfNeeded, findDataChoice, findDataChoices, flushCache, getAbsoluteDateTimes, getActions, getAlias, getAllDateTimes, getAllDateTimes, getAllLevels, getAllLevels, getAllTimesForTimeDriver, getCache, getCache, getCacheClearDelay, getCacheDataToDisk, getCompositeDataChoices, getData, getData, getDataCachePath, getDataChangeListeners, getDataChoices, getDataContext, getDataInner, getDataInner, getDataIsEditable, getDataPaths, getDataPrefix, getDataSelection, getDataSelectionComponents, getDataSource, getDateTimes, getDateTimeSelection, getDefaultSave, getDescription, getDescriptor, getErrorMessage, getEverChangedName, getExtraGeoSelectionComponent, getExtraTimesComponent, getFileFilterForPolling, getFullDescription, getid, getIdv, getInError, getLocalDirectory, getLocationForPolling, getLocationsForPolling, getMostRecentFiles, getName, getNameForDataSource, getNeedToShowErrorToUser, getNextId, getOutstandingGetDataCalls, getPartialDescription, getPassword, getPathsThatCanBeRelative, getPollingInfo, getProperties, getPropertiesComponents, getPropertiesHeader, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getProperty, getRelativePaths, getSampleDataProjection, getSaveDataFileLabel, getSelectedDateTimes, getSelectedDateTimes, getTimesFromDataSelection, getTmpPaths, getTypeName, getUserName, handlePropertiesAction, hasPollingInfo, holdsDateTimes, holdsIndices, identifiedBy, identifiedByName, incrOutstandingGetDataCalls, initAfterCreation, initAfterUnpersistence, initDataChoice, initDataSelectionComponents, initFromXml, isPolling, loadFieldMask, loadFieldMask, loadLatestFile, logException, logException, makeDerivedDataChoices, makeSaveLocalActions, newFileFromPolling, newFilesFromPolling, notifyDataChange, propertiesChanged, putCache, putCache, reloadData, reloadProperties, removeCache, removeDataChangeListener, removeDataChoice, removeProperty, replaceDataChoice, resetTmpState, saveDataToLocalDisk, saveDataToLocalDisk, saveDataToLocalDisk, selectTimesFromList, setAlias, setAskToUpdate, setCacheClearDelay, setCacheDataToDisk, setDataEditableStrings, setDataIsEditable, setDataIsRelative, setDataRelativeStrings, setDataSelection, setDateTimeSelection, setDefaultSave, setDescription, setDescriptor, setDirectory, setEverChangedName, setInError, setInError, setInError, setName, setNewFiles, setObjectProperties, setObjectProperty, setPassword, setPollingInfo, setPollLocation, setProperties, setProperty, setProperty, setRelativePaths, setTemplateName, setTmpPaths, setUserName, shouldCache, shouldCache, showPasswordDialog, showPropertiesDialog, showPropertiesDialog, showPropertiesDialog, showWaitDialog, tick, toString, toStringTruncated, updateDetailsText, updateState, 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, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface ucar.unidata.data.DataSource
getUniqueId
 

Field Detail

CATEGORY_DB

public static final int CATEGORY_DB
_more_

See Also:
Constant Field Values

CATEGORY_TD

public static final int CATEGORY_TD
_more_

See Also:
Constant Field Values

CATEGORY_TS

public static final int CATEGORY_TS
_more_

See Also:
Constant Field Values

CATEGORY_TY

public static final int CATEGORY_TY
_more_

See Also:
Constant Field Values

CATEGORY_ST

public static final int CATEGORY_ST
_more_

See Also:
Constant Field Values

CATEGORY_TC

public static final int CATEGORY_TC
_more_

See Also:
Constant Field Values

CATEGORY_HU

public static final int CATEGORY_HU
_more_

See Also:
Constant Field Values

CATEGORY_SD

public static final int CATEGORY_SD
_more_

See Also:
Constant Field Values

CATEGORY_SS

public static final int CATEGORY_SS
_more_

See Also:
Constant Field Values

CATEGORY_EX

public static final int CATEGORY_EX
_more_

See Also:
Constant Field Values

CATEGORY_IN

public static final int CATEGORY_IN
_more_

See Also:
Constant Field Values

CATEGORY_DS

public static final int CATEGORY_DS
_more_

See Also:
Constant Field Values

CATEGORY_LO

public static final int CATEGORY_LO
_more_

See Also:
Constant Field Values

CATEGORY_WV

public static final int CATEGORY_WV
_more_

See Also:
Constant Field Values

CATEGORY_ET

public static final int CATEGORY_ET
_more_

See Also:
Constant Field Values

CATEGORY_XX

public static final int CATEGORY_XX
_more_

See Also:
Constant Field Values

PARAM_MINPRESSURE

public static StormParam PARAM_MINPRESSURE
_more_


PARAM_MAXWINDSPEED_KTS

public static StormParam PARAM_MAXWINDSPEED_KTS
_more_


CATEGORY_VALUES

public static final int[] CATEGORY_VALUES
_more_


CATEGORY_NAMES

public static final String[] CATEGORY_NAMES
_more_


ATTR_CATEGORY

public static final String ATTR_CATEGORY
_more_

See Also:
Constant Field Values

PARAM_STORMCATEGORY

public static StormParam PARAM_STORMCATEGORY
_more_


obsParams

protected StormParam[] obsParams
_more_


forecastParams

protected StormParam[] forecastParams
_more_


seenWays

private Hashtable seenWays
_more_


ways

private List<Way> ways
_more_


wayMap

private Hashtable<String,Way> wayMap
_more_

Constructor Detail

StormDataSource

public StormDataSource()
                throws Exception
_more_

Throws:
Exception - _more_

StormDataSource

public StormDataSource(DataSourceDescriptor descriptor,
                       String name,
                       String description,
                       Hashtable properties)
_more_

Parameters:
descriptor - _more_
name - _more_
description - _more_
properties - _more_
Method Detail

isEditable

public boolean isEditable()
_more_

Returns:
_more_

canAddCurrentName

public boolean canAddCurrentName(DataChoice dataChoice)
_more_

Specified by:
canAddCurrentName in interface DataSource
Overrides:
canAddCurrentName in class DataSourceImpl
Parameters:
dataChoice - _more_
Returns:
_more_

makeRealType

protected static RealType makeRealType(String id,
                                       String alias,
                                       Unit unit)
_more_

Parameters:
id - _more_
alias - _more_
unit - _more_
Returns:
_more_

initAfter

protected final void initAfter()
_more_

Overrides:
initAfter in class DataSourceImpl

initializeStormData

protected void initializeStormData()
_more_


initParams

protected void initParams()
                   throws VisADException
_more_

Throws:
VisADException - _more_

getCategory

public int getCategory(String name)
_more_

Parameters:
name - _more_
Returns:
_more_

getStormInfos

public abstract List<StormInfo> getStormInfos()
_more_

Returns:
_more_

getId

public abstract String getId()
_more_

Returns:
_more_

doMakeDataChoices

protected void doMakeDataChoices()
_more_

Overrides:
doMakeDataChoices in class DataSourceImpl

reloadData

public void reloadData()
Re-initialize the storm data.

Specified by:
reloadData in interface DataSource
Overrides:
reloadData in class DataSourceImpl

getTrackCollection

public StormTrackCollection getTrackCollection(StormInfo stormInfo,
                                               Hashtable<String,Boolean> waysToUse,
                                               Way obsWay)
                                        throws Exception
_more_

Parameters:
stormInfo - _more_
waysToUse - _more_
obsWay - _more_
Returns:
_more_
Throws:
Exception - _more_

getWayName

public String getWayName()
_more_

Returns:
_more_

getWaysName

public String getWaysName()
_more_

Returns:
_more_

getTrackCollectionInner

public abstract StormTrackCollection getTrackCollectionInner(StormInfo stormInfo,
                                                             Hashtable<String,Boolean> waysToUse,
                                                             Way observationWay)
                                                      throws Exception
_more_

Parameters:
stormInfo - _more_
waysToUse - _more_
observationWay - _more_
Returns:
_more_
Throws:
Exception - _more_

addWay

protected Way addWay(Way way)
_more_

Parameters:
way - _more_
Returns:
_more_

getWay

protected Way getWay(String w,
                     String name)
_more_

Parameters:
w - _more_
name - _more_
Returns:
_more_

getWays

public List<Way> getWays()
_more_

Returns:
_more_

getStormInfo

public StormInfo getStormInfo(String stormId)
_more_

Parameters:
stormId - _more_
Returns:
_more_

getYear

public static int getYear(DateTime dttm)
                   throws VisADException
_more_

Parameters:
dttm - _more_
Returns:
_more_
Throws:
VisADException - _more_

addDistanceError

public static void addDistanceError(StormTrack obsTrack,
                                    StormTrack fctTrack)
                             throws VisADException
_more_

Parameters:
obsTrack - _more_
fctTrack - _more_
Throws:
VisADException - _more_

difference

public static StormTrack difference(StormTrack obsTrack,
                                    StormTrack fctTrack,
                                    StormParam param)
                             throws VisADException,
                                    RemoteException
_more_

Parameters:
obsTrack - _more_
fctTrack - _more_
param - _more_
Returns:
_more_
Throws:
RemoteException - _more_
VisADException - _more_

getClosestPointRange

public static StormTrackPoint[] getClosestPointRange(List<StormTrackPoint> aList,
                                                     DateTime dt)
_more_

Parameters:
aList - _more_
dt - _more_
Returns:
_more_

getClosestPoint

public static StormTrackPoint getClosestPoint(List<StormTrackPoint> aList,
                                              DateTime dt)
_more_

Parameters:
aList - _more_
dt - _more_
Returns:
_more_

getIsObservationWayChangeable

public boolean getIsObservationWayChangeable()
_more_

Returns:
_more_

getDefaultObservationWay

public Way getDefaultObservationWay()
_more_

Returns:
_more_

getDistance

public static double getDistance(StormTrackPoint p1,
                                 StormTrackPoint p2)
_more_

Parameters:
p1 - _more_
p2 - _more_
Returns:
_more_