ucar.unidata.idv.control
Class MapDisplayControl.MapState

java.lang.Object
  extended by ucar.unidata.gis.maps.MapData
      extended by ucar.unidata.idv.control.MapDisplayControl.MapState
Enclosing class:
MapDisplayControl

public static class MapDisplayControl.MapState
extends MapData

This class holds the state associated with a given map


Field Summary
 
Fields inherited from class ucar.unidata.gis.maps.MapData
category, description, fastRendering, lineStyle, lineWidth, mapColor, myMap, source, spacing, visible
 
Constructor Summary
MapDisplayControl.MapState()
          ctor for persistence
MapDisplayControl.MapState(MapData that)
          ctor for instantiating from a MapData
MapDisplayControl.MapState(String mapPath, String description, Color mapColor, float lineWidth, int lineStyle)
          Construct this MapState.
 
Method Summary
protected  void checkVisibility()
          Take into account the visibility of the display control
 boolean init(MapDisplayControl mapDisplayControl)
          Initialize the map.
protected  void stateChanged()
          A method that allows derived classes to be told when the state has changed.
 
Methods inherited from class ucar.unidata.gis.maps.MapData
equals, getCategory, getColor, getDescription, getFastRendering, getLineStyle, getLineWidth, getMap, getSource, getSpacing, getVisible, hashCode, setCategory, setColor, setDescription, setFastRendering, setLineStyle, setLineWidth, setSource, setSpacing, setVisible, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MapDisplayControl.MapState

public MapDisplayControl.MapState()
ctor for persistence


MapDisplayControl.MapState

public MapDisplayControl.MapState(MapData that)
ctor for instantiating from a MapData

Parameters:
that - The MapData to copy from

MapDisplayControl.MapState

public MapDisplayControl.MapState(String mapPath,
                                  String description,
                                  Color mapColor,
                                  float lineWidth,
                                  int lineStyle)
Construct this MapState.

Parameters:
mapPath - File path, resource path or url of the map file.
description - Map description
mapColor - The initial color to use
lineWidth - The initial line width to use
lineStyle - The initial line style to use
Method Detail

checkVisibility

protected void checkVisibility()
Take into account the visibility of the display control


init

public boolean init(MapDisplayControl mapDisplayControl)
Initialize the map.

Parameters:
mapDisplayControl - The display control we are part of
Returns:
true if everything ok. False otherwise. If a problem this method will signal the user.

stateChanged

protected void stateChanged()
A method that allows derived classes to be told when the state has changed.

Overrides:
stateChanged in class MapData