Package ucar.unidata.idv
Class IdvBase
java.lang.Object
ucar.unidata.idv.IdvBase
- All Implemented Interfaces:
IdvConstants
,XmlPersistable
- Direct Known Subclasses:
IntegratedDataViewer
This is the base class for the IntegratedDataViewer.
It holds a set of managers (e.g., IdvUIManager, DataManager)
and has methods to create them and get them. These factory
could be overwritten by derived classes to create their
own kind of manager or editor or so some different
initialization.
- Version:
- $Revision: 1.40 $Date: 2007/06/12 22:52:02 $
- Author:
- IDV development team
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected AliasEditor
The data alias editorprotected String[]
Command line argumentsprotected ArgsManager
The command line argument managerprotected AutoDisplayEditor
The data alias editorprotected IdvChooserManager
The chooser managerprotected CollabManager
Handles collaboration and the event captureprotected ColorTableEditor
The color table editor.protected ColorTableManager
The color table manager.protected DataManager
The data managerprotected DisplayConventions
Handles the different display conventionsprotected IntegratedDataViewer
The idv.protected ImageGenerator
Handles generating images, movies, etc.protected InstallManager
Handles reinstalling the IDVprotected JythonManager
The jython managerprotected ParamDefaultsEditor
The parameter defaults editorprotected ParamGroupsEditor
The parameter defaults editorprotected IdvPersistenceManager
Handles bundle writingprotected PluginManager
The plugin managerprotected IdvPreferenceManager
Handles the end user preferencesprotected IdvProjectionManager
The porojection managerprotected PublishManager
Handles doing publishing of contentprotected IdvResourceManager
The resource managerprotected ResourceViewer
_more_protected StateManager
Handles properties, etc.protected StationModelManager
The station model managerprotected ucar.unidata.idv.test.TestManager
Handles running tests, creating test archives, etc.protected IdvUIManager
Handles creating user interfaces, etc.protected VMManager
The manager of ViewManagersFields inherited from interface ucar.unidata.idv.IdvConstants
ARG_B64BUNDLE, ARG_B64ISL, ARG_BUNDLE, ARG_CATALOG, ARG_CHOOSER, ARG_CLEARDEFAULT, ARG_CODE, ARG_CONNECT, ARG_CURRENTTIME, ARG_DATA, ARG_DEBUG, ARG_DEFAULT, ARG_DISPLAY, ARG_DXML, ARG_FIXEDTIME, ARG_HELP, ARG_IMAGE, ARG_IMAGESERVER, ARG_INSTALLPLUGIN, ARG_ISLFILE, ARG_ISLINTERACTIVE, ARG_LISTRESOURCES, ARG_MAINCLASS, ARG_MOVIE, ARG_MSG_DEBUG, ARG_MSG_RECORD, ARG_NODEFAULT, ARG_NOERRORSINGUI, ARG_NOGUI, ARG_NOONEINSTANCE, ARG_NOPLUGINS, ARG_NOPREF, ARG_ONEINSTANCEPORT, ARG_PLUGIN, ARG_PORT, ARG_PRINTJNLP, ARG_PROPERTIES, ARG_SCRIPT, ARG_SERVER, ARG_SETFILES, ARG_SITEPATH, ARG_TEMPLATE, ARG_TEST, ARG_TESTEVAL, ARG_TRACE, ARG_TRACEONLY, ARG_USERPATH, DEFAULT_DATE_FORMAT, DEFAULT_DOCPATH, DEFAULT_TIMEZONE, FILTER_CPT, FILTER_ISL, FILTER_JNLP, FILTER_XIDV, FILTER_XIDVZIDV, FILTER_XML, FILTER_ZIDV, ID_COMMANDSTORUN, ID_DATASOURCES, ID_DISPLAYCONTROLS, ID_IDV, ID_JYTHON, ID_MESSAGE, ID_MISCHASHTABLE, ID_NCIDV_VERSION, ID_VERSION, ID_VIEWMANAGERS, ID_WINDOWS, INITIAL_PROBE_EARTHLOCATION, NULL_DATA_SELECTION, NULL_STRING, PREF_APPEARANCEMODE, PREF_ARCHIVEDIR, PREF_ARCHIVENAME, PREF_AUTODISPLAYS_ENABLE, PREF_AUTODISPLAYS_SHOWGUI, PREF_AUTOSELECTDATA, PREF_CACHESIZE, PREF_CONTROLSINTABS, PREF_DATAPREFIX, PREF_DATE_FORMAT, PREF_DISTANCEUNIT, PREF_DOCACHE, PREF_EMBEDDATACHOOSERINDASHBOARD, PREF_EMBEDFIELDSELECTORINDASHBOARD, PREF_EMBEDLEGENDINDASHBOARD, PREF_EMBEDQUICKLINKSINDASHBOARD, PREF_EVENT_KEYBOARDMAP, PREF_EVENT_MOUSEMAP, PREF_EVENT_WHEELMAP, PREF_FAST_RENDER, PREF_FIELD_CACHETHRESHOLD, PREF_FILEREADDIR, PREF_FILEWRITEDIR, PREF_GEOMETRY_BY_REF, PREF_HISTORY, PREF_IMAGE_BY_REF, PREF_LARGE_REMOTE_DATA_WARN, PREF_LASTVERSION, PREF_LATLON_FORMAT, PREF_LEGEND_SHOWICONS, PREF_LOCALE, PREF_LOOKANDFEEL, PREF_MAXIMAGESIZE, PREF_MEMORY, PREF_NPOT_IMAGE, PREF_OPEN_ASK, PREF_OPEN_MERGE, PREF_OPEN_REMOVE, PREF_PROJ_LIST, PREF_SAMPLINGMODE, PREF_SHOWCONTROLWINDOW, PREF_SHOWDASHBOARD, PREF_SHOWDECODEDIALOG, PREF_SHOWHIDDENFILES, PREF_SHOWQUITCONFIRM, PREF_SITEPATH, PREF_THREADS_DATA, PREF_THREADS_RENDER, PREF_TIMEZONE, PREF_VERTICALCS, PREF_VERTICALUNIT, PREF_WINDOW_SHOWTOOLBAR, PREF_ZIDV_ASK, PREF_ZIDV_DIRECTORY, PREF_ZIDV_SAVETOTMP, PROP_3DMODE, PROP_ABOUTTEXT, PROP_APPRESOURCEPATH, PROP_CHOOSERS, PROP_CHOOSERS_ALL, PROP_CONTROLDESCRIPTORS, PROP_CONTROLDESCRIPTORS_ALL, PROP_DATAHOLDERBOUNDS, PROP_DEFAULTLOCATIONS, PROP_DISPLAYLIST_GROUP, PROP_FIXFILELOCKUP, PROP_JNLPCODEBASE, PROP_JNLPTEMPLATE, PROP_JNLPTITLE, PROP_LOADINGXML, PROP_MAP_GLOBE_LEVEL, PROP_MAP_MAP_LEVEL, PROP_MINIMUMFRAMECYCLETIME, PROP_MONITORPORT, PROP_OLDCONTROLDESCRIPTORS, PROP_ONEINSTANCEPORT, PROP_PREFERENCES, PROP_PROJ_NAME, PROP_RESOURCEFILES, PROP_SHOWCLOCK_DASH, PROP_SHOWCLOCK_VIEW, PROP_SHOWDASHBOARD, PROP_SHOWDATATREE, PROP_SHOWFORMULAS, PROP_SHOWSPLASH, PROP_SPLASHICON, PROP_UI_DESKTOP, PROP_USE_DISPLAYAREA, PROP_USE_TIMEDRIVER, PROP_VERSIONFILE, PROP_WINDOW_SCREENSIZEOFFSET, PROP_WINDOW_SIZEHEIGHT, PROP_WINDOW_SIZEWIDTH, PROP_WINDOW_USESCREENSIZE, SUFFIX_BAT, SUFFIX_CPT, SUFFIX_ISL, SUFFIX_JNLP, SUFFIX_RBI, SUFFIX_SH, SUFFIX_XIDV, SUFFIX_XML, SUFFIX_ZIDV
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Add a class that was loaded in via the plugin mechanism.createElement
(XmlEncoder encoder) Implement the XmlPersistable createElement method, just return null since we don't really want to be persisted.protected AliasEditor
Factory method to create theAliasEditor
protected ArgsManager
doMakeArgsManager
(String[] args) Factory method to create theArgsManager
protected AutoDisplayEditor
Factory method to create theAutoDisplayEditor
protected CollabManager
Factory method to create theCollabManager
protected ColorTableEditor
Factory method to create theColorTableEditor
protected ColorTableManager
Factory method to create theColorTableManager
protected DataManager
Factory method to create theDataManager
protected DisplayConventions
Factory method to create theDisplayConventions
protected IdvChooserManager
Factory method to create theIdvChooserManager
protected IdvProjectionManager
Factory method to create theProjectionManager
protected IdvUIManager
Factory method to create theIdvUIManager
protected ImageGenerator
Factory method to create theImageGenerator
protected InstallManager
Factory method to create theInstallManager
.protected JythonManager
Factory method to create theJythonManager
protected ParamDefaultsEditor
Factory method to create theParamDefaultsEditor
protected ParamGroupsEditor
Factory method to create theParamGroupsEditor
protected IdvPersistenceManager
Factory method to create theIdvPersistenceManager
protected PluginManager
Factory method to create thePluginManager
protected IdvPreferenceManager
Factory method to create theIdvPreferenceManager
protected PublishManager
Factory method to create thePublishManager
This manages publishing content to weblogs, etc.protected IdvResourceManager
Factory method to create theIdvResourceManager
protected ResourceViewer
_more_protected StateManager
Factory method to create theStateManager
.protected StationModelManager
Factory method to create theStationModelManager
protected ucar.unidata.idv.test.TestManager
Factory method to create theTestManager
.protected VMManager
Factory method to create theVMManager
.Create, if needed, and return theAliasEditor
Create, if needed, and return theArgsManager
Create, if needed, and return theAutoDisplayEditor
Create, if needed, and return theCollabManager
getColorProperty
(String name, Color dflt) Utility method to retrieve a String property from the idv properties.Create, if needed, and return theColorTableEditor
Create, if needed, and return theColorTableManager
Create, if needed, and return theDataManager
.Create, if needed, and return theDisplayConventions
.protected XmlEncoder
getIdv()
Get the IDVCreate, if needed, and return theIdvChooserManager
Create, if needed, and return theProjectionManager
Create, if needed, and return theIdvUIManager
Create, if needed, and return theImageGenerator
Create, if needed, and return theInstallManager
Create, if needed, and return theJythonManager
This simply returns the call to getStore.Create, if needed, and return theParamDefaultsEditor
Create, if needed, and return theParamGroupsEditor
Get the persistence managerCreate, if needed, and return theIdvResourceManager
getPreference
(String pref) Helper method that wraps getStore().get (pref)getPreference
(String pref, Object dflt) Helper method that wraps getStore().get (pref)Create, if needed, and return theIdvPreferenceManager
boolean
getProperty
(String name, boolean dflt) Utility method to retrieve a boolean property from the idv properties.double
getProperty
(String name, double dflt) Utility method to retrieve an int property from the idv properties.int
getProperty
(String name, int dflt) Utility method to retrieve an int property from the idv properties.getProperty
(String name, String dflt) Utility method to retrieve a String property from the idv properties.Create, if needed, and returnPublishManager
Create, if needed, and return theIdvResourceManager
Create, if needed, and return theAliasEditor
Create, if needed, and return theStateManager
Create, if needed, and return theStationModelManager
getStore()
Create the IdvObjectStore (if null) and return it.ucar.unidata.idv.test.TestManager
Create, if needed, and return theTestManager
.Create, if needed, and return theVMManager
.boolean
Do we have a non-null collab managerboolean
initFromXml
(XmlEncoder encoder, Element element) Just needed so we can implement XmlPersistableprotected Object
makeManager
(Class managerClass, Object[] args) Utility to make a manager class.protected void
Set the reference to the idv.void
Show the alias editorvoid
Show the alias editorvoid
Call show on theIdvChooserManager
void
Call show on theIdvChooserManager
void
Show the color table editorvoid
showColorTableEditor
(String colorTableName) Show the color table editor with the color table with the given name (if non-null)void
Show the param defaults editorvoid
Show the alias editorvoid
Show the param defaults editorvoid
Create (if null) and popup the user preference dialog window.void
Show the alias editorvoid
Show the station model editor
-
Field Details
-
idv
The idv. This is really a pointer to this -
args
Command line arguments -
resourceManager
The resource manager -
pluginManager
The plugin manager -
vmManager
The manager of ViewManagers -
publishManager
Handles doing publishing of content -
persistenceManager
Handles bundle writing -
displayConventions
Handles the different display conventions -
argsManager
The command line argument manager -
colorTableEditor
The color table editor. -
colorTableManager
The color table manager. -
stationModelManager
The station model manager -
aliasEditor
The data alias editor -
resourceViewer
_more_ -
projectionManager
The porojection manager -
autoDisplayEditor
The data alias editor -
jythonManager
The jython manager -
paramDefaultsEditor
The parameter defaults editor -
paramGroupsEditor
The parameter defaults editor -
chooserManager
The chooser manager -
dataManager
The data manager -
collabManager
Handles collaboration and the event capture -
preferenceManager
Handles the end user preferences -
testManager
protected ucar.unidata.idv.test.TestManager testManagerHandles running tests, creating test archives, etc. -
uiManager
Handles creating user interfaces, etc. -
imageGenerator
Handles generating images, movies, etc. -
stateManager
Handles properties, etc. -
installManager
Handles reinstalling the IDV
-
-
Constructor Details
-
IdvBase
Create the IdvBase- Parameters:
args
- Command line arguments
-
-
Method Details
-
setIdv
Set the reference to the idv. This is really a reference to this IdvBase object, but the idv is used to pass in to the different managers and editors.- Parameters:
idv
- The IDV
-
getIdv
Get the IDV- Returns:
- The idv
-
addPluginClass
Add a class that was loaded in via the plugin mechanism. We check these classes when we are creating a manager- Parameters:
c
- The class
-
makeManager
Utility to make a manager class. This first sees if there is a sub-class of the given managerClass in th list of plugin classes If there is it will use that class. If args is null this method jsut does a newInstance If args is non-null we'll look for the right constructor- Parameters:
managerClass
- Class to instantiateargs
- Args to pass in. May be null.- Returns:
- Instantiated object
-
doMakeStationModelManager
Factory method to create theStationModelManager
- Returns:
- The station model manager
-
getStationModelManager
Create, if needed, and return theStationModelManager
- Returns:
- The station model manager
-
showStationModelEditor
public void showStationModelEditor()Show the station model editor -
doMakeArgsManager
Factory method to create theArgsManager
- Parameters:
args
- The command lint arguments- Returns:
- The command line argument manager
-
getPersistenceManager
Get the persistence manager- Returns:
- The persistence manager
-
doMakePersistenceManager
Factory method to create theIdvPersistenceManager
- Returns:
- The IdvPersistenceManager
-
getArgsManager
Create, if needed, and return theArgsManager
- Returns:
- The command line argument manager
-
doMakeDataManager
Factory method to create theDataManager
- Returns:
- The data manager
-
getDataManager
Create, if needed, and return theDataManager
. This manages the creation and manipulation of the data sources.- Returns:
- The data manager
-
doMakeDisplayConventions
Factory method to create theDisplayConventions
- Returns:
- The display conventions
-
getDisplayConventions
Create, if needed, and return theDisplayConventions
. This manages the creation and manipulation of the data sources.- Returns:
- The data manager
-
doMakeColorTableManager
Factory method to create theColorTableManager
- Returns:
- The color table manager
-
getColorTableManager
Create, if needed, and return theColorTableManager
- Returns:
- The color table manager
-
doMakeTestManager
protected ucar.unidata.idv.test.TestManager doMakeTestManager()Factory method to create theTestManager
.- Returns:
- The test manager
-
getTestManager
public ucar.unidata.idv.test.TestManager getTestManager()Create, if needed, and return theTestManager
. This class runs the idv in test mode and also creates the test archives.- Returns:
- The test manager
-
doMakeVMManager
Factory method to create theVMManager
. This manages the set ofViewManager
s. It really should be called the ViewManagerManager- Returns:
- The ViewManager manager
-
getVMManager
Create, if needed, and return theVMManager
.- Returns:
- The ViewManager manager
-
doMakePublishManager
Factory method to create thePublishManager
This manages publishing content to weblogs, etc.- Returns:
- The Publish manager
-
getPublishManager
Create, if needed, and returnPublishManager
- Returns:
- The publish manager
-
doMakeIdvUIManager
Factory method to create theIdvUIManager
- Returns:
- The UI manager
-
getIdvUIManager
Create, if needed, and return theIdvUIManager
- Returns:
- The UI manager
-
doMakeImageGenerator
Factory method to create theImageGenerator
- Returns:
- The image generator
-
getImageGenerator
Create, if needed, and return theImageGenerator
- Returns:
- The ImageGenerator
-
doMakeStateManager
Factory method to create theStateManager
.- Returns:
- The state manager
-
getStateManager
Create, if needed, and return theStateManager
- Returns:
- The state manager
-
doMakeInstallManager
Factory method to create theInstallManager
.- Returns:
- The install manager
-
getInstallManager
Create, if needed, and return theInstallManager
- Returns:
- The install manager
-
doMakeJythonManager
Factory method to create theJythonManager
- Returns:
- The jython manager
-
getJythonManager
Create, if needed, and return theJythonManager
- Returns:
- The jython manager
-
doMakeIdvChooserManager
Factory method to create theIdvChooserManager
- Returns:
- The Chooser manager
-
getIdvChooserManager
Create, if needed, and return theIdvChooserManager
- Returns:
- The Chooser manager
-
showChooser
public void showChooser()Call show on theIdvChooserManager
-
showChooserModal
public void showChooserModal()Call show on theIdvChooserManager
-
doMakeCollabManager
Factory method to create theCollabManager
- Returns:
- The collaboration manager
-
getCollabManager
Create, if needed, and return theCollabManager
- Returns:
- The collaboration manager
-
haveCollabManager
public boolean haveCollabManager()Do we have a non-null collab manager- Returns:
- Have a collab manager
-
doMakeAliasEditor
Factory method to create theAliasEditor
- Returns:
- The alias editor
-
getAliasEditor
Create, if needed, and return theAliasEditor
- Returns:
- The alias editor
-
showAliasEditor
public void showAliasEditor()Show the alias editor -
doMakeResourceViewer
_more_- Returns:
- _more_
-
getResourceViewer
Create, if needed, and return theAliasEditor
- Returns:
- The alias editor
-
showResourceViewer
public void showResourceViewer()Show the alias editor -
doMakeIdvProjectionManager
Factory method to create theProjectionManager
- Returns:
- The alias editor
-
getIdvProjectionManager
Create, if needed, and return theProjectionManager
- Returns:
- The projection manager
-
showIdvProjectionManager
public void showIdvProjectionManager()Show the alias editor -
doMakeAutoDisplayEditor
Factory method to create theAutoDisplayEditor
- Returns:
- The auto display editor
-
getAutoDisplayEditor
Create, if needed, and return theAutoDisplayEditor
- Returns:
- The auto display editor
-
showAutoDisplayEditor
public void showAutoDisplayEditor()Show the alias editor -
doMakeParamDefaultsEditor
Factory method to create theParamDefaultsEditor
- Returns:
- The parameter defaults editor
-
getParamDefaultsEditor
Create, if needed, and return theParamDefaultsEditor
- Returns:
- The parameter defaults editor
-
showDefaultsEditor
public void showDefaultsEditor()Show the param defaults editor -
doMakeParamGroupsEditor
Factory method to create theParamGroupsEditor
- Returns:
- The parameter Groups editor
-
getParamGroupsEditor
Create, if needed, and return theParamGroupsEditor
- Returns:
- The parameter Groups editor
-
showParamGroupsEditor
public void showParamGroupsEditor()Show the param defaults editor -
doMakeColorTableEditor
Factory method to create theColorTableEditor
- Returns:
- The color table editor
-
getColorTableEditor
Create, if needed, and return theColorTableEditor
- Returns:
- The color table editor
-
showColorTableEditor
public void showColorTableEditor()Show the color table editor -
showColorTableEditor
Show the color table editor with the color table with the given name (if non-null)- Parameters:
colorTableName
- The name of the color table to show
-
doMakePreferenceManager
Factory method to create theIdvPreferenceManager
- Returns:
- The preference manager
-
getPreferenceManager
Create, if needed, and return theIdvPreferenceManager
- Returns:
- The preference manager
-
showPreferenceManager
public void showPreferenceManager()Create (if null) and popup the user preference dialog window. -
doMakeResourceManager
Factory method to create theIdvResourceManager
- Returns:
- The resource manager
-
getResourceManager
Create, if needed, and return theIdvResourceManager
- Returns:
- The resource manager
-
doMakePluginManager
Factory method to create thePluginManager
- Returns:
- The plugin manager
-
getPluginManager
Create, if needed, and return theIdvResourceManager
- Returns:
- The resource manager
-
getObjectStore
This simply returns the call to getStore. We have this here because getStore returns an IdvObjectStore, not an XmlObjectStore which is called for in the inteface.- Returns:
- The
XmlObjectStore
-
getStore
Create the IdvObjectStore (if null) and return it.- Returns:
- The
XmlObjectStore
-
getProperty
Utility method to retrieve a boolean property from the idv properties. If the property does not exists return the given default value.- Parameters:
name
- The name of the propertydflt
- The default value if the property is not found- Returns:
- The given property or the dflt value
-
getProperty
Utility method to retrieve an int property from the idv properties. If the property does not exists return the given default value.- Parameters:
name
- The name of the propertydflt
- The default value if the property is not found- Returns:
- The given property or the dflt value
-
getProperty
Utility method to retrieve an int property from the idv properties. If the property does not exists return the given default value.- Parameters:
name
- The name of the propertydflt
- The default value if the property is not found- Returns:
- The given property or the dflt value
-
getProperty
Utility method to retrieve a String property from the idv properties. If the property does not exists return the given default value.- Parameters:
name
- The name of the propertydflt
- The default value if the property is not found- Returns:
- The given property or the dflt value
-
getColorProperty
Utility method to retrieve a String property from the idv properties. If the property does not exists return the given default value.- Parameters:
name
- The name of the propertydflt
- The default value if the property is not found- Returns:
- The given property or the dflt value
-
getPreference
Helper method that wraps getStore().get (pref)- Parameters:
pref
- The name of the preference- Returns:
- The value of the preference, or null if not found
-
getPreference
Helper method that wraps getStore().get (pref)- Parameters:
pref
- The name of the preferencedflt
- The default value to return if the preference is not found- Returns:
- The preference value or the dflt
-
createElement
Implement the XmlPersistable createElement method, just return null since we don't really want to be persisted.- Specified by:
createElement
in interfaceXmlPersistable
- Parameters:
encoder
- The encoder doing the encoding- Returns:
- null, because we don't want this object to actually be encoded
-
getEncoder
-
initFromXml
Just needed so we can implement XmlPersistable- Specified by:
initFromXml
in interfaceXmlPersistable
- Parameters:
encoder
- The encoder doing the encodingelement
- The xml element that defines the object- Returns:
- Was this intialization successful
-