ucar.unidata.idv.control
Class DisplayControlImpl

java.lang.Object
  extended by ucar.unidata.collab.SharableImpl
      extended by ucar.unidata.idv.control.DisplayControlBase
          extended by ucar.unidata.idv.control.DisplayControlImpl
All Implemented Interfaces:
ActionListener, ItemListener, PropertyChangeListener, EventListener, HyperlinkListener, Sharable, DataChangeListener, DisplayControl, Prototypable, ControlListener, DisplayListener
Direct Known Subclasses:
AerologicalSoundingControl, AnimationTextControl, AudioControl, ChatLogControl, DrawingControl, GridDisplayControl, ImageMovieControl, LocationIndicatorControl, MapDisplayControl, MovieDisplayControl, MultiDisplayHolder, NoteControl, ObsDisplayControl, OmniControl, ProbeControl, ProfilerControl, RadarGridControl, RangeAndBearingControl, ShapefileControl, TextDisplayControl

public abstract class DisplayControlImpl
extends DisplayControlBase
implements DisplayControl, ActionListener, ItemListener, DataChangeListener, HyperlinkListener, DisplayListener, PropertyChangeListener, ControlListener, Prototypable

This is the main base class for all DisplayControls.

Version:
$Revision: 1.726 $
Author:
IDV development team

Nested Class Summary
static class DisplayControlImpl.SideLegendLabel
          Class SideLegendLabel Does the underline
 
Field Summary
protected  List categories
          This is the list of DataCategory-s that were defined for this DisplayControl by the idv/controls.properties and ControlDescriptor code.
protected  ColorScaleInfo colorScaleInfo
          Holds the color scale information
protected  List colorScales
          This is the color scale widget for a display
protected  ContourInfo contourInfo
          Used to hold contour information if this control is enabled for it.
protected  String contourInfoParams
          Used by the isl to override selective parameters in the default contourInfo
protected  ContourWidget contourWidget
          This is the contour info gui widget for controls enabled for contours
protected  ControlContext controlContext
          This is the context in whcih this display control exists (typically an instance of the IntegratedDataViewer but we use the ControlContext interface to keep us honest and not sloppy).
protected  ColorTableWidget ctw
          This is the color table gui widget for controls enabled for color tables
protected  DataSelection dataSelection
          The DataSelection that holds any data subsetting specifications (e.g., time).
protected  String defaultView
          The name of the ViewManager that any displays should be added to
protected  ViewManager defaultViewManager
          This can be used to temporarily set a ViewManager that is to be used.
protected  String DISPLAY_LIST_NAME
          The name for the text type for the display list.
protected  Hashtable displayListTable
          This is the table of the view manager display list displayables
protected  boolean displayListUsesColor
          A boolean to see if the display list got it's color from the display.
protected  List displayMasters
          Holds the DisplayMaster-s that this control wholly owns (e.g., profile display master).
protected  Unit displayUnit
          The Unit (may be null) that is used to display data.
protected  String helpUrl
          The url to show help for this control.
protected  String initNoteText
          This is the initial text note text.
protected  boolean instantiatedWithNoData
          This gets set to track when we have been re-instantiated from a bundle without any data.
protected  JTextArea noteTextArea
          The text area widget used for the control text notes
protected  JComponent noteWrapper
          The Container that holds the noteTextArea.
protected  String paramName
          The name of the parameter (if there is one)
protected  Hashtable requestProperties
          A hashtable that is used to hold extra properties that are passed to the DataChoice through the getData called.
protected  SelectRangeWidget selectRangeWidget
          This is the contour info gui widget for controls enabled for contours
protected  boolean settingVisibility
          A flag to check if this control is in the middle of toggling its visibility checkboxes.
protected  List sharables
          Contains a list of all Sharable objects (e.g., AnimationWidget) that are created by this control.
protected  boolean showNoteText
          Do we show the note text?
protected  JSlider skipSlider
          slider for setting skip values
protected  double version
          version
protected  List viewManagers
          Holds the ViewManager-s that this control has created.
protected static double ZFUDGE
          fudge factor for the Z position
 
Fields inherited from class ucar.unidata.idv.control.DisplayControlBase
CMD_BARBSIZE, CMD_COLORS, CMD_COLORTABLE, CMD_INTERVAL, CMD_LEVEL, CMD_LINEWIDTH, CMD_POPUP, CMD_REMOVE, DEFAULT_POINT_SIZE, DEFAULT_SAMPLING_MODE, FIND_ALL, FIND_CATEGORY, FIND_CLASS, FIND_SPECIAL, FIND_THIS, FIND_WITHDATA, FIND_WITHTHISDATA, FIND_WITHTHISFIELD, FIND_WITHTHISVIEW, FLAG_COLOR, FLAG_COLORTABLE, FLAG_COLORUNIT, FLAG_CONTOUR, FLAG_DATACONTROL, FLAG_DISPLAYUNIT, FLAG_LINEWIDTH, FLAG_NONE, FLAG_SELECTRANGE, FLAG_SKIPFACTOR, FLAG_SMOOTHING, FLAG_TEXTUREQUALITY, FLAG_TIMERANGE, FLAG_ZPOSITION, GRID_INSETS, ICON_LOCK, ICON_REMOVE, ICON_UNLOCK, LABEL_NONE, log_, MACRO_DATASOURCENAME, MACRO_DISPLAYNAME, MACRO_DISPLAYUNIT, MACRO_FHOUR, MACRO_LONGNAME, MACRO_POSITION, MACRO_SHORTNAME, MACRO_STATION, MACRO_TIMESTAMP, MACRO_VALUE, NEAREST_NEIGHBOR, PREF_DISPLAYLIST_TEMPLATE, PREF_EXTRALABEL_TEMPLATE, PREF_LEGENDLABEL_TEMPLATE, PROP_REMOVED, SETTINGS_GROUP_DISPLAY, SETTINGS_GROUP_FLAGS, SHARE_CHOICES, SHARE_COLOR, SHARE_COLORSCALE, SHARE_COLORTABLE, SHARE_DISPLAYUNIT, SHARE_POSITION, SHARE_SELECTRANGE, SHARE_SKIPVALUE, SHARE_TRANSECT, SHARE_VISIBILITY, WEIGHTED_AVERAGE
 
Fields inherited from interface ucar.unidata.idv.DisplayControl
BOTTOM_LEGEND, DEFAULT_PROBEFORMAT, PREF_PREFIX, PREF_PROBEFORMAT, PREF_REMOVEONWINDOWCLOSE, PREF_SAMPLING_MODE, PREF_STANDALONE_REMOVEONCLOSE, PREF_STANDALONE_REMOVEONCLOSE_ASK, PROP_LEGENDICON, RASTERMODE_SHOWALL, RASTERMODE_SHOWNONRASTER, RASTERMODE_SHOWRASTER, SIDE_LEGEND
 
Constructor Summary
DisplayControlImpl()
          Default constructor.
DisplayControlImpl(ControlContext controlContext)
          Create a DisplayControlImple from a ControlContext
 
Method Summary
 void actionPerformed(ActionEvent event)
          Process the actions of any of the controls created with the doMake...Control method calls.
protected  void activateDisplays()
          Activate each DisplayInfo
protected  void addAttributedDisplayable(Displayable d)
          Add the given Displayable to the list of attribute displayables.
protected  void addAttributedDisplayable(Displayable d, int attributeFlags)
          Add the given Displayable to the list of displayables.
protected  void addAttributedDisplayable(Displayable d, int attributeFlags, int notGlobalFlags)
          Add the given Displayable into the list of attributed displayables managed by this DisplayControl.
protected  void addAttributeFlags(int f)
          Add the given attribute flag (e.g., FLAG_COLORTABLE) to the attrbiute flag map.
protected  void addCheckBoxSettings(List comps, Hashtable methodNameToSettingsMap)
          Add checkbox type settings to the Properties panel
 boolean addDataChoice(DataChoice c)
          Add the given DataChoice to the list of data choices and return true if this is a new DataChoice.
 ViewManager addDisplayable(Displayable d)
          Add the given Displayable into a ViewManager
 ViewManager addDisplayable(Displayable theDisplay, int attributeFlag)
          A wrapper around addDisplayable (Displayable theDisplay, ViewDescriptor viewDescriptor), passing in the default LASTACTIVE ViewDescriptor.
 ViewManager addDisplayable(Displayable theDisplay, ViewDescriptor viewDescriptor)
          Find the ViewManager defined by the given ViewDescriptor.
 ViewManager addDisplayable(Displayable theDisplay, ViewDescriptor viewDescriptor, int flag)
          Add the given Displayable into the ViewManager identified by the given ViewDescriptor
 DisplayInfo addDisplayable(Displayable theDisplay, ViewManager viewManager)
          Add the given Displayable into the given ViewManager
 ViewManager addDisplayable(Displayable theDisplay, ViewManager viewManager, int flag)
          Add the given Displayable into the given ViewManager
protected  void addDisplayMaster(DisplayMaster s)
          A sub-class can register any DisplayMaster-s created and managed by them.
protected  void addDisplaySettings(DisplaySettingsDialog dsd)
          Add property values for this DisplaySettingsDialog
protected  void addLabelMacros(String template, List patterns, List values)
          Add any macro name/value pairs.
protected  void addNewData(List newChoices)
          Called when the user chooses new data for this display
protected  void addNoteText(JPanel mainPanel, JComponent noteWrapper)
          Insert the given noteWrapper (which holds the note text TextArea) into the gui
protected  void addPropertiesComponents(JTabbedPane jtp)
          Add tabs to the properties dialog.
 void addPropertyChangeListener(PropertyChangeListener listener)
          Add a property change listener.
 void addRemovable(Removable removable)
          Add something to be removed on doRemove
 void addSharable(SharableImpl s)
          A sub-class can register any SharableImpl-s created and managed by them.
protected  void addTimeModeWidget(List controlWidgets)
          Add in the time mode widget to the list of control widgets
protected  void addToControlContext()
          Add to the control context
 void addToRangeMenu(ColorTableWidget cw, List items)
          Deprecated. use #addToRangeMenu(RangeWidget)
 void addToRangeMenu(RangeDialog selectRangeWidget, List items)
          Deprecated. use #addToRangeMenu(RangeWidget)
 void addToRangeMenu(RangeWidget rw, List items)
          A hook to add an entry into the range menu
protected  void addViewManager(ViewManager s)
          A sub-class can register any ViewManager-s created and managed by them.
 void appendDataChoices(List newDataChoices)
          Append the given list of DataChoice-s to the myDataChoices list
protected  void applyAttributesToDisplayables()
          Used to apply all of the display attributes taht are active to the Displayable-s
protected  void applyColor()
          If the color is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_COLOR
protected  void applyColorScaleInfo()
          If the colorScaleInfo is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_COLORTABLE
protected  void applyColorTable()
          If the color table is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_COLORTABLE
protected  void applyColorUnit()
          If the color unit (gotten from a call to getUnitForColor) is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_COLORUNIT
protected  void applyContourInfo()
          If the contourInfo is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_CONTOUR
 void applyDisplaySetting(DisplaySetting displaySetting)
          Apply a display setting to this control
protected  void applyDisplayUnit()
          If the color unit (gotten from a call to getUnitForColor) is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_DISPLAYUNIT
protected  void applyLineWidth()
          Apply the line width to the displayables with FLAG_LINEWIDTH set
 void applyPreferences()
          Apply preferences to this control.
 boolean applyProperties()
          Apply the properties from the dialog
 void applyProperties(Hashtable properties)
           
 void applyPropertyValues(List props)
          Apply the property values in the list
protected  void applyRange()
          Apply the range it to the Displayables in the displayables list that are flagged with the FLAG_COLORTABLE
protected  void applySelectRange()
          Apply the range it to the Displayables in the displayables list that are flagged with the FLAG_SELECTRANGE
protected  void applySkipFactor()
          Use the value of the skip factor to subset the data.
protected  void applySmoothing()
          Use the value of the smoothing properties to set the value on the display.
protected  void applyTextureQuality()
          Use the value of the texture quality to set the value on the display
 void applyTimeRange()
          Called when we have set the time range.
protected  void applyZPosition()
          Apply the z position to the displayables with FLAG_ZPOSITION set
protected  boolean boundsClose(double a, double b)
          See if two values are close
 boolean canBeDocked()
          Can this be docked
 boolean canExportData()
          Can this display control write out data.
protected  boolean canSaveDataInCache()
          See if this can save data in cache.
 void captureWindow()
          Screen snapshot of window
protected  void centerOnDisplay()
          If this display has a dataprojection then center the view to it
 void changeColorUnit()
          Change the color unit.
 void changeDisplayUnit()
          Change the display unit.
protected  boolean checkFlag(int f)
          Test if the given flag is set in the attrbiuteFlags
protected  boolean checkIfDataOk(DataInstance di)
          Implements the default check if the new DataInstance/DataChoice pair holds valid data.
protected  void checkImageSize(FieldImpl image)
          If image is bigger than threshold then set the skip value
protected  void clearDataInstance()
          Clear the DataInstance
 void clearPrototype()
          Clear the prototype (default) for this display control
protected  void clearViewManagers()
          Runs through the list of ViewManager-s and tells each to destroy.
 void close()
          Close the window.
protected  void colorUnitChanged(Unit oldUnit, Unit newUnit)
          A hook that is called when the color unit is changed.
 void controlChanged(ControlEvent event)
          Noop for the ControlListener interface
 Range convertColorRange(Range rawRange, Unit rawUnit)
          Utility to convert the given raw data range into the display units
 Range convertRange(Range rawRange, Unit rawUnit, Unit outUnit)
          Utility to convert the given raw data range into the display units
protected  DisplayableData createDisplayListDisplayable(ViewManager view)
          Make the DisplayListDisplayable
protected  IdvWindow createIdvWindow()
          Create an IDV window
 void dataChanged()
          Implementation of DataChangeListener.
protected  void deactivateDisplays()
          DeActivate each DisplayInfo
 void debug(String msg)
          Debug
 void displayableToFront()
          Move the displayable to the front
 void displayChanged(DisplayEvent event)
          Noop for the DisplayListener interface
 void displayControlFailed()
          Method to do what needs to be done when the display control failed.
protected  void displayUnitChanged(Unit oldUnit, Unit newUnit)
          A hook that is called when the display unit is changed.
 boolean doApplyProperties()
          Apply the properties
 void doExport(String what, String filename)
          Called by ISL.
protected  void doInitialUpdateLegendAndList()
          Do the initial update legend and list
protected  JComponent doMakeBottomLegendComponent()
          Create and return the gui component which is used to display this DisplayControl in the "legend" area of its ViewManager.
protected  JMenu doMakeChangeColorMenu()
          Utility to make the menu item for changing the color.
protected  JMenu doMakeChangeColorMenu(String name)
          Utility to make the menu item for changing the color.
protected  JMenuItem doMakeChangeParameterMenuItem()
          Utility to make the menu item for changing the data choice
 Component doMakeColorControl()
          A wrapper around doMakeColorControl (Color color), passing in null as the Color argument.
 Component doMakeColorControl(Color color)
          This creates a gui control for selecting a Color.
protected  void doMakeColorScales()
          Actually create the color scales
protected  Container doMakeContents()
          Make Gui contents
protected  DataInstance doMakeDataInstance(DataChoice dataChoice)
          Creates and returns the DataInstance corresponding to a DataChoice.
protected  JMenuBar doMakeMenuBar()
          Make the menu bar
protected  List doMakeMenuBarMenus(List menus)
          Make the menus to put in the menu bar
 JComponent doMakePointSizeWidget()
          Make the point size widget
 JButton doMakeRemoveControl(String tooltip)
          Create the gui control (a JButton) that allows the user to remove this DisplayControl.
protected  JComponent doMakeSideLegendComponent()
          Create and return the gui component which is used to display this DisplayControl in the "legend" area of its ViewManager.
protected  Component doMakeSkipFactorSlider()
          Make the skip factor slider.
protected  JSlider doMakeTextureSlider()
          Make a slider for the texture quality
 JCheckBox doMakeVisibilityControl(String label)
          Get the toggle button JCheckBox that is source for item listener events to toggle visibility of the display.
protected  JComponent doMakeWidgetComponent()
          A helper method for constructing the ui.
protected  void doMakeWindow()
          Called by the derived class init method to create the gui window.
protected  JComponent doMakeZPositionSlider()
          Create the z position slider panel
 void doRemove()
          Remove this DisplayControl.
 void exportDisplayedData(String type)
          Export displayed data to file
protected  DisplayInfo findDisplayInfo(Displayable displayable)
          Find the DisplayInfo for a displayable
protected  List findDisplays(String key)
          Find displays based on the key
protected  List findDisplays(String key, List displays)
          Find displays with the particular key in the list of displays
protected  void firePropertyChangeEvent(PropertyChangeEvent event)
          Fire a property change event.
 void firstFrameDone()
          This gets called by the view manager when it has rcvd its first frame_done event.
protected  String formatForCursorReadout(Real r)
          Format a real for the cursor readout
 boolean getActive()
          Is this control active, i.e., has this control not gotten removed yet
 Animation getAnimation()
          Get the animation
protected  Animation getAnimation(boolean createOurOwn)
          Get the Animation for this display.
protected  Animation getAnimation(boolean createOurOwn, RealType timeType)
          Get the Animation for this display.
protected  Animation getAnimation(RealType timeType)
          Create, if needed, and return the Animation to use
 AnimationInfo getAnimationInfo()
          Get the AnimationInfo property.
 AnimationWidget getAnimationWidget()
          Create, if needed, and return the AnimationWidget
protected  int getAttributeFlags()
          Return the attribute flag map
 Hashtable getCachedData()
          Get the cache of data.
 boolean getCanDoRemoveAll()
          Used by the IDV to determine whether a control should be removed when the user does a remove all.
 List getCategories()
          Returns the list of data categories.
protected  String getChangeParameterLabel()
          A hook to allow derived classes to have their own label in the menu for the change data call.
 boolean getCollapseLegend()
          Get the collapsed legend property.
 Color getColor()
          Get the color for the selector.
 float getColorDimness()
          Get the ColorDimness property.
 ColorScaleInfo getColorScaleInfo()
          Get the contour information for any contours
 ColorTable getColorTable()
          Get the ColorTable property.
 float[][] getColorTableForDisplayable(ColorTable ct)
          The default is to use the alpha color table.
protected  ColorTable getColorTableToApply()
          Get the color table to use when applying to displayables
 ColorTableWidget getColorTableWidget(Range r)
          Get the ColorTableWidget using the specified range.
protected  Unit getColorUnit()
          Return the colorUnit The get and set methods here are protected so the XmlEncoder will not try to encode them.
 String getColorUnitName()
          This is used for xml persistence.
 String getColorWidgetLabel()
          Return the label that is to be used for the color widget This allows derived classes to override this and provide their own name,
 IdvComponentHolder getComponentHolder()
          Get the ComponentHolder property.
protected  Container getContents()
          Get the GUI contents
 ContourInfo getContourInfo()
          Get the contour information for any contours
protected  long getControlChangeSleepTime()
          This returns the time to sleep, in milliseconds, between checks for finally handling control changed events.
 ControlContext getControlContext()
          This is the IntegratedDataViewer
 List getControlMenus(JComponent comp)
          Get the list of menus associated with this control.
 void getControlWidgets(List<ControlWidget> controlWidgets)
          Add into the given the widgets for the different attributes
 List getCursorReadout(EarthLocation el, Real animationValue, int animationStep, List<ReadoutInfo> samples)
          Get the list of items for the cursor readout
protected  List getCursorReadoutInner(EarthLocation el, Real animationValue, int animationStep)
          The getCursorReadout method that really does the work
protected  List getCursorReadoutInner(EarthLocation el, Real animationValue, int animationStep, List<ReadoutInfo> samples)
          Get the list of items, subclasses should override
 Data getData(DataInstance dataInstance)
          A wrapper around dataInstance.getData but this calls updateDataInstance first
 DataChoice getDataChoice()
          Return the single DataChoice
 List getDataChoices()
          Return the list of current DataChoice-s
 Data getDataForDisplayList()
          Get the data for the display list
 DataInstance getDataInstance()
          We have this here (in part) for xml persistence
 DataInstance getDataInstance(boolean forceCreation)
          We have this here (in part) for xml persistence
 MapProjection getDataProjection()
          get MapProjection of data to display
 MapProjection getDataProjectionForMenu()
          Get the MapProjection for this data; if have a single point data object make synthetic map projection for location
protected  String getDataProjectionLabel()
          Get the data projection label
 DataSelection getDataSelection()
          This is used for xml persistence.
protected  List getDataSources()
          Get the DataSources associated with this contol
 DataTimeRange getDataTimeRange()
          Get the DataTimeRange property.
 DataTimeRange getDataTimeRange(boolean createIfNeeded)
          Get the DataTimeRange property.
protected  Set getDataTimeSet()
          Collect the time animation set from the displayables.
protected  void getDebugDetails(StringBuffer sb)
          When we are iun debug mode this method gets called to add details html
protected  ColorScaleInfo getDefaultColorScaleInfo()
          Get the default color scale info
protected  String getDefaultDisplayListTemplate()
          Get the default display list template for this control.
protected  Unit getDefaultDistanceUnit()
          Get the default distance unit
protected  boolean getDefaultFastRendering()
          Get the default for fast rendering
 String getDefaultSamplingMode()
          Get the perferred sampling mode.
 int getDefaultSamplingModeValue()
          Get the integer value of the default sampling mode
 String getDefaultView()
          Return the name of the first ViewManager found in the list of DisplayInfo-s.
 ViewDescriptor getDefaultViewDescriptor()
          Return the ViewDescriptor to use.
 ViewManager getDefaultViewManager()
          Return the name of the first ViewManager found in the list of DisplayInfo-s.
protected  String getDetailsContents()
          Get the contents of the details html
 DisplayRealType getDisplayAltitudeType()
          Utility method to get the altitude type of the display
 String getDisplayCategory()
          This is the category that is defined for this control.
 LatLonPoint getDisplayCenter()
          Get the center of the display
 DisplayConventions getDisplayConventions()
          Get the DisplayConventions to use.
protected  Data getDisplayedData()
          Get the DisplayedData
 String getDisplayId()
          The id of this control (from controls.xml) We have this here for xml persistence
 List getDisplayInfos()
          Return the list of DisplayInfo objects held by this control.
 Color getDisplayListColor()
          Get the DisplayListColor property.
protected  Data getDisplayListData()
          Add the data to the in display legend
 DisplayableData getDisplayListDisplayable(ViewManager view)
          Get the displayable for the Display List
 String getDisplayListTemplate()
          Get the DisplayListTemplate property.
 DisplayMaster getDisplayMaster(Displayable displayable)
          A helper method for finding the DisplayMaster that displays the given Displayable
 String getDisplayName()
          Returns the name of this display.
 float getDisplayScale()
          Get the scaling factor for probes and such.
 Unit getDisplayUnit()
          Return the display unit
protected  Unit getDisplayUnit(Unit rawUnit)
          Returns the default display unit to be used.
 String getDisplayUnitName()
          Get the name of the display unit (if non-null) This is used for xml persistence.
 boolean getDisplayVisibility()
          Get the visibility of the display
 boolean getDoCursorReadout()
          Get the DoCursorReadout property.
 List getEditMenuItems(List items)
          Add the relevant edit menu items into the list
protected  void getEditMenuItems(List items, boolean forMenuBar)
          Add the relevant edit menu items into the list
 boolean getExpandedInTabs()
          Get the ExpandedInTabs property.
 String getExtraLabelTemplate()
          Get the ExtraLabelTemplate property.
protected  JComponent getExtraLegendComponent(int legendType)
          Assume that any display controls that have a color table widget will want the color table to show up in the legend.
protected  void getExtraMenus(List menus, boolean forMenuBar)
          Get any extra menus for this control.
 List getFileMenuItems(List items)
          Add the relevant edit menu items into the list
protected  void getFileMenuItems(List items, boolean forMenuBar)
          Add the relevant file menu items into the list
protected  GraphicsConfiguration getGraphicsConfiguration(boolean is3D, boolean useStereo)
          Get the graphics configuration
 FieldImpl getGrid(GridDataInstance dataInstance)
          A wrapper around dataInstance.getGrid but this calls updateDataInstance first
 FieldImpl getGrid(GridDataInstance dataInstance, boolean copy)
          A wrapper around dataInstance.getGrid but this calls updateDataInstance first
 boolean getHadDataChoices()
          Get the HadDataChoices property.
 boolean getHaveInitialized()
          Has this control been initialized
 List getHelpIds()
          Return the list of (String) java help ids
protected  void getHelpMenuItems(List items, boolean forMenuBar)
          Add the help menu items
 String getId()
          Get the Id property.
 IntegratedDataViewer getIdv()
          Get the integraed data viewer that this is part of
 Image getImage()
          Get the image
 Image getImage(String what)
          Get the image of "what"
 List getInitDataChoices()
          Used to publicize the list of data choices for the persitence mechanism.
protected  ColorTable getInitialColorTable()
          A hook so derived classes can return a colortable.
protected  boolean getInitialFastRendering()
          Get the initial fast rendering property
protected  Range getInitialRange()
          Hook method to allow derived classes to return a different initial Range
protected  double getInitialZPosition()
          Get the initial Z position
protected  Animation getInternalAnimation()
          Create if needed and return an Animation
protected  Animation getInternalAnimation(RealType timeType)
          Create if needed and return an Animation
 boolean getIsRaster()
          Is this a raster display?
 boolean getIsTimeDriver()
          Get the IsTimeDriver property.
 String getLabel()
          Used by the idv classes
protected  void getLastFileMenuItems(List items)
          Get last file menu items.
 JComponent getLegendButtons(int legendType)
          Set the legend buttons
 JComponent getLegendComponent(int legendType)
          Return the gui component used to display this DisplayControl within a ViewManager.
 JComponent getLegendLabel(int legendType)
          This is the main JLabel used in the legend.
protected  void getLegendLabels(List labels, int legendType)
          This method is used to get all of the labels (String) that are shown in the side legend.
 String getLegendLabelTemplate()
          Get the LegendLabel property.
protected  String getLegendToolTip()
          Return the tooltip text that is to be shown in the legend This method constructs html that shows the display name, choices, link to help, etc.
 int getLineWidth()
          Get the line width property.
 ValueSliderWidget getLineWidthWidget()
          Get the LineWidthWidget
 String getLineWidthWidgetLabel()
          Return the label that is to be used for the line width widget This allows derived classes to override this and provide their own name,
 boolean getLockVisibilityToggle()
          Get the locking visibility of the display
protected  String getLongParamName()
          Get the long parameter name
protected  void getMacroNames(List names, List labels)
          Add any macro name/label pairs
 JComponent getMainPanel()
          Get the component for the main panel of this DisplayControlImpl's contents.
 Dimension getMainPanelSize()
          Get the main panel size
 boolean getMakeWindow()
          Should this control make its own window.
 NavigatedDisplay getMapDisplay()
          Just calls getNavigatedDisplay
 MapViewManager getMapViewManager()
          A helper method for finding the MapViewManager this control displays in.
 MapProjection getMapViewProjection()
          Get the projection from the main display.
 String getMenuLabel()
          Return the label used for the menues in the IDV.
 List getMyDataChoices()
          Deprecated. Use getDataChoices
 NavigatedDisplay getNavigatedDisplay()
          A helper method for finding the NavigatedDisplay of this control's MapViewManager.
 String getNoteText()
          This is the value (String) of the note text area.
 XmlObjectStore getObjectStore()
          Return the object store from the getControlContext
 boolean getOkToFireEvents()
          Get whether it's okay to fire events to listeners.
protected  ColorTable getOldColorTableOrInitialColorTable()
          Just a utility for bundles that were created with the old code that saved off the color table name, not the color table.
 String getOriginalDataChoicesLabel()
          Get the name of the data choice, if there is one, when we are saving off without data
 Component getOuterContents()
          The outer contents is the outermost component of the gui (i.e., it holds the menu bar and the mainPanel)
 float getPointSize()
          Get the PointSize property.
 boolean getProperty(String name, boolean dflt)
          Wrapper around ControlContext.getProperty method
 String getProperty(String name, String dflt)
          Wrapper around ControlContext.getProperty method
 String getPropertyDisplayName()
          I forgot why there was this getter (with the "Property") here
 Range getRange()
          Get the range for the parameter
 Range getRangeForColorTable()
          Get the range for the color table.
 Range getRangeToApply()
          Get the range to use to apply to displayables
 Unit getRawDataUnit()
          Get the raw data unit.
protected  Hashtable getRequestProperties()
          Create (if null) and return the Hashtable that holds the extra request properties used in a getData call on the DataChoice
 String getSamplingModeName(int mode)
          Get the name of the sampling mode
 int getSamplingModeValue()
          Get the sampling mode
 int getSamplingModeValue(String samplingMode)
          Get the integer value for the sampling mode supplied
protected  void getSaveMenuItems(List items, boolean forMenuBar)
          Add in the menu items for the save and export display template
 Range getSelectRange()
          Get the range for the data
 boolean getSelectRangeEnabled()
          Get the SelectRangeEnabled property.
 SelectRangeWidget getSelectRangeWidget(Range r)
          Get the SelectRangeWidget using the specified range.
protected  JPanel getSettingsPanel()
          Get the settings panel
protected  String getShortParamName()
          Get the short parameter name
 boolean getShowInDisplayList()
          Get the ShowInDisplayList property.
 boolean getShowInLegend()
          Get the ShowInLegend property.
 boolean getShowInTabs()
          Get the ShowInTabs property.
 boolean getShowNoteText()
          Is this control currently showing the embedded note text area.
 int getSkipValue()
          Get the skip value property
 String getSkipWidgetLabel()
          Return the label that is to be used for the skip widget This allows derived classes to override this and provide their own name,
 int getSmoothingFactor()
          Get the smoothing factor
 String getSmoothingType()
          Get the smoothing type
 Animation getSomeAnimation()
          Get some animation.
 XmlObjectStore getStore()
          Get the object store
 String getTemplateName()
          Get the TemplateName property.
 int getTextureQuality()
          Get the texture quality
 String getTextureQualityLabel()
          Return the label that is to be used for the texture quality widget This allows derived classes to override this and provide their own name,
 Set getTimeSet()
          Get the time set
protected  String getTitle()
          Returns the window title.
 Object getTransientProperty(Object key)
          Find a property on the display control.
protected  Unit getUnitForColor()
          Get the unit used for coloring the displays.
 boolean getUseFastRendering()
          Get the UseFastRendering property.
 boolean getUsesTimeDriver()
          Get the UsesTimeDriver property.
 boolean getUseTimesInAnimation()
          Get the UseTimesInAnimation property.
 double getVersion()
          Get the Version property.
 double getVerticalValue(double value)
          Get the vertical position for a constant map from a value in the range of -1.0 to 1.0.
 Animation getViewAnimation()
          Get the Animation that is from the view manager for this control
 ViewContext getViewContext()
          A hack for now.
 ControlContext getViewer()
          We have this here (in part) for xml persistence This is usually the IntegratedDataViewer
 ViewManager getViewManager()
          Get, from the ControlContext, the ViewManager identified by the ViewDescriptor returned from getDefaultViewDescriptor()
 ViewManager getViewManager(Displayable displayable)
          A helper method for finding the common ViewManager which is displaying the given displayable.
 ViewManager getViewManager(ViewDescriptor viewDescriptor)
          Get, from the ControlContext, the ViewManager identified by the given ViewDescriptor
 String getViewManagerClassNames()
          Get the ViewManagerClasses property.
 ViewManager getViewManagerForCapture(String what)
          Allows a derived class to provide its own viewmanager wehn capturing an image of the display from isl
 List getViewManagers()
          Method to get a list of ViewManagers that are applicable to this DisplayControl.
 List getViewMenuItems(List items)
          Add the relevant view menu items into the list
protected  void getViewMenuItems(List items, boolean forMenuBar)
          Add the relevant view menu items into the list
 int getVisbilityAnimationPause()
          Get the VisbilityAnimationPause property.
protected  boolean getWasUnPersisted()
          See if we were unpersisted
 JFrame getWindow()
          Return the control's JFrame
 Dimension getWindowSize()
          This method is here (mostly) for xml unpersistence
 boolean getWindowVisible()
          Is the window currently visible
 int getWindowX()
          This method is here (mostly) for xml unpersistence
 int getWindowY()
          This method is here (mostly) for xml unpersistence
 double getZPosition()
          Get the ZPosition property.
protected  String getZPositionSliderLabel()
          Get the label for the Z position slider.
 void guiExported()
          This is called to inform this display control that its gui has been exported out of some other component (ex: the MultiDisplayControl).
 void guiImported()
          This is called to inform this display control that its gui has been imported by some other idv component and it no longer is in a window.
 void handleDisplayChanged(DisplayEvent event)
          Allow sub-classes to get displayevents
protected  void handleWindowClosing()
          Handle the window closing.
 boolean hasMapProjection()
          Does this display have a map projection
protected  boolean hasTimeMacro(String t)
          Does this have a time macro string?
protected  boolean haveDataTimes()
          Do any of our displayables have times
protected  boolean haveParameterDefaults()
          Check to see if we have any display properties.
 void hide()
          Hide the window
 void hyperlinkUpdate(HyperlinkEvent e)
          Implement the HyperLinkListener method to pass any link clicks off to the ControlContext
 boolean inGlobeDisplay()
          Are we in a Globe display?
 boolean init(DataChoice choice)
          Initialize this instance according to a data choice.
 boolean init(List choices)
          Initialize this instance according to the first DataChoice in a List.
 void init(String displayId, List categories, List choices, ControlContext controlContext, Hashtable properties, DataSelection dataSelection)
          This init method is the one actually called by the IDV.
 void init(String displayId, List categories, List choices, ControlContext controlContext, String properties, DataSelection dataSelection)
          Deprecated. use init that takes a properties Hashtable
 void initAfterUnPersistence(ControlContext vc, Hashtable properties)
          Called by the IntegratedDataViewer to initialize after this control has been unpersisted
 void initAfterUnPersistence(ControlContext vc, Hashtable properties, List preSelectedDataChoices)
          Called by the IntegratedDataViewer to initialize after this control has been unpersisted
 void initAsPrototype()
          Initialize as a prototype
 void initAsTemplate()
          Initialize as a template
 void initBasic(String displayId, List categories, Hashtable properties)
          This init method is used to just initialize some basic properties of this display control.
 void initDone()
          Called after all initialization has been done.
protected  void initializeWithNewData()
          This is called when this display is created from a template and does not have any data.
 void initWindow(IdvWindow window)
          A hook method to allow subclasses to initialize the dialog window, set the size of the dialog window, etc.
 boolean isDisplay3D()
          Utility method to determine if we are displaying in a 3d viewmanager
protected  boolean isDisplayUnitAlsoColorUnit()
          Allows for derived classes to define that the display unit is different then the color unit.
protected  boolean isGuiShown()
          Is the GUI being shown
 boolean isInitDone()
          Check if initialization is done
 boolean isInTransectView()
          Are we displayed in a transect view manager
 boolean isInViewManager()
          Does this control have displays in a view manager
 void itemStateChanged(ItemEvent event)
          A no-op method to implement the ItemListener interface.
protected  List makeChangeColorMenuItems()
          Add the list of menu items for changing the color to the component (usually a menu or popup menu)
 JLabel makeLegendLabel()
          make the legend label
protected  JButton makeLockButton()
          Create a lock button for the given display control.
protected  JButton makeRemoveButton()
          Create an icon button for removing the given display control.
 void moveTo(ViewManager newViewManager)
          An implementation of the DisplayControl interface moveTo method.
protected  void notifyViewManagersOfChange()
          notify views of change
protected  void parseProperties(String properties)
          The given properties String is a ";" delimited list of name=value properties.
 void popup(Component src)
          Show the dialog window for this control.
protected  void popupDataDialog(String dialogMessage, Component from)
          Create and show the data choosing dialog
protected  void popupDataDialog(String dialogMessage, Component from, boolean multiples)
          Popup a DataTreeDialog
protected  void popupDataDialog(String dialogMessage, Component from, boolean multiples, List categories)
          Popup a DataTreeDialog
protected  void processRequestProperties()
          Process request properties from a DataChoice
 void projectionChanged()
          Method to call if projection changes.
 void propertyChange(PropertyChangeEvent evt)
          Handle animation change events
 void putTransientProperty(Object key, Object value)
          Put a property on the display control.
protected  void reallySetAttributeFlags(int f)
          Set the attribute flag map to the given value.
 void receiveShareData(Sharable from, Object dataId, Object[] data)
          Method called by other classes that share the the state.
protected  void redoGuiLayout()
          Used to relayout the gui mainPanel
 void reloadDataSource()
          Reload the data sources
 void reloadDataSourceInThread()
          reload the data source in a thread.
 void removeDataChoice(DataChoice dataChoice)
          Remove the given DataChoice from the myDataChoices list.
 void removeDisplayable(Displayable displayable)
          Remove a Displayable
protected  void removeDisplayables()
          Iterates across the list of DisplayInfo-s, telling them to removeDisplayable.
protected  void removeDisplayables(boolean andDestroyThem)
          Iterates across the list of DisplayInfo-s, telling them to removeDisplayable.
protected  boolean removeOnWindowClose()
          Should the DisplayControl do a doRemove when the window closes.
 void removePropertyChangeListener(PropertyChangeListener listener)
          Remove property change listener.
protected  void resetData()
          This gets called when the control has received notification of a dataChange event.
 void resetDimness()
          Set the color table dimness to the default
 void resetViewManager(String oldViewId, String newViewId)
          Reset the view manager
protected  void revertToDefaultColorTable()
          Reset the color table to the initial color table
protected  void revertToDefaultColorTable(String whichColorTable)
          Revert to the default
protected  void revertToDefaultRange()
          Reset the range to the initial range
protected  void revertToDefaultRange(String whichColorTable)
          Revert to the default
 void saveAsFavorite()
          Save this display control as a favorite display template.
 void saveAsParameterDefaults()
          Save the state as parameter defaults
 void saveAsPrototype()
          Save this display as a prototype (default)
 void saveAsTemplate()
          Save this display control as a display template.
 void saveDataChoiceInCache()
          Save the data choice into the cache data source
 void saveImage(String filename)
          Find the first ViewManager in the list of DisplayInfo-s and have the ViewManager write its image to to given filename.
protected  List<DataChoice> selectDataChoices(String dialogMessage, Component from, boolean multiples, List categories)
          Popup a DataTreeDialog
 void setAnimationInfo(AnimationInfo value)
          Set the AnimationInfo property.
protected  void setAnimationSet(List dateTimes)
          A utility method to set the animation set from the given list of times of the animation
protected  void setAttributeFlags(int f)
          Set the attribute flag map to the given value.
 void setCachedData(Hashtable cache)
          Set the data cache.
 void setCanDoRemoveAll(boolean v)
          Used by the IDV to determine whether a control should be removed when the user does a remove all.
 void setCategories(List c)
          A set method so the categories list will get persisted.
 void setCollapseLegend(boolean value)
          Set the collapsed legend property.
 void setColor(Color c)
          Set the color for the selector.
 void setColorBrighter()
          Set the color brighter
 void setColorDimmer()
          Set the color dimmer
 void setColorDimness(float value)
          Set the ColorDimness property.
 void setColorScaleInfo(ColorScaleInfo newInfo)
          Set the color scale parameters for any color scale
 void setColorScaleVisible(boolean viz)
          Set the visibility of the color scale.
 void setColorTable(ColorTable newColorTable)
          Set the ColorTable property.
 void setColorTable(String whichColorTable, ColorTable newColorTable)
          Set the color table from the colortablewidget
 void setColorTableName(String n)
          This method is for legacy bundles that used to save off the color table name instead of the color table.
protected  void setColorUnit(Unit unit)
          Set the colorUnit
 void setColorUnitName(String name)
          This is used for xml persistence.
 void setComponentHolder(IdvComponentHolder value)
          Set the ComponentHolder property.
protected  void setContents(Container c)
          Set the gui contents
 void setContourInfo(ContourInfo newInfo)
          Set the contour parameters for any contours
 void setContourInfoParams(String s)
          Used by the isl to override selective parameters in the default contourInfo
protected  boolean setData(DataChoice dataChoice)
          Sets the data associated with this instance.
protected  boolean setData(List newChoices)
          Gets called when the user has selected a new DataChoice.
 void setDataChoices(List newList)
          Set the list of data choices to be the given list
protected  void setDataInstance(DataInstance dataInstance)
          Set the data instance.
 void setDataInstances(List l)
          Sets the list of DataInstances for this DisplayControl.
 void setDataSelection(DataSelection newDataSelection)
          This is used for xml persistence.
 void setDataTimeRange(DataTimeRange value)
          Set the DataTimeRange property.
 void setDefaultSamplingMode(String newMode)
          Set sampling mode.
 void setDefaultView(String s)
          Set the name of the default view manager that displays are put into.
protected  void setDisplayableVisibility(Displayable d, boolean visible)
          Set the ultimate visibility of the particular Displayable.
protected  void setDisplayableVisiblity(Displayable d, boolean visible)
          Deprecated.  
 void setDisplayActive()
          If wasActive is true then set the display master to be active.
 void setDisplayCategory(String value)
          This is the category that is defined for this control.
 void setDisplayId(String theId)
          Set the id of this control (from controls.xml) We have this here for xml persistence
 void setDisplayInactive()
          Set the display master to be inactive.
 void setDisplayListColor(Color newColor)
          Set the display list color property.
protected  void setDisplayListColor(Color newColor, boolean fromUser)
          Set the display list color property.
protected  void setDisplayListProperties(DisplayableData d, ViewManager view)
          Set the display list properties on the displayable
 void setDisplayListTemplate(String value)
          Set the DisplayListTemplate property.
 void setDisplayName(String displayName)
          What is the name of this control (e.g., "Plan view")
protected  void setDisplayUnit(Unit newUnit)
          Set the display unit.
 void setDisplayUnitName(String name)
          Set the name of the display unit.
 void setDisplayVisibility(boolean on)
          Set the visibility of the display and set the state of any visibility buttons we may have.
 void setDoCursorReadout(boolean value)
          Set the DoCursorReadout property.
 void setExpandedInTabs(boolean value)
          Set the ExpandedInTabs property.
 void setExtraLabelTemplate(String value)
          Set the ExtraLabelTemplate property.
 void setHadDataChoices(boolean value)
          Set the HadDataChoices property.
 void setHelpUrl(String helpUrl)
          Set the help URL for this DisplayControl
 void setId(String value)
          Set the Name property.
 void setInitDataChoices(List l)
          Used to publicize the list of data choices for the persistence mechanism
 void setInitialSettings(List settings)
          Set the initial settings
 void setInitialViewManager(ViewManager viewManager)
          Set the view manager for this control to use.
 void setIsRaster(boolean v)
          Set IsRaster property
 void setIsTimeDriver(boolean value)
          Set the IsTimeDriver property.
 void setLabelAsPreference(Object[] obj)
          Set the label as a preference
 void setLegendBackground(Color bg)
          Set the color to be used for the background in the bottom legend
 void setLegendForeground(Color fg)
          Set the color to be used for the foreground in the bottom legend
 void setLegendLabel(String label)
          A no-op so unpersisting old bundles won't flag a warning.
 void setLegendLabelTemplate(String value)
          Set the LegendLabel property.
 void setLineWidth(int value)
          Set the line width property.
 void setLockVisibilityToggle(boolean v)
          Set the locking visibility of the display
protected  void setMainPanelDimensions()
          Set the main panel dimenstions
 void setMainPanelSize(Dimension s)
          Set the main panel size
 void setMakeWindow(boolean value)
          Should this control make its own window.
 void setName(String value)
          Set the Name property.
 void setNameFromUser(String value)
          Set the NameFromUser property.
protected  boolean setNewColorUnit(Unit newUnit, boolean applyToDisplayable)
          The user has chosen a new unit for color.
protected  boolean setNewDisplayUnit(Unit newUnit, boolean applyToDisplayable)
          The user has chosen a new unit for display.
 void setNoteText(String n)
          Set the value of the note text area.
 void setOkToFireEvents(boolean v)
          Set whether it's okay to fire events to listeners.
 void setOriginalDataChoicesLabel(String s)
          Set the name of the data choice
 void setParamName(String paramName)
          The name of the parameter (initially from the DataChoice) displayed by this control.
 void setPersistedVisadData(List l)
          Deprecated.  
 void setPointSize(float value)
          Set the PointSize property.
protected  void setProjectionInView(boolean useViewPreference)
          Set the projection in the map view manager.
protected  void setProjectionInView(boolean useViewPreference, boolean maintainViewpoint)
          Set the projection in the map view manager.
protected  void setProperty(String name, Object value)
          Wrapper around Misc.propertySet
 void setRange(Range newRange)
          Set the range for the color table.
 void setRange(String whichColortable, Range newRange)
          Set the range (from the colortablewidget)
 void setSelectRange(Range newRange)
          Set the range for the select data.
 void setSelectRangeEnabled(boolean value)
          Set the SelectRangeEnabled property.
 void setSettingsDisplayUnit(Unit newUnit)
          Set the display unit from the settings
 void setSharedColorScaleInfo(ColorScaleInfo newInfo)
          Set the shared color scale info
 void setShowInDisplayList(boolean value)
          Set the ShowInDisplayList property.
 void setShowInLegend(boolean value)
          Set the ShowInLegend property.
 void setShowInTabs(boolean value)
          Set the ShowInTabs property.
 void setShowNoteText(boolean n)
          Used by the presistence/unpersistence to record whether this control is showing its note text area
 void setSkipValue(int value)
          Set the skip value property
 void setSmoothingFactor(int val)
          Set the smoothing factor
 void setSmoothingType(String type)
          Set the smoothing type
 void setTemplateName(String value)
          Set the TemplateName property.
 void setTextureQuality(int quality)
          Set the texture quality
 void setTitle(String title)
          Set the title of the window if it has been created.
protected  void setUnitForColor(Unit newUnit)
          Set the unit to use for color.
 void setUseFastRendering(boolean value)
          Set the UseFastRendering property.
 void setUsesTimeDriver(boolean value)
          Set the UsesTimeDriver property.
 void setUseTimesInAnimation(boolean value)
          Set the UseTimesInAnimation property.
 void setVersion(double value)
          Set the Version property.
 void setViewer(ControlContext controlContext)
          We have this here (in part) for xml persistence This is usually the IntegratedDataViewer
 void setViewManagerClassNames(String value)
          Set the ViewManagerClasses property.
 void setVisbilityAnimationPause(int value)
          Set the VisbilityAnimationPause property.
 void setWindowSize(Dimension value)
          This method is here (mostly) for xml unpersistence
 void setWindowVisible(boolean v)
          Set the local data memeber myWindowVisible.
 void setWindowX(int x)
          This method is here (mostly) for xml unpersistence
 void setWindowY(int y)
          This method is here (mostly) for xml unpersistence
 void setZPosition(double value)
          Set the ZPosition property.
 void setZPosition(double value, boolean fromSlider)
          Set the Z position
protected  boolean shouldAddAnimationListener()
          A hook to allow derived classes to tell us to add this as an animation listener
protected  boolean shouldAddControlListener()
          A hook to allow derived classes to tell us to add this as a control listener
protected  boolean shouldAddDisplayListener()
          A hook to allow derived classes to tell us to add this as a display listener
protected  boolean shouldApplyFastRendering()
          This method can be overwritten by the derived classes that do not want the general application of the fast rendering flag.
 boolean shouldBeDocked()
          Should this be docked
 boolean shouldWindowBeVisible()
          Does this display control popup its window on creation
 void show()
          SHow the window
 boolean showColorControlWidget()
          Show the color control widget in the widgets if FLAG_COLOR is set.
 void showColorDialog()
          Show the color dialog
 void showColorDialog(String methodName)
          Show the color dialog and invoke the named method
 void showColorScaleDialog()
          Popup the color scale properties dialog
protected  boolean showColorScales(boolean show)
          Method to show all ColorScales associated with this DisplayControl.
protected  void showColorSwatches(boolean on)
          Change the visiblity of all color swatches
 void showContourPropertiesDialog()
          Popup the contour properties dialog
 void showDetails()
          Popup the details window
 void showDisplaySettingsDialog()
          Show the DisplaySettingsDialog
 void showHelp()
          This method will attempt to show the relevant javahelp for this display.
protected  void showLegendMenu(JComponent comp, MouseEvent event)
          Create and show the popup menu for the user's right click on the legend.
 void showNormalCursor()
          A helper method to show the normal cursor
 void showProperties()
          Show the properties dialog
 void showTimeRangeDialog()
          Popup the time range dialog
 void showWaitCursor()
          A helper method to show the wait cursor
protected  void timeChanged(Real time)
          Respond to a timeChange event
 void toFront()
          Move the control's window to the front.
 void toggleNoteTextArea()
          Toggle the visibility of the noteTextArea.
 void toggleVisibilityForVectorGraphicsRendering(int rasterMode)
          Toggle the visibility for vector graphics rendering
 void toggleWindow()
          Hide or show the main window
 String toString()
          The toString method.
 void transectChanged()
          Method called when a transect changes.
protected  void updateAnimation()
          Update the animation for the view manager
protected  DataInstance updateDataInstance(DataInstance dataInstance)
          update the datainstance in preparation for a getData call.
protected  DataSelection updateDataSelection(DataSelection dataSelection)
          update the dataselection in preparation for a getData call.
protected  void updateDisplayList()
          Update the display list data
protected  GridDataInstance updateGridDataInstance(GridDataInstance dataInstance)
          update the datainstance in preparation for a getData call
protected  void updateLegendAndList()
          Update the legend labels and the display list
protected  void updateLegendLabel()
          This method is called to update the legend labels when some state has changed in this control that is reflected in the labels.
protected  void updateLockButton(JButton lockBtn)
          Change the icon in the lock button for the given display control.
 boolean useSmoothingFactor()
          Should we use the smoothing factor?
protected  boolean useZPosition()
          See if the display supports Z positioning.
 void viewManagerChanged(String property)
          Method called when a transect changes.
 void viewManagerDestroyed(ViewManager viewManager)
          Called when a ViewManager which holds the display is destoryed
 void viewpointChanged()
          This gets called when we have received a controlChanged event and have not received another one in some time delta
 void writeTestArchive(String archiveName)
          Write out all screen images
 void xxxsetDisplayActive(boolean active)
          Set the display master to be active/inactive.
 void zSliderChanged(double value)
          The z slider postion changed
 
Methods inherited from class ucar.unidata.idv.control.DisplayControlBase
boxToEarth, boxToEarth, boxToEarth, boxToEarth, boxToEarth, boxToScreen, calculateRectangle, createStationTfo, earthToBox, earthToBox, earthToBoxTuple, earthToScreen, formatLevels, getLabeledReal, getLevelReal, getScreenCenter, getSelectedStation, getTmpProperty, isLeftButtonDown, logException, logException, makeEarthLocation, putTmpProperty, removeTmpProperty, screenToBox, screenToBox, screenToEarth, setStations, setStations, toBox, toEarth, userErrorMessage, userMessage
 
Methods inherited from class ucar.unidata.collab.SharableImpl
applySharableProperties, doShare, doShare, doShareExternal, doShareInternal, getReceiveShareTime, getSharablePropertiesComponent, getShareGroup, getSharing, getUniqueId, initSharable, removeSharable, setReceiveShareTime, setShareGroup, setSharing, setUniqueId, showSharableDialog
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface ucar.unidata.idv.DisplayControl
getTmpProperty, putTmpProperty, removeTmpProperty
 
Methods inherited from interface ucar.unidata.collab.Sharable
getReceiveShareTime, getShareGroup, getSharing, getUniqueId, setReceiveShareTime
 

Field Detail

version

protected double version
version


ZFUDGE

protected static final double ZFUDGE
fudge factor for the Z position

See Also:
Constant Field Values

settingVisibility

protected boolean settingVisibility
A flag to check if this control is in the middle of toggling its visibility checkboxes. Used to keep us from having an infinite event loop. Infinity is a pretty cool concept but it doesn't work well in practice.


DISPLAY_LIST_NAME

protected final String DISPLAY_LIST_NAME
The name for the text type for the display list.

See Also:
Constant Field Values

displayUnit

protected Unit displayUnit
The Unit (may be null) that is used to display data. We keep it at this level because this class handles the widget that is used to change the unit, etc.


initNoteText

protected String initNoteText
This is the initial text note text. We have this here so when this control is instantiated via persistence this value gets set. We then use it when we create the note TextArea


noteTextArea

protected JTextArea noteTextArea
The text area widget used for the control text notes


noteWrapper

protected JComponent noteWrapper
The Container that holds the noteTextArea. We keep this around so we can add/remove the TextArea


showNoteText

protected boolean showNoteText
Do we show the note text?


dataSelection

protected DataSelection dataSelection
The DataSelection that holds any data subsetting specifications (e.g., time). This is typically created by the IDV and passed into this DisplayControl.


requestProperties

protected Hashtable requestProperties
A hashtable that is used to hold extra properties that are passed to the DataChoice through the getData called.


sharables

protected List sharables
Contains a list of all Sharable objects (e.g., AnimationWidget) that are created by this control. We keep this around so when the display is removed we can tell each Sharable to remove itself.


displayMasters

protected List displayMasters
Holds the DisplayMaster-s that this control wholly owns (e.g., profile display master).


defaultViewManager

protected ViewManager defaultViewManager
This can be used to temporarily set a ViewManager that is to be used. TBD.


viewManagers

protected List viewManagers
Holds the ViewManager-s that this control has created.


defaultView

protected String defaultView
The name of the ViewManager that any displays should be added to


contourInfo

protected ContourInfo contourInfo
Used to hold contour information if this control is enabled for it.


contourInfoParams

protected String contourInfoParams
Used by the isl to override selective parameters in the default contourInfo


displayListUsesColor

protected boolean displayListUsesColor
A boolean to see if the display list got it's color from the display.


ctw

protected ColorTableWidget ctw
This is the color table gui widget for controls enabled for color tables


colorScales

protected List colorScales
This is the color scale widget for a display


displayListTable

protected Hashtable displayListTable
This is the table of the view manager display list displayables


contourWidget

protected ContourWidget contourWidget
This is the contour info gui widget for controls enabled for contours


selectRangeWidget

protected SelectRangeWidget selectRangeWidget
This is the contour info gui widget for controls enabled for contours


helpUrl

protected String helpUrl
The url to show help for this control. Typically set through controls.xml


paramName

protected String paramName
The name of the parameter (if there is one)


instantiatedWithNoData

protected boolean instantiatedWithNoData
This gets set to track when we have been re-instantiated from a bundle without any data.


categories

protected List categories
This is the list of DataCategory-s that were defined for this DisplayControl by the idv/controls.properties and ControlDescriptor code.


colorScaleInfo

protected ColorScaleInfo colorScaleInfo
Holds the color scale information


controlContext

protected ControlContext controlContext
This is the context in whcih this display control exists (typically an instance of the IntegratedDataViewer but we use the ControlContext interface to keep us honest and not sloppy).


skipSlider

protected JSlider skipSlider
slider for setting skip values

Constructor Detail

DisplayControlImpl

public DisplayControlImpl()
Default constructor. This is called when the control is unpersisted through the XmlEncoder mechanism.


DisplayControlImpl

public DisplayControlImpl(ControlContext controlContext)
Create a DisplayControlImple from a ControlContext

Parameters:
controlContext - context to use
Method Detail

initBasic

public final void initBasic(String displayId,
                            List categories,
                            Hashtable properties)
This init method is used to just initialize some basic properties of this display control. It is intended that this control has not been created for normal display purposes but has been created for other purposes (e.g., Testing valid help ids).

Specified by:
initBasic in interface DisplayControl
Parameters:
displayId - The identifier of this control. Taken from controls.xml
categories - The list of DataCategoryies for this control
properties - Any properties (usually defined in controls.xml)

init

public final void init(String displayId,
                       List categories,
                       List choices,
                       ControlContext controlContext,
                       String properties,
                       DataSelection dataSelection)
                throws VisADException,
                       RemoteException
Deprecated. use init that takes a properties Hashtable

This init method is the one actually called by the IDV. The default is to turn around and call init with the first element in the dataChoice array.

Specified by:
init in interface DisplayControl
Parameters:
displayId - The identifier of this control. Taken from controls.xml
categories - The list of DataCategoryies for this control
choices - The list of DataChoice-s (usually only one) for this control
controlContext - The context in which this control is in (usually a reference to the IntegratedDataViewer
properties - Any properties (usually defined in controls.xml)
dataSelection - Holds any specifications of subsets of the data (e.g., times)
Throws:
RemoteException
VisADException

init

public final void init(String displayId,
                       List categories,
                       List choices,
                       ControlContext controlContext,
                       Hashtable properties,
                       DataSelection dataSelection)
                throws VisADException,
                       RemoteException
This init method is the one actually called by the IDV. The default is to turn around and call init with the first element in the dataChoice array.

Specified by:
init in interface DisplayControl
Parameters:
displayId - The identifier of this control. Taken from controls.xml
categories - The list of DataCategoryies for this control
choices - The list of DataChoice-s (usually only one) for this control
controlContext - The context in which this control is in (usually a reference to the IntegratedDataViewer
properties - Any properties (usually defined in controls.xml)
dataSelection - Holds any specifications of subsets of the data (e.g., times)
Throws:
RemoteException
VisADException

doInitialUpdateLegendAndList

protected void doInitialUpdateLegendAndList()
Do the initial update legend and list


addToControlContext

protected void addToControlContext()
Add to the control context


initAsTemplate

public void initAsTemplate()
Initialize as a template

Specified by:
initAsTemplate in interface DisplayControl

initAsPrototype

public void initAsPrototype()
Initialize as a prototype

Specified by:
initAsPrototype in interface Prototypable

initAfterUnPersistence

public void initAfterUnPersistence(ControlContext vc,
                                   Hashtable properties)
Called by the IntegratedDataViewer to initialize after this control has been unpersisted

Specified by:
initAfterUnPersistence in interface DisplayControl
Parameters:
vc - The context in which this control exists
properties - Properties that may hold things

initAfterUnPersistence

public void initAfterUnPersistence(ControlContext vc,
                                   Hashtable properties,
                                   List preSelectedDataChoices)
Called by the IntegratedDataViewer to initialize after this control has been unpersisted

Specified by:
initAfterUnPersistence in interface DisplayControl
Parameters:
vc - The context in which this control exists
properties - Properties that may hold things
preSelectedDataChoices - set of preselected data choices

init

public boolean init(List choices)
             throws VisADException,
                    RemoteException
Initialize this instance according to the first DataChoice in a List. This implementation invokes init(DataChoice) to perform the initialization. If the list is null or empty, then the argument to init(DataChoice) is null.

Parameters:
choices - A list of data choices or null.
Returns:
true if and only if this instance was correctly initialized by the data choice.
Throws:
VisADException - if a VisAD Failure occurs.
RemoteException - if a Java RMI failure occurs.

init

public boolean init(DataChoice choice)
             throws VisADException,
                    RemoteException

Initialize this instance according to a data choice. Subclasses should override this method. Overridding methods should probably invoke setData(DataChoice) as part of their initialization procedure -- although it is unclear when this is actually necessary.

This implementation simply returns true.

Parameters:
choice - A data choice or null.
Returns:
true if and only if this instance was correctly initialized by the data choice.
Throws:
VisADException - if a VisAD Failure occurs.
RemoteException - if a Java RMI failure occurs.

initDone

public void initDone()
Called after all initialization has been done. A hook that allows derived classes to do any further initialization.


addPropertyChangeListener

public void addPropertyChangeListener(PropertyChangeListener listener)
Add a property change listener.

Parameters:
listener - the listener to add

removePropertyChangeListener

public void removePropertyChangeListener(PropertyChangeListener listener)
Remove property change listener.

Parameters:
listener - listener to remove

firePropertyChangeEvent

protected void firePropertyChangeEvent(PropertyChangeEvent event)
Fire a property change event.

Parameters:
event - event to propagate

hasTimeMacro

protected boolean hasTimeMacro(String t)
Does this have a time macro string?

Parameters:
t - the string to check
Returns:
true if there is a time macro

shouldAddAnimationListener

protected boolean shouldAddAnimationListener()
A hook to allow derived classes to tell us to add this as an animation listener

Returns:
Add as animation listener

shouldAddDisplayListener

protected boolean shouldAddDisplayListener()
A hook to allow derived classes to tell us to add this as a display listener

Returns:
Add as display listener

shouldAddControlListener

protected boolean shouldAddControlListener()
A hook to allow derived classes to tell us to add this as a control listener

Returns:
Add as control listener

getHaveInitialized

public boolean getHaveInitialized()
Has this control been initialized

Returns:
Is this control initialized

getGraphicsConfiguration

protected GraphicsConfiguration getGraphicsConfiguration(boolean is3D,
                                                         boolean useStereo)
Get the graphics configuration

Parameters:
is3D - use Java 3D
useStereo - use stereo (id3D must be true)
Returns:
the GraphicsConfiguration for DisplayImpl's

applyAttributesToDisplayables

protected void applyAttributesToDisplayables()
                                      throws VisADException,
                                             RemoteException
Used to apply all of the display attributes taht are active to the Displayable-s

Throws:
RemoteException
VisADException

addAttributeFlags

protected void addAttributeFlags(int f)
Add the given attribute flag (e.g., FLAG_COLORTABLE) to the attrbiute flag map.

Parameters:
f - The flag (e.g., FLAG_COLORTABLE)

setAttributeFlags

protected void setAttributeFlags(int f)
Set the attribute flag map to the given value. Note: this really should just set the flags but instead it OR's the attributeFlags with the given set of flags in the f parameter. Lets keep this logic because changing it now breaks lotsof things. If you want to actually set the flags call reallySetAttributeFlags

Parameters:
f - The value of the attribute flag map

reallySetAttributeFlags

protected void reallySetAttributeFlags(int f)
Set the attribute flag map to the given value.

Parameters:
f - THe value of the attribute flag map

checkFlag

protected boolean checkFlag(int f)
Test if the given flag is set in the attrbiuteFlags

Parameters:
f - The flag to check
Returns:
Is the given flag set

getAttributeFlags

protected int getAttributeFlags()
Return the attribute flag map

Returns:
The attributeFlags

addAttributedDisplayable

protected void addAttributedDisplayable(Displayable d)
Add the given Displayable to the list of attribute displayables. Use this object's attributeFlags data member as the attribute attributeFlags to use.

Parameters:
d - The Displayable to add

addAttributedDisplayable

protected void addAttributedDisplayable(Displayable d,
                                        int attributeFlags)
Add the given Displayable to the list of displayables. This is simply a wrapper that passes in notGlobalFlags="0"

Parameters:
d - The Displayable to add
attributeFlags - The set of attributes for this displayable

addAttributedDisplayable

protected void addAttributedDisplayable(Displayable d,
                                        int attributeFlags,
                                        int notGlobalFlags)
Add the given Displayable into the list of attributed displayables managed by this DisplayControl. An "attributed displayable" is one which there is one (or more) gui widgets created for defining the graphic attributes of the displayable (e.g., color table, param range, color, etc) defined by the bitmask attributeFlags. The notGlobalFlags are used to define the attribute for this displayable but not used for creating the gui, etc.

Parameters:
d - The Displayable to add
attributeFlags - The set of attributes for this displayable
notGlobalFlags - Attribute flags for this displayable but don't let them effect the gui.

applyContourInfo

protected void applyContourInfo()
                         throws VisADException,
                                RemoteException
If the contourInfo is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_CONTOUR

Throws:
RemoteException
VisADException

applyColorScaleInfo

protected void applyColorScaleInfo()
                            throws VisADException,
                                   RemoteException
If the colorScaleInfo is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_COLORTABLE

Throws:
RemoteException - problem with remote display
VisADException - problem with local display

colorUnitChanged

protected void colorUnitChanged(Unit oldUnit,
                                Unit newUnit)
A hook that is called when the color unit is changed. Allows derived classes to act accordingly.

Parameters:
oldUnit - The old color unit
newUnit - The new color unit

applyColorUnit

protected void applyColorUnit()
                       throws VisADException,
                              RemoteException
If the color unit (gotten from a call to getUnitForColor) is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_COLORUNIT

Throws:
RemoteException
VisADException

displayUnitChanged

protected void displayUnitChanged(Unit oldUnit,
                                  Unit newUnit)
A hook that is called when the display unit is changed. Allows derived classes to act accordingly.

Parameters:
oldUnit - The old color unit
newUnit - The new color unit

getRawDataUnit

public Unit getRawDataUnit()
Get the raw data unit.

Returns:
null

applyDisplayUnit

protected void applyDisplayUnit()
                         throws VisADException,
                                RemoteException
If the color unit (gotten from a call to getUnitForColor) is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_DISPLAYUNIT

Throws:
RemoteException
VisADException

getColorTableToApply

protected ColorTable getColorTableToApply()
Get the color table to use when applying to displayables

Returns:
The color table

applyColorTable

protected void applyColorTable()
                        throws VisADException,
                               RemoteException
If the color table is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_COLORTABLE

Throws:
RemoteException
VisADException

resetDimness

public void resetDimness()
Set the color table dimness to the default


setColorDimmer

public void setColorDimmer()
                    throws VisADException,
                           RemoteException
Set the color dimmer

Throws:
RemoteException - On badness
VisADException - On badness

setColorBrighter

public void setColorBrighter()
                      throws VisADException,
                             RemoteException
Set the color brighter

Throws:
RemoteException - On badness
VisADException - On badness

applyColor

protected void applyColor()
                   throws VisADException,
                          RemoteException
If the color is non-null then apply it to the Displayables in the displayables list that are flagged with the FLAG_COLOR

Throws:
RemoteException
VisADException

applyRange

protected void applyRange()
                   throws VisADException,
                          RemoteException
Apply the range it to the Displayables in the displayables list that are flagged with the FLAG_COLORTABLE

Throws:
RemoteException
VisADException

applySelectRange

protected void applySelectRange()
                         throws VisADException,
                                RemoteException
Apply the range it to the Displayables in the displayables list that are flagged with the FLAG_SELECTRANGE

Throws:
RemoteException
VisADException

applyZPosition

protected void applyZPosition()
                       throws VisADException,
                              RemoteException
Apply the z position to the displayables with FLAG_ZPOSITION set

Throws:
RemoteException - When bad things happen
VisADException - When bad things happen

applyLineWidth

protected void applyLineWidth()
                       throws VisADException,
                              RemoteException
Apply the line width to the displayables with FLAG_LINEWIDTH set

Throws:
RemoteException - When bad things happen
VisADException - When bad things happen

getColorTableForDisplayable

public float[][] getColorTableForDisplayable(ColorTable ct)
The default is to use the alpha color table. We use this so derived classes can override it before applying the color table to the Displayable-s

Parameters:
ct - The original color table
Returns:
A 2D float array that is the actual color table

addToRangeMenu

public void addToRangeMenu(RangeWidget rw,
                           List items)
A hook to add an entry into the range menu

Parameters:
rw - Range widget
items - List of menu items

addToRangeMenu

public void addToRangeMenu(ColorTableWidget cw,
                           List items)
Deprecated. use #addToRangeMenu(RangeWidget)

A hook to add an entry into the range menu

Parameters:
cw - the color table widget
items - List of menu items

addToRangeMenu

public void addToRangeMenu(RangeDialog selectRangeWidget,
                           List items)
Deprecated. use #addToRangeMenu(RangeWidget)

A hook to add an entry into the range menu

Parameters:
selectRangeWidget - the range dialog that has the items
items - List of menu items

parseProperties

protected void parseProperties(String properties)
The given properties String is a ";" delimited list of name=value properties. This method processes this string, calling setProperty for each property.

Parameters:
properties - Specification of the name=value properties.

setInitialSettings

public void setInitialSettings(List settings)
Set the initial settings

Parameters:
settings - the display settings

applyProperties

public void applyProperties(Hashtable properties)
Parameters:
properties - Specification of the name=value properties.

applyDisplaySetting

public void applyDisplaySetting(DisplaySetting displaySetting)
                         throws Exception
Apply a display setting to this control

Parameters:
displaySetting - the settings to apply
Throws:
Exception - problem setting settings

applyPropertyValues

public void applyPropertyValues(List props)
                         throws Exception
Apply the property values in the list

Parameters:
props - list of property values
Throws:
Exception - problem setting property values

getCanDoRemoveAll

public boolean getCanDoRemoveAll()
Used by the IDV to determine whether a control should be removed when the user does a remove all. This is overwritten by the TextDisplayControl to return false.

Specified by:
getCanDoRemoveAll in interface DisplayControl
Returns:
Should this control be removed

setCanDoRemoveAll

public void setCanDoRemoveAll(boolean v)
Used by the IDV to determine whether a control should be removed when the user does a remove all.

Parameters:
v - The value

getShowNoteText

public boolean getShowNoteText()
Is this control currently showing the embedded note text area.

Returns:
Is showing notes

setShowNoteText

public void setShowNoteText(boolean n)
Used by the presistence/unpersistence to record whether this control is showing its note text area

Parameters:
n - The value for the show note text flag

getNoteText

public String getNoteText()
This is the value (String) of the note text area.

Returns:
The note text

setNoteText

public void setNoteText(String n)
Set the value of the note text area.

Parameters:
n - The note text

toggleNoteTextArea

public void toggleNoteTextArea()
Toggle the visibility of the noteTextArea.


redoGuiLayout

protected void redoGuiLayout()
Used to relayout the gui mainPanel


isInTransectView

public boolean isInTransectView()
Are we displayed in a transect view manager

Returns:
Is in transect view

addNoteText

protected void addNoteText(JPanel mainPanel,
                           JComponent noteWrapper)
Insert the given noteWrapper (which holds the note text TextArea) into the gui

Parameters:
mainPanel - Where to add the noteWrapper
noteWrapper - Holds the note text TextArea

setProperty

protected void setProperty(String name,
                           Object value)
Wrapper around Misc.propertySet

Parameters:
name - Property name
value - Property value

addDisplayMaster

protected void addDisplayMaster(DisplayMaster s)
A sub-class can register any DisplayMaster-s created and managed by them. When this DisplayControl is removed it runs through all of the DisplayMaster-s and calls destroy on them.

Parameters:
s - The DisplayMaster to add

addViewManager

protected void addViewManager(ViewManager s)
A sub-class can register any ViewManager-s created and managed by them. When this DisplayControl is removed it runs through all of the ViewManager-s and calls destroy on them.

Parameters:
s - The ViewManager to add

clearViewManagers

protected void clearViewManagers()
Runs through the list of ViewManager-s and tells each to destroy. Creates a new viewManagers list.


addSharable

public void addSharable(SharableImpl s)
A sub-class can register any SharableImpl-s created and managed by them. When this DisplayControl is removed it runs through all of the SharableImpl-s and calls removeSharable on them.

Parameters:
s - The SharableImpl to add

initializeWithNewData

protected void initializeWithNewData()
This is called when this display is created from a template and does not have any data. It is meant as a hook for derived classes to clear out state that may not be in sync with the newly chosen data


displayChanged

public final void displayChanged(DisplayEvent event)
Noop for the DisplayListener interface

Specified by:
displayChanged in interface DisplayListener
Parameters:
event - The event

handleDisplayChanged

public void handleDisplayChanged(DisplayEvent event)
Allow sub-classes to get displayevents

Parameters:
event - The event

boundsClose

protected boolean boundsClose(double a,
                              double b)
See if two values are close

Parameters:
a - first value
b - second value
Returns:
true if they are close

controlChanged

public void controlChanged(ControlEvent event)
Noop for the ControlListener interface

Specified by:
controlChanged in interface ControlListener
Parameters:
event - The event

getControlChangeSleepTime

protected long getControlChangeSleepTime()
This returns the time to sleep, in milliseconds, between checks for finally handling control changed events.

Returns:
milliseconds to sleep for control change events.

viewpointChanged

public void viewpointChanged()
This gets called when we have received a controlChanged event and have not received another one in some time delta


propertyChange

public void propertyChange(PropertyChangeEvent evt)
Handle animation change events

Specified by:
propertyChange in interface PropertyChangeListener
Parameters:
evt - The event

firstFrameDone

public void firstFrameDone()
This gets called by the view manager when it has rcvd its first frame_done event. We have this here for those displays (e.g., station model) that need state from the view manager that is only valid when there has been a display.

Specified by:
firstFrameDone in interface DisplayControl

getDataChoices

public List getDataChoices()
Return the list of current DataChoice-s

Specified by:
getDataChoices in interface DisplayControl
Returns:
List of data choices

getMyDataChoices

public List getMyDataChoices()
Deprecated. Use getDataChoices

Return the list of current DataChoice-s

Returns:
List of data choices

getInitDataChoices

public List getInitDataChoices()
Used to publicize the list of data choices for the persitence mechanism. This is the list of DataChoice-s that this control was originally create with

Returns:
List of original data choices

setInitDataChoices

public void setInitDataChoices(List l)
Used to publicize the list of data choices for the persistence mechanism

Parameters:
l - List of original data choices

setPersistedVisadData

public void setPersistedVisadData(List l)
Deprecated. 

No-op for legacy bundles

Parameters:
l - List of data

addDataChoice

public boolean addDataChoice(DataChoice c)
Add the given DataChoice to the list of data choices and return true if this is a new DataChoice.

Parameters:
c - The data choice to add
Returns:
Was this data choice added. (It won't be added if it is already in the list).

removeDataChoice

public void removeDataChoice(DataChoice dataChoice)
Remove the given DataChoice from the myDataChoices list. Tell the DataChoice to remove this object as a DataChangeListener

Parameters:
dataChoice - The data choice to remove

setDataChoices

public void setDataChoices(List newList)
Set the list of data choices to be the given list

Parameters:
newList - New list of data choices.

appendDataChoices

public void appendDataChoices(List newDataChoices)
Append the given list of DataChoice-s to the myDataChoices list

Parameters:
newDataChoices - List to append

getDataChoice

public DataChoice getDataChoice()
Return the single DataChoice

Specified by:
getDataChoice in interface DisplayControl
Returns:
The data choice

dataChanged

public void dataChanged()
Implementation of DataChangeListener.

Specified by:
dataChanged in interface DataChangeListener

receiveShareData

public void receiveShareData(Sharable from,
                             Object dataId,
                             Object[] data)
Method called by other classes that share the the state.

Specified by:
receiveShareData in interface Sharable
Overrides:
receiveShareData in class SharableImpl
Parameters:
from - other class.
dataId - type of sharing
data - Array of data being shared. In this case, the first (and only?) object in the array is the level

resetData

protected void resetData()
                  throws VisADException,
                         RemoteException
This gets called when the control has received notification of a dataChange event. By default it turns around and calls setData with the current list of data choices.

Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

addNewData

protected void addNewData(List newChoices)
                   throws VisADException,
                          RemoteException
Called when the user chooses new data for this display

Parameters:
newChoices - List of new DataChoice-s
Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

setData

protected boolean setData(List newChoices)
                   throws VisADException,
                          RemoteException
Gets called when the user has selected a new DataChoice. By default this method extracts the first DataChoice from the list of choices and calls setData (DataChoice dataChoice) {return true;}

This returns whether the data setting was successfull or not.

Parameters:
newChoices - List of new DataChoice-s
Returns:
Was this successful
Throws:
RemoteException - Java RMI problem
VisADException - problem creating VisAD object

checkIfDataOk

protected boolean checkIfDataOk(DataInstance di)
                         throws VisADException,
                                RemoteException
Implements the default check if the new DataInstance/DataChoice pair holds valid data. The default DataInstance.dataOk method does a getData call (which may be expensive) and returns whether the Data object is non-null. Sub-classes can override this method. For example, the ImageSequence control overridess this to do nothing because it wants to display a progress bar.

Parameters:
di - The DataInstance to check
Returns:
Is the data held by this data instance ok (typically is it non-null)
Throws:
RemoteException
VisADException

setData

protected boolean setData(DataChoice dataChoice)
                   throws VisADException,
                          RemoteException

Sets the data associated with this instance. This method gets called at initialization or when the user has selected a new DataChoice through the data selector control.

In order to implement subclasses of this class that behave correctly, you should know that this implementation uses overridable methods of this class in the following way:

Parameters:
dataChoice - The DataChoice to use.
Returns:
Was this setData call successful
Throws:
RemoteException
VisADException

getInitialRange

protected Range getInitialRange()
                         throws RemoteException,
                                VisADException
Hook method to allow derived classes to return a different initial Range

Returns:
The initial range to use
Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

getInitialColorTable

protected ColorTable getInitialColorTable()
A hook so derived classes can return a colortable. This method uses the DisplayConventions to get the color table based on the paramName

Returns:
The color table to use

revertToDefaultColorTable

protected void revertToDefaultColorTable()
Reset the color table to the initial color table


revertToDefaultRange

protected void revertToDefaultRange()
Reset the range to the initial range


getOldColorTableOrInitialColorTable

protected final ColorTable getOldColorTableOrInitialColorTable()
Just a utility for bundles that were created with the old code that saved off the color table name, not the color table.

Returns:
The color table

setCategories

public void setCategories(List c)
A set method so the categories list will get persisted.

Parameters:
c - The list of DataCategorys

getCategories

public List getCategories()
Returns the list of data categories.

Specified by:
getCategories in interface DisplayControl
Returns:
The list of DataCategorys

showWaitCursor

public void showWaitCursor()
A helper method to show the wait cursor


showNormalCursor

public void showNormalCursor()
A helper method to show the normal cursor


setDisplayName

public void setDisplayName(String displayName)
What is the name of this control (e.g., "Plan view")

Parameters:
displayName - The name to use for display purposes

getPropertyDisplayName

public String getPropertyDisplayName()
I forgot why there was this getter (with the "Property") here

Returns:
The display name

getDisplayName

public String getDisplayName()
Returns the name of this display. Initially, the name of the display is "Display", but it can be set by the setDisplayName(String) method.

Returns:
The name of this display.

getDisplayId

public String getDisplayId()
The id of this control (from controls.xml) We have this here for xml persistence

Specified by:
getDisplayId in interface DisplayControl
Returns:
The id

setDisplayId

public void setDisplayId(String theId)
Set the id of this control (from controls.xml) We have this here for xml persistence

Parameters:
theId - The id

clearDataInstance

protected void clearDataInstance()
Clear the DataInstance


setDataInstance

protected void setDataInstance(DataInstance dataInstance)
Set the data instance. Protected so it does not get persisted.

Parameters:
dataInstance - The data instance used by this control

getDataInstance

public DataInstance getDataInstance()
We have this here (in part) for xml persistence

Returns:
The data instance used by this control

getDataInstance

public DataInstance getDataInstance(boolean forceCreation)
We have this here (in part) for xml persistence

Parameters:
forceCreation - if true, force it.
Returns:
The data instance used by this control

getData

public Data getData(DataInstance dataInstance)
             throws VisADException,
                    RemoteException
A wrapper around dataInstance.getData but this calls updateDataInstance first

Parameters:
dataInstance - the dataInstance
Returns:
dataInstance.getData();
Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

getGrid

public FieldImpl getGrid(GridDataInstance dataInstance)
                  throws VisADException,
                         RemoteException
A wrapper around dataInstance.getGrid but this calls updateDataInstance first

Parameters:
dataInstance - the dataInstance
Returns:
dataInstance.getGrid();
Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

getGrid

public FieldImpl getGrid(GridDataInstance dataInstance,
                         boolean copy)
                  throws VisADException,
                         RemoteException
A wrapper around dataInstance.getGrid but this calls updateDataInstance first

Parameters:
dataInstance - the dataInstance
copy - make a copy of the field
Returns:
dataInstance.getGrid(copy);
Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

updateGridDataInstance

protected GridDataInstance updateGridDataInstance(GridDataInstance dataInstance)
                                           throws VisADException,
                                                  RemoteException
update the datainstance in preparation for a getData call

Parameters:
dataInstance - the grid data instance
Returns:
the new instance
Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

updateDataInstance

protected DataInstance updateDataInstance(DataInstance dataInstance)
                                   throws VisADException,
                                          RemoteException
update the datainstance in preparation for a getData call. This will set the timeDriverTimes if enabled

Parameters:
dataInstance - the dataInstance to update
Returns:
the updated dataInstance
Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

updateDataSelection

protected DataSelection updateDataSelection(DataSelection dataSelection)
                                     throws VisADException,
                                            RemoteException
update the dataselection in preparation for a getData call. This will set the timeDriverTimes if enabled

Parameters:
dataSelection - the dataSelection to update
Returns:
the new DataSelection
Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

setParamName

public void setParamName(String paramName)
The name of the parameter (initially from the DataChoice) displayed by this control.

Parameters:
paramName - The parameter name

getViewer

public ControlContext getViewer()
We have this here (in part) for xml persistence This is usually the IntegratedDataViewer

Returns:
The context in which this control exists

setViewer

public void setViewer(ControlContext controlContext)
We have this here (in part) for xml persistence This is usually the IntegratedDataViewer

Parameters:
controlContext - The control context

getViewContext

public ViewContext getViewContext()
A hack for now. The controlContext is really the IDV which also serves as the ViewContext

Returns:
The context in which view managers exist

getControlContext

public ControlContext getControlContext()
This is the IntegratedDataViewer

Returns:
The context in which this control exists

getIdv

public IntegratedDataViewer getIdv()
Get the integraed data viewer that this is part of

Returns:
the IntegratedDataViewer

getDisplayConventions

public DisplayConventions getDisplayConventions()
Get the DisplayConventions to use.

Returns:
The display conventions

getLabel

public String getLabel()
Used by the idv classes

Specified by:
getLabel in interface DisplayControl
Returns:
The label that describes this control

toString

public String toString()
The toString method.

Overrides:
toString in class Object
Returns:
The displayName

getWindow

public JFrame getWindow()
Return the control's JFrame

Specified by:
getWindow in interface DisplayControl
Returns:
The JFrame

getTitle

protected String getTitle()
Returns the window title. This implementation invokes the getDisplayName() method.

Returns:
The window title.

setTitle

public void setTitle(String title)
Set the title of the window if it has been created.

Parameters:
title - The title

updateLegendLabel

protected void updateLegendLabel()
This method is called to update the legend labels when some state has changed in this control that is reflected in the labels.


updateLegendAndList

protected void updateLegendAndList()
Update the legend labels and the display list


updateDisplayList

protected void updateDisplayList()
Update the display list data


getDataForDisplayList

public Data getDataForDisplayList()
Get the data for the display list

Specified by:
getDataForDisplayList in interface DisplayControl
Returns:
the dat for the display list

getDisplayListData

protected Data getDisplayListData()
Add the data to the in display legend

Returns:
the data for the display list displayable

getDisplayListDisplayable

public DisplayableData getDisplayListDisplayable(ViewManager view)
Get the displayable for the Display List

Specified by:
getDisplayListDisplayable in interface DisplayControl
Parameters:
view - the view that it will go into
Returns:
the appropriate displayable

setDisplayListProperties

protected void setDisplayListProperties(DisplayableData d,
                                        ViewManager view)
                                 throws VisADException,
                                        RemoteException
Set the display list properties on the displayable

Parameters:
d - the displayable
view - the view manager
Throws:
RemoteException - a Java RMI Exception occured
VisADException - unable to set properties

getLegendButtons

public JComponent getLegendButtons(int legendType)
Set the legend buttons

Specified by:
getLegendButtons in interface DisplayControl
Parameters:
legendType - type of legend
Returns:
component containing buttons

getShortParamName

protected String getShortParamName()
Get the short parameter name

Returns:
The String to be used for the short parameter name

getLongParamName

protected String getLongParamName()
Get the long parameter name

Returns:
The String to be used for the long parameter name

getDataSources

protected List getDataSources()
Get the DataSources associated with this contol

Returns:
list of data sources

addLabelMacros

protected void addLabelMacros(String template,
                              List patterns,
                              List values)
Add any macro name/value pairs.

Parameters:
template - template for the label
patterns - The macro names
values - The macro values

getLegendLabels

protected void getLegendLabels(List labels,
                               int legendType)
This method is used to get all of the labels (String) that are shown in the side legend.

Parameters:
labels - A list that the labels are inserted into
legendType - The type of legend, BOTTOM_LEGEND or SIDE_LEGEND

getMenuLabel

public String getMenuLabel()
Return the label used for the menues in the IDV. Implements the method in the DisplayControl interface

Specified by:
getMenuLabel in interface DisplayControl
Returns:
The menu label

toFront

public void toFront()
Move the control's window to the front.

Specified by:
toFront in interface DisplayControl

removeOnWindowClose

protected boolean removeOnWindowClose()
Should the DisplayControl do a doRemove when the window closes.

Returns:
Whether to remove this control on a window close.

guiImported

public void guiImported()
This is called to inform this display control that its gui has been imported by some other idv component and it no longer is in a window.


guiExported

public void guiExported()
This is called to inform this display control that its gui has been exported out of some other component (ex: the MultiDisplayControl).


createIdvWindow

protected IdvWindow createIdvWindow()
Create an IDV window

Returns:
the window

createDisplayListDisplayable

protected DisplayableData createDisplayListDisplayable(ViewManager view)
                                                throws VisADException,
                                                       RemoteException
Make the DisplayListDisplayable

Parameters:
view - the view that this will be in
Returns:
The displayable data object
Throws:
RemoteException - Java RMI Exception
VisADException - VisAD problem

doMakeWindow

protected void doMakeWindow()
                     throws VisADException,
                            RemoteException
Called by the derived class init method to create the gui window.

Throws:
RemoteException
VisADException

isGuiShown

protected boolean isGuiShown()
Is the GUI being shown

Returns:
true if it is

doMakeMenuBar

protected JMenuBar doMakeMenuBar()
Make the menu bar

Returns:
The menu bar

captureWindow

public void captureWindow()
Screen snapshot of window


setMainPanelDimensions

protected void setMainPanelDimensions()
                               throws Exception
Set the main panel dimenstions

Throws:
Exception - problem setting the dimensions

getImage

public Image getImage()
               throws Exception
Get the image

Returns:
the image
Throws:
Exception - problem getting image

getViewManagerForCapture

public ViewManager getViewManagerForCapture(String what)
                                     throws Exception
Allows a derived class to provide its own viewmanager wehn capturing an image of the display from isl

Parameters:
what - The specification of the viewmanager (from the isl)
Returns:
the viewmanager or null
Throws:
Exception - on badness

getImage

public Image getImage(String what)
               throws Exception
Get the image of "what"

Parameters:
what - description of what to get
Returns:
the image
Throws:
Exception - problem getting image

doMakeMenuBarMenus

protected List doMakeMenuBarMenus(List menus)
Make the menus to put in the menu bar

Parameters:
menus - List to add to
Returns:
The menus list

getStore

public XmlObjectStore getStore()
Get the object store

Returns:
the store

handleWindowClosing

protected void handleWindowClosing()
Handle the window closing.


getOuterContents

public Component getOuterContents()
The outer contents is the outermost component of the gui (i.e., it holds the menu bar and the mainPanel)

Returns:
Gui contents

getMainPanel

public JComponent getMainPanel()
Get the component for the main panel of this DisplayControlImpl's contents.

Returns:
GUI contents

setMakeWindow

public void setMakeWindow(boolean value)
Should this control make its own window. This method is here (mostly) for xml unpersistence

Parameters:
value - The make window flag

getMakeWindow

public boolean getMakeWindow()
Should this control make its own window. This method is here (mostly) for xml unpersistence

Returns:
The flag

setWindowSize

public void setWindowSize(Dimension value)
This method is here (mostly) for xml unpersistence

Parameters:
value - The size of the window

getWindowSize

public Dimension getWindowSize()
This method is here (mostly) for xml unpersistence

Returns:
The size of the window (if non-null) else null

getMainPanelSize

public Dimension getMainPanelSize()
Get the main panel size

Returns:
the main panel size

setMainPanelSize

public void setMainPanelSize(Dimension s)
Set the main panel size

Parameters:
s - the dimensions of the panel

setWindowX

public void setWindowX(int x)
This method is here (mostly) for xml unpersistence

Parameters:
x - The x location of the window

getWindowX

public int getWindowX()
This method is here (mostly) for xml unpersistence

Returns:
The x location of the window

setWindowY

public void setWindowY(int y)
This method is here (mostly) for xml unpersistence

Parameters:
y - The y location of the window

getWindowY

public int getWindowY()
This method is here (mostly) for xml unpersistence

Returns:
The y location of the window

show

public void show()
SHow the window

Specified by:
show in interface DisplayControl

toggleWindow

public void toggleWindow()
Hide or show the main window

Specified by:
toggleWindow in interface DisplayControl

hide

public void hide()
Hide the window


initWindow

public void initWindow(IdvWindow window)
A hook method to allow subclasses to initialize the dialog window, set the size of the dialog window, etc.

Parameters:
window - The control's window

getWindowVisible

public boolean getWindowVisible()
Is the window currently visible

Returns:
Window visibility

shouldWindowBeVisible

public boolean shouldWindowBeVisible()
Does this display control popup its window on creation

Returns:
Should the window be visible

setWindowVisible

public void setWindowVisible(boolean v)
Set the local data memeber myWindowVisible. If myWindow is non-null then set its visiblity as well. This method is mostly used in the XmlEncoder persistence mechanism.

Parameters:
v - Window visibility

getChangeParameterLabel

protected String getChangeParameterLabel()
A hook to allow derived classes to have their own label in the menu for the change data call.

Returns:
Menu label for the change data call.

hyperlinkUpdate

public void hyperlinkUpdate(HyperlinkEvent e)
Implement the HyperLinkListener method to pass any link clicks off to the ControlContext

Specified by:
hyperlinkUpdate in interface HyperlinkListener
Parameters:
e - The event

hasMapProjection

public boolean hasMapProjection()
Does this display have a map projection

Returns:
Has map projection

reloadDataSource

public void reloadDataSource()
                      throws RemoteException,
                             VisADException
Reload the data sources

Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

reloadDataSourceInThread

public void reloadDataSourceInThread()
                              throws RemoteException,
                                     VisADException
reload the data source in a thread.

Throws:
RemoteException - Java RMI problem
VisADException - VisAD problem

getLastFileMenuItems

protected void getLastFileMenuItems(List items)
Get last file menu items.

Parameters:
items - the last items in the file menu.

getSaveMenuItems

protected void getSaveMenuItems(List items,
                                boolean forMenuBar)
Add in the menu items for the save and export display template

Parameters:
items - List of menu items to add into
forMenuBar - if this is for the menubar

getEditMenuItems

public List getEditMenuItems(List items)
Add the relevant edit menu items into the list

Parameters:
items - List of menu items
Returns:
the list with the new items

getFileMenuItems

public List getFileMenuItems(List items)
Add the relevant edit menu items into the list

Parameters:
items - List of menu items
Returns:
the list with the new items

getViewMenuItems

public List getViewMenuItems(List items)
Add the relevant view menu items into the list

Parameters:
items - List of menu items
Returns:
the list with the new items

getEditMenuItems

protected void getEditMenuItems(List items,
                                boolean forMenuBar)
Add the relevant edit menu items into the list

Parameters:
items - List of menu items
forMenuBar - Is this for the menu in the window's menu bar or for a popup menu in the legend

haveParameterDefaults

protected boolean haveParameterDefaults()
Check to see if we have any display properties.

Returns:
true if we have properties for parameter defaults.

getTimeSet

public Set getTimeSet()
               throws RemoteException,
                      VisADException
Get the time set

Specified by:
getTimeSet in interface DisplayControl
Returns:
the Set for times
Throws:
RemoteException - RMI exception
VisADException - Couldn't create time set

getDataTimeSet

protected Set getDataTimeSet()
                      throws RemoteException,
                             VisADException
Collect the time animation set from the displayables. If none found then return null.

Returns:
Animation set
Throws:
RemoteException - On badness
VisADException - On badness

haveDataTimes

protected boolean haveDataTimes()
Do any of our displayables have times

Returns:
Have times

findDisplays

protected List findDisplays(String key)
Find displays based on the key

Parameters:
key - the key
Returns:
List of appropriate display

findDisplays

protected List findDisplays(String key,
                            List displays)
Find displays with the particular key in the list of displays

Parameters:
key - key to look for
displays - list of displays
Returns:
the displays for that key

showProperties

public void showProperties()
Show the properties dialog


addPropertiesComponents

protected void addPropertiesComponents(JTabbedPane jtp)
Add tabs to the properties dialog.

Parameters:
jtp - the JTabbedPane to add to

addDisplaySettings

protected void addDisplaySettings(DisplaySettingsDialog dsd)
Add property values for this DisplaySettingsDialog

Parameters:
dsd - the display settings dialog

setLabelAsPreference

public void setLabelAsPreference(Object[] obj)
Set the label as a preference

Parameters:
obj - list of objects defining the label

showDisplaySettingsDialog

public void showDisplaySettingsDialog()
Show the DisplaySettingsDialog


getSettingsPanel

protected JPanel getSettingsPanel()
Get the settings panel

Returns:
the panel for settings

addCheckBoxSettings

protected void addCheckBoxSettings(List comps,
                                   Hashtable methodNameToSettingsMap)
Add checkbox type settings to the Properties panel

Parameters:
comps - list of checkbox components
methodNameToSettingsMap - hashtable of methods to checkbox

applyProperties

public final boolean applyProperties()
Apply the properties from the dialog

Returns:
true if successful

doApplyProperties

public boolean doApplyProperties()
Apply the properties

Returns:
true if successful

showContourPropertiesDialog

public void showContourPropertiesDialog()
Popup the contour properties dialog


showColorScaleDialog

public void showColorScaleDialog()
Popup the color scale properties dialog


getMacroNames

protected void getMacroNames(List names,
                             List labels)
Add any macro name/label pairs

Parameters:
names - List of macro names
labels - List of macro labels

doExport

public void doExport(String what,
                     String filename)
              throws Exception
Called by ISL. Write out some data defined by the what parameter to the given file. This method throws an UnimplementedException. Derived classes need to overwrite this to write out the appropriate data

Parameters:
what - What is to be written out
filename - To what file
Throws:
Exception

saveAsParameterDefaults

public void saveAsParameterDefaults()
Save the state as parameter defaults


saveAsFavorite

public void saveAsFavorite()
Save this display control as a favorite display template.


saveAsTemplate

public void saveAsTemplate()
Save this display control as a display template.


saveAsPrototype

public void saveAsPrototype()
Save this display as a prototype (default)


clearPrototype

public void clearPrototype()
Clear the prototype (default) for this display control


displayableToFront

public void displayableToFront()
Move the displayable to the front


getViewMenuItems

protected void getViewMenuItems(List items,
                                boolean forMenuBar)
Add the relevant view menu items into the list

Parameters:
items - List of menu items
forMenuBar - Is this for the menu in the window's menu bar or for a popup menu in the legend

getDataProjectionLabel

protected String getDataProjectionLabel()
Get the data projection label

Returns:
the data projection label

getFileMenuItems

protected void getFileMenuItems(List items,
                                boolean forMenuBar)
Add the relevant file menu items into the list

Parameters:
items - List of menu items
forMenuBar - Is this for the menu in the window's menu bar or for a popup menu in the legend

saveDataChoiceInCache

public void saveDataChoiceInCache()
Save the data choice into the cache data source


getExtraMenus

protected void getExtraMenus(List menus,
                             boolean forMenuBar)
Get any extra menus for this control. Subclasses should override to add more menus

Parameters:
menus - list of menus to populate
forMenuBar - Is this for the menu in the window's menu bar or for a popup menu in the legend

getHelpMenuItems

protected void getHelpMenuItems(List items,
                                boolean forMenuBar)
Add the help menu items

Parameters:
items - List of menu items
forMenuBar - Is this for the menu in the window's menu bar or for a popup menu in the legend

showDetails

public void showDetails()
Popup the details window


getHelpIds

public List getHelpIds()
Return the list of (String) java help ids

Returns:
List of help ids

showHelp

public void showHelp()
This method will attempt to show the relevant javahelp for this display. It successively tries to show the helpUrl attribute, the "idv.controls.displayId" and then each "idv.controls.classname"

If there is no help available it will popup a message to the user.

Specified by:
showHelp in interface DisplayControl

isInViewManager

public boolean isInViewManager()
Does this control have displays in a view manager

Returns:
Does this control have displays in a view manager

saveImage

public void saveImage(String filename)
Find the first ViewManager in the list of DisplayInfo-s and have the ViewManager write its image to to given filename.

Specified by:
saveImage in interface DisplayControl
Parameters:
filename - The file to write the image to

writeTestArchive

public void writeTestArchive(String archiveName)
Write out all screen images

Specified by:
writeTestArchive in interface DisplayControl
Parameters:
archiveName - The name of the archive we are writing to

projectionChanged

public void projectionChanged()
Method to call if projection changes. Subclasses that are worried about such events should implement this.

Specified by:
projectionChanged in interface DisplayControl

transectChanged

public void transectChanged()
Method called when a transect changes.

Specified by:
transectChanged in interface DisplayControl

viewManagerChanged

public void viewManagerChanged(String property)
Method called when a transect changes.

Specified by:
viewManagerChanged in interface DisplayControl
Parameters:
property - The property that changed

getDataProjectionForMenu

public MapProjection getDataProjectionForMenu()
Get the MapProjection for this data; if have a single point data object make synthetic map projection for location

Returns:
MapProjection for the data

getDataProjection

public MapProjection getDataProjection()
get MapProjection of data to display

Specified by:
getDataProjection in interface DisplayControl
Returns:
The native projection of the data

getDisplayCenter

public LatLonPoint getDisplayCenter()
                             throws RemoteException,
                                    VisADException
Get the center of the display

Returns:
center point or null if not a navigated display
Throws:
RemoteException - On badness
VisADException - On badness

setProjectionInView

protected void setProjectionInView(boolean useViewPreference)
Set the projection in the map view manager.

Parameters:
useViewPreference - if true, will let the view decide if preference to reset data is used or not

setProjectionInView

protected void setProjectionInView(boolean useViewPreference,
                                   boolean maintainViewpoint)
Set the projection in the map view manager.

Parameters:
useViewPreference - if true, will let the view decide if preference to reset data is used or not
maintainViewpoint - keep the same viewpoint

centerOnDisplay

protected void centerOnDisplay()
If this display has a dataprojection then center the view to it


getMapViewProjection

public MapProjection getMapViewProjection()
Get the projection from the main display.

Returns:
map projection for this display's map view manager or null

activateDisplays

protected void activateDisplays()
                         throws RemoteException,
                                VisADException
Activate each DisplayInfo

Throws:
RemoteException
VisADException

deactivateDisplays

protected void deactivateDisplays()
                           throws RemoteException,
                                  VisADException
DeActivate each DisplayInfo

Throws:
RemoteException
VisADException

findDisplayInfo

protected DisplayInfo findDisplayInfo(Displayable displayable)
Find the DisplayInfo for a displayable

Parameters:
displayable - the displayable to search for
Returns:
the associated DisplayInfo

removeDisplayable

public void removeDisplayable(Displayable displayable)
                       throws RemoteException,
                              VisADException
Remove a Displayable

Parameters:
displayable - displayable to remove
Throws:
RemoteException - Java RMI problem
VisADException - Problem in VisAD

removeDisplayables

protected void removeDisplayables()
                           throws RemoteException,
                                  VisADException
Iterates across the list of DisplayInfo-s, telling them to removeDisplayable.

Throws:
RemoteException
VisADException

removeDisplayables

protected void removeDisplayables(boolean andDestroyThem)
                           throws RemoteException,
                                  VisADException
Iterates across the list of DisplayInfo-s, telling them to removeDisplayable.

Parameters:
andDestroyThem - true to destroy them
Throws:
RemoteException
VisADException

viewManagerDestroyed

public void viewManagerDestroyed(ViewManager viewManager)
                          throws VisADException,
                                 RemoteException
Called when a ViewManager which holds the display is destoryed

Specified by:
viewManagerDestroyed in interface DisplayControl
Parameters:
viewManager - The view manager that was destroyed
Throws:
RemoteException - Java RMI error
VisADException - VisAD error

addRemovable

public void addRemovable(Removable removable)
Add something to be removed on doRemove

Parameters:
removable - the removeable

doRemove

public void