Class LatLonLines


public class LatLonLines extends LineDrawing
Displayable to support Latitude and Longitude lines.
Version:
$Revision: 1.9 $
Author:
Don Murray, Unidata
  • Constructor Details

    • LatLonLines

      public LatLonLines(RealType type) throws VisADException, RemoteException
      Construct a LatLonLine object with default min, max and spacing values.
      Parameters:
      type - lat lines when type = RealType.Latitude, lon lines when type = RealType.Longitude
      Throws:
      VisADException - invalid type or can't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • LatLonLines

      public LatLonLines(RealType type, float minValue, float maxValue, float spacing) throws VisADException, RemoteException
      Construct a LatLonLine object of the given type.
      Parameters:
      type - lat lines when type = RealType.Latitude, lon lines when type = RealType.Longitude
      minValue - starting line (degrees)
      maxValue - ending line (degrees)
      spacing - spacing between lines (degrees)
      Throws:
      VisADException - invalid type or can't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • LatLonLines

      public LatLonLines(RealType type, float minValue, float maxValue, float spacing, boolean setData) throws VisADException, RemoteException
      Construct a LatLonLine object of the given type.
      Parameters:
      type - lat lines when type = RealType.Latitude, lon lines when type = RealType.Longitude
      minValue - starting line (degrees)
      maxValue - ending line (degrees)
      spacing - spacing between lines (degrees)
      setData - if true, the data will be set on construction
      Throws:
      VisADException - invalid type or can't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • LatLonLines

      public LatLonLines(RealType type, float minValue, float maxValue, float spacing, float base, boolean setData) throws VisADException, RemoteException
      Construct a LatLonLine object of the given type.
      Parameters:
      type - lat lines when type = RealType.Latitude, lon lines when type = RealType.Longitude
      minValue - starting line (degrees)
      maxValue - ending line (degrees)
      spacing - spacing between lines (degrees)
      base - base for lines spacing
      setData - if true, the data will be set on construction
      Throws:
      VisADException - invalid type or can't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • LatLonLines

      protected LatLonLines(LatLonLines that) throws RemoteException, VisADException
      Constructs from another instance.
      Parameters:
      that - The other instance.
      Throws:
      VisADException - VisAD failure.
      RemoteException - Java RMI failure.
  • Method Details

    • setSpacing

      public void setSpacing(float spacing) throws VisADException, RemoteException
      Change the line spacing
      Parameters:
      spacing - spacing between lines (degrees)
      Throws:
      VisADException - couldn't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • getSpacing

      public float getSpacing()
      Get the current line spacing.
      Returns:
      spacing in degrees
    • setBase

      public void setBase(float base) throws VisADException, RemoteException
      Change the line base
      Parameters:
      base - base for lines (degrees)
      Throws:
      VisADException - couldn't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • getBase

      public float getBase()
      Get the current line base.
      Returns:
      base in degrees
    • setMaxMin

      public void setMaxMin(float minValue, float maxValue) throws VisADException, RemoteException
      Change the starting and ending lines
      Parameters:
      minValue - starting line (degrees)
      maxValue - ending line (degrees)
      Throws:
      VisADException - couldn't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • setLimits

      public void setLimits(float minValue, float maxValue, float spacing) throws VisADException, RemoteException
      Set the limits and spacing of the lines.
      Parameters:
      minValue - starting line (degrees)
      maxValue - ending line (degrees)
      spacing - spacing between lines (degrees)
      Throws:
      VisADException - couldn't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • setLimits

      public void setLimits(float minValue, float maxValue, float spacing, float base) throws VisADException, RemoteException
      Set the limits and spacing of the lines.
      Parameters:
      minValue - starting line (degrees)
      maxValue - ending line (degrees)
      spacing - spacing between lines (degrees)
      base - base for lines (degrees)
      Throws:
      VisADException - couldn't create local VisAD object
      RemoteException - couldn't create remote VisAD object
    • cloneForDisplay

      public Displayable cloneForDisplay() throws RemoteException, VisADException
      Returns a clone of this instance suitable for another VisAD display. Underlying data objects are not cloned.
      Overrides:
      cloneForDisplay in class DisplayableData
      Returns:
      A semi-deep clone of this instance.
      Throws:
      VisADException - VisAD failure.
      RemoteException - Java RMI failure.
    • setVisible

      public void setVisible(boolean visible) throws RemoteException, VisADException
      Sets the "visible" property. This method fires a PropertyChangeEvent for VISIBLE.
      Overrides:
      setVisible in class DisplayableData
      Parameters:
      visible - Whether or not this instance should be visible.
      Throws:
      VisADException - VisAD failure.
      RemoteException - Java RMI failure.
    • toString

      public String toString()
      Provide a readable description of this LatLonLines
      Overrides:
      toString in class DisplayableData
      Returns:
      readable description