ucar.unidata.idv.ui
Class ParamGroupsEditor

java.lang.Object
  extended by ucar.unidata.ui.WindowHolder
      extended by ucar.unidata.idv.IdvManager
          extended by ucar.unidata.idv.ui.ParamGroupsEditor
All Implemented Interfaces:
ActionListener, EventListener, IdvConstants

public class ParamGroupsEditor
extends IdvManager
implements ActionListener

An editor for param groups

Version:
$Revision: 1.5 $Date: 2007/06/21 14:45:02 $
Author:
IDV development team

Nested Class Summary
 class ParamGroupsEditor.ParamGroupsTable
          A JTable that holds a list of DataGroup objects and provides display and editing capabilities
 
Field Summary
static String TAG_PARAM
          The param xml tag name
static String TAG_PARAMGROUP
          The params xml tag name
static String TAG_PARAMGROUPS
          The params xml tag name
 
Fields inherited from class ucar.unidata.ui.WindowHolder
contents, dialog, frame, window
 
Fields inherited from interface ucar.unidata.idv.IdvConstants
ARG_B64BUNDLE, 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_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, FILE_VMSTATE, 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_VERSION, ID_VIEWMANAGERS, ID_WINDOWS, INITIAL_PROBE_EARTHLOCATION, NULL_DATA_SELECTION, NULL_STRING, 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_HISTORY, PREF_LASTVERSION, PREF_LATLON_FORMAT, PREF_LOCALE, PREF_LOOKANDFEEL, PREF_MAXIMAGESIZE, 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_TIMEZONE, PREF_VERTICALCS, PREF_VERTICALUNIT, 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_JNLPCODEBASE, PROP_JNLPTEMPLATE, PROP_JNLPTITLE, PROP_LOADINGXML, PROP_OLDCONTROLDESCRIPTORS, PROP_ONEINSTANCEPORT, PROP_PREFERENCES, PROP_PROJ_NAME, PROP_RESOURCEFILES, PROP_SHOWDASHBOARD, PROP_SHOWDATATREE, PROP_SHOWFORMULAS, PROP_SHOWSPLASH, PROP_SPLASHICON, PROP_UI_DESKTOP, 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
ParamGroupsEditor(IntegratedDataViewer idv)
          Create the editor with the given collection of xml resources
 
Method Summary
 void actionPerformed(ActionEvent event)
          Handle the CLOSEANCEL, OK, HELP, events.
 void addNewRow()
          add a new row to users table
protected  void copyToUsers(DataGroup i)
          Copy the given DataGroup object into the user's editable table
 void doImport()
          Import an xml param defaults file
 void doOpen()
          Open an xml param defaults file
 void doSave(List infoList, String filename)
          Save the list of DataGroup-s into the given file
 void doSaveAs()
          Save the param infos
 void doSaveAs(List infoList)
          Prompt for a file and write out the DataGroup-s from the given list.
 void exportSelectedToPlugin()
          Export the selected param infos to the plugin manager
 void exportToPlugin()
          Export allthe param infos to the plugin manager
 ParamGroupsEditor.ParamGroupsTable getCurrentTable()
          Return the ParamGroupsTable which is currently being shown in the tabbed pane
 List getDataGroups(boolean justFirst)
          Get the param infos
protected  String getWindowTitle()
          Get the window title to use
 void showHelp()
          show help
 
Methods inherited from class ucar.unidata.idv.IdvManager
getArgsManager, getCollabManager, getColorTableManager, getDataManager, getIdv, getIdvChooserManager, getIdvClass, getIdvProjectionManager, getIdvUIManager, getImageGenerator, getJythonManager, getPersistenceManager, getPreferenceManager, getProperty, getProperty, getProperty, getPublishManager, getResourceManager, getStateManager, getStationModelManager, getStore, getVMManager, logException, showNormalCursor, showWaitCursor, waitUntilDisplaysAreDone
 
Methods inherited from class ucar.unidata.ui.WindowHolder
close, doMakeContents, getContents, getDialog, getFrame, getWindow, isShowing, removeAll, setWindowTitle, shouldMakeDialog, show, show, showModal, toFront, windowIsClosing
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TAG_PARAM

public static final String TAG_PARAM
The param xml tag name

See Also:
Constant Field Values

TAG_PARAMGROUPS

public static final String TAG_PARAMGROUPS
The params xml tag name

See Also:
Constant Field Values

TAG_PARAMGROUP

public static final String TAG_PARAMGROUP
The params xml tag name

See Also:
Constant Field Values
Constructor Detail

ParamGroupsEditor

public ParamGroupsEditor(IntegratedDataViewer idv)
Create the editor with the given collection of xml resources

Parameters:
idv - The IDV
Method Detail

exportSelectedToPlugin

public void exportSelectedToPlugin()
Export the selected param infos to the plugin manager


exportToPlugin

public void exportToPlugin()
Export allthe param infos to the plugin manager


addNewRow

public void addNewRow()
add a new row to users table


getDataGroups

public List getDataGroups(boolean justFirst)
Get the param infos

Parameters:
justFirst - if true then just get the first table
Returns:
param infos

getCurrentTable

public ParamGroupsEditor.ParamGroupsTable getCurrentTable()
Return the ParamGroupsTable which is currently being shown in the tabbed pane

Returns:
The current ParamGroupsTable

doImport

public void doImport()
Import an xml param defaults file


doOpen

public void doOpen()
Open an xml param defaults file


actionPerformed

public void actionPerformed(ActionEvent event)
Handle the CLOSEANCEL, OK, HELP, events.

Specified by:
actionPerformed in interface ActionListener
Overrides:
actionPerformed in class WindowHolder
Parameters:
event - The event

showHelp

public void showHelp()
show help


getWindowTitle

protected String getWindowTitle()
Get the window title to use

Overrides:
getWindowTitle in class WindowHolder
Returns:
Window title

doSave

public void doSave(List infoList,
                   String filename)
Save the list of DataGroup-s into the given file

Parameters:
infoList - List of infos
filename - The filename to write to

doSaveAs

public void doSaveAs()
Save the param infos


doSaveAs

public void doSaveAs(List infoList)
Prompt for a file and write out the DataGroup-s from the given list.

Parameters:
infoList - List of DataGroup-s

copyToUsers

protected void copyToUsers(DataGroup i)
Copy the given DataGroup object into the user's editable table

Parameters:
i - the param fino object to copy