Class ContourPlanViewControl

All Implemented Interfaces:
ActionListener, ItemListener, PropertyChangeListener, EventListener, HyperlinkListener, Sharable, DataChangeListener, DisplayControl, Prototypable, ControlListener, DisplayListener

public class ContourPlanViewControl extends PlanViewControl
A control for displaying gridded data as 2D contours.
Author:
IDV Development Team
  • Constructor Details

    • ContourPlanViewControl

      public ContourPlanViewControl()
      Create a new ContourPlanViewControl setting the attribute flags as appropriate.
  • Method Details

    • createPlanDisplay

      protected DisplayableData createPlanDisplay() throws VisADException, RemoteException
      Method to create the particular DisplayableData that this this instance uses for data depictions.
      Specified by:
      createPlanDisplay in class PlanViewControl
      Returns:
      Contour2DDisplayable for this instance.
      Throws:
      RemoteException
      VisADException
    • getColorFill

      public boolean getColorFill()
      Get whether this display should use color filled contours. Used mainly by persistence.
      Returns:
      true if color fill should be used.
    • getContourInfo

      public ContourInfo getContourInfo()
      Get the contour info.
      Overrides:
      getContourInfo in class GridDisplayControl
      Returns:
      the contour info
    • getDefaultContourInfo

      protected ContourInfo getDefaultContourInfo()
      Get the default contour info
      Overrides:
      getDefaultContourInfo in class GridDisplayControl
      Returns:
      the default contour info
    • getIsRaster

      public boolean getIsRaster()
      Is this a raster display?
      Overrides:
      getIsRaster in class DisplayControlImpl
      Returns:
      true if raster
    • initializeDefaultContourInfo

      protected void initializeDefaultContourInfo(ContourInfo contourInfo)
      A hook for derived classes to set any state. ex: color filled contours turn off labels
      Overrides:
      initializeDefaultContourInfo in class GridDisplayControl
      Parameters:
      contourInfo - The contour info to initialize
    • projectionChanged

      public void projectionChanged()
      Do what is needed when projection changes
      Specified by:
      projectionChanged in interface DisplayControl
      Overrides:
      projectionChanged in class PlanViewControl
    • setColorFill

      public void setColorFill(boolean v)
      Set whether this display should use color filled contours. Used mainly by persistence.
      Parameters:
      v - true if color fill should be used.
    • setData

      protected boolean setData(DataChoice data) throws VisADException, RemoteException
      Set the data displayed by this control
      Overrides:
      setData in class PlanViewControl
      Parameters:
      data - DataChoice representing the data
      Returns:
      true if successful
      Throws:
      VisADException - error creating data
      RemoteException - error creating remote data
    • haveMultipleFields

      protected boolean haveMultipleFields()
      Return whether the Data held by this display control contains multiple fields (e.g., for the isosurface colored by another parameter
      Overrides:
      haveMultipleFields in class PlanViewControl
      Returns:
      true if there are multiple fields
    • getControlWidgets

      public void getControlWidgets(List controlWidgets) throws VisADException, RemoteException
      Add in any special control widgets to the current list of widgets.
      Overrides:
      getControlWidgets in class PlanViewControl
      Parameters:
      controlWidgets - list of control widgets
      Throws:
      VisADException - VisAD error
      RemoteException - RMI error
    • applySmoothing

      protected void applySmoothing() throws VisADException, RemoteException
      Use the value of the smoothing type and weight to subset the data.
      Overrides:
      applySmoothing in class PlanViewControl
      Throws:
      RemoteException - Java RMI problem
      VisADException - VisAD problem
    • getColorParamName

      protected String getColorParamName()
      Get the parameter name for color.
      Overrides:
      getColorParamName in class GridDisplayControl
      Returns:
      color parameter name
    • setColorByMember

      public void setColorByMember(boolean yesorno)
      Set the color by ensemble member property
      Parameters:
      yesorno - true to color by ensemble member
    • getColorByMember

      public boolean getColorByMember()
      Get the color by ensemble member property
      Returns:
      the color by ensemble member property
    • getColorUnit

      protected Unit getColorUnit()
      If ensemble, return null, otherwise return the default
      Overrides:
      getColorUnit in class GridDisplayControl
      Returns:
      the unit for the color parameter