Interface ControlContext

All Superinterfaces:
DataContext, IdvContext
All Known Subinterfaces:
ViewContext
All Known Implementing Classes:
DefaultIdv, IdvServer.MyIdv, IntegratedDataViewer, MultiPaneIdv

public interface ControlContext extends DataContext
This interface is how DisplayControls view the IntegratedDataViewer. We use an interface so that, instead of just passing the IDV as itself to the display controls, we can keep tabs on what IDV methods are used by the display controls. It is a way of keeping us somewhat honest.
Author:
IDV development team
  • Method Details

    • addDisplayControl

      void addDisplayControl(DisplayControl control)
      a Add the given DisplayControl
      Parameters:
      control - The new display control
    • removeDisplayControl

      void removeDisplayControl(DisplayControl control)
      Remove the given DisplayControl
      Parameters:
      control - The removed display control
    • getViewManager

      ViewManager getViewManager(ViewDescriptor viewDescriptor)
      Create, if needed, and return the ViewManager identified by the given ViewDescriptor
      Parameters:
      viewDescriptor - The view descriptor that defines the view manager being looked for
      Returns:
      The view manager
    • getViewManager

      ViewManager getViewManager(ViewDescriptor viewDescriptor, boolean newWindow, String properties)
      Create, if needed, and return the ViewManager identified by the given ViewDescriptor
      Parameters:
      viewDescriptor - The view descriptor that defines the view manager being looked for
      newWindow - If true it will create a new window and place the ViewManager in it if the ViewManager was newly created (as opposed to one that already exists).
      properties - Semicolon separated list of properties to configure the ViewManager
      Returns:
      The view manager
    • handleAction

      boolean handleAction(String action, Hashtable properties)
      Handle the given action. This may be a url, snippet of jython, etc.
      Parameters:
      action - The action
      properties - Any extra properties (e.g., properties to pass to the DataManager when creating a new data source)
      Returns:
      Was this action handled successfully
    • getObjectStore

      XmlObjectStore getObjectStore()
      Return the XmlObjectStore that is used to get and store persistent user state.
      Specified by:
      getObjectStore in interface DataContext
      Returns:
      The object store
    • doMakeDataChoiceMenu

      JMenu doMakeDataChoiceMenu(DataChoice dataChoice)
      Create a menu of commands for the given DataChoice
      Parameters:
      dataChoice - The data choice to create a menu for
      Returns:
      The menu
    • getLocationList

      List getLocationList()
      Return the list of NamedStationTables
      Returns:
      The station tables
    • showWindow

      void showWindow(DisplayControl control, IdvWindow window)
      Popup the given window. We have this so the IDV can control when windows are shown.
      Parameters:
      control - The control whose window is to be popped up
      window - The window to be popped up
    • showWaitCursor

      void showWaitCursor()
      Show the wait cursor.
    • showNormalCursor

      void showNormalCursor()
      Show the normal cursor.
    • getIdv

      Get the IDV
      Specified by:
      getIdv in interface DataContext
      Returns:
      The reference to the IDV
    • getPersistenceManager

      IdvPersistenceManager getPersistenceManager()
      Get the persistence manager
      Returns:
      Reference to the persistence manager
    • getColorTableManager

      ColorTableManager getColorTableManager()
      Returns:
      The color table manager
    • getPreferenceManager

      IdvPreferenceManager getPreferenceManager()
      Returns:
      The preference manager
    • getStationModelManager

      StationModelManager getStationModelManager()
      Returns:
      Get the station model manager
    • getDisplayConventions

      DisplayConventions getDisplayConventions()
      Returns:
      The display conventions
    • getResourceManager

      IdvResourceManager getResourceManager()
      Specified by:
      getResourceManager in interface DataContext
      Returns:
      The resource manager
    • createDisplay

      DisplayControl createDisplay(String dataSourceName, String paramName, String displayName, String properties, boolean initDisplayInThread)
      Create a new DisplayControl
      Parameters:
      dataSourceName - The identifying object for the data source (e.g., test.nc)
      paramName - The name of the parameter
      displayName - The display type (from controls.xml)
      properties - A set of semi-colon delimited name=value properties
      initDisplayInThread - If true then intialize the new display control in its own thread
      Returns:
      The new DisplayControl