ucar.unidata.gis.maps
Class MapInfo

java.lang.Object
  extended by ucar.unidata.gis.maps.MapInfo

public class MapInfo
extends Object


Field Summary
static String ATTR_CATEGORY
          Xml attribute for the category property
static String ATTR_COLOR
          Xml attribute for the color property
static String ATTR_DESCRIPTION
          Xml attribute for the map description property
static String ATTR_FASTRENDER
          Xml attribute for the map description property
static String ATTR_LINESTYLE
          Xml attribute for the linestyle property
static String ATTR_LINEWIDTH
          Xml attribute for the linewidth property
static String ATTR_MAXVALUE
          Xml attribute for the max value property
static String ATTR_MINVALUE
          Xml attribute for the min value property
static String ATTR_POSITION
          Xml attribute for the map vertical position property
static String ATTR_SOURCE
          Xml attribute for the map source property
static String ATTR_SPACING
          Xml attribute for the spacing property
static String ATTR_VALID
          Xml attribute for the property
static String ATTR_VISIBLE
          Xml attribute for the valid property - used to ignore certain map entries
static String TAG_LATITUDE
          Xml tag for the latitude entry
static String TAG_LONGITUDE
          Xml tag for the longitude entry
static String TAG_MAP
          Xml tag for the map entry
static String TAG_MAPS
          Xml tag for the maps entry
 
Constructor Summary
MapInfo()
          Parameterless ctro for unpersistence
MapInfo(Element root)
          Create the MapInfo from the given xml
MapInfo(List mapDataList)
          Create the MapInfo object with the given MapData list
MapInfo(List mapDataList, LatLonData latData, LatLonData lonData, float mapPosition)
          Create the MapInfo object with the given MapData list, LatLonData and map position
MapInfo(XmlResourceCollection mapResources, boolean stopAfterFirst)
          Create the MapInfo from the xml files pointed to by the resource collection
MapInfo(XmlResourceCollection mapResources, boolean stopAfterFirst, boolean stopAfterEditable)
          Create the MapInfo from the xml files pointed to by the resource collection
 
Method Summary
static SampledSet createMapData(String source)
          A utility to read in the map data at the given source.
 boolean getJustLoadedLocalMaps()
          Get the Flag for just loading local maps
 LatLonData getLatData()
          Find and return the LatLonData object that represents the lat state
 List getLatLonData()
          Get the LatLonData property.
 LatLonData getLonData()
          Find and return the LatLonData object that represents the lon state
 List<MapData> getMapDataList()
          Get the MapData property.
 double getMapPosition()
          Get the vertical map position value
 String getXml()
          Return the current state (as an XML string) of this MapInfo
 String getXml(boolean useFullSourcePath)
           
 void setJustLoadedLocalMaps(boolean v)
          Set the Flag for just loading local maps
 void setLatLonData(List value)
          Set the LatLonData property.
 void setMapDataList(List value)
          Set the MapData property.
 void setMapPosition(double position)
          Set the map position
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TAG_LATITUDE

public static final String TAG_LATITUDE
Xml tag for the latitude entry

See Also:
Constant Field Values

TAG_LONGITUDE

public static final String TAG_LONGITUDE
Xml tag for the longitude entry

See Also:
Constant Field Values

TAG_MAPS

public static final String TAG_MAPS
Xml tag for the maps entry

See Also:
Constant Field Values

TAG_MAP

public static final String TAG_MAP
Xml tag for the map entry

See Also:
Constant Field Values

ATTR_COLOR

public static final String ATTR_COLOR
Xml attribute for the color property

See Also:
Constant Field Values

ATTR_CATEGORY

public static final String ATTR_CATEGORY
Xml attribute for the category property

See Also:
Constant Field Values

ATTR_DESCRIPTION

public static final String ATTR_DESCRIPTION
Xml attribute for the map description property

See Also:
Constant Field Values

ATTR_FASTRENDER

public static final String ATTR_FASTRENDER
Xml attribute for the map description property

See Also:
Constant Field Values

ATTR_LINEWIDTH

public static final String ATTR_LINEWIDTH
Xml attribute for the linewidth property

See Also:
Constant Field Values

ATTR_LINESTYLE

public static final String ATTR_LINESTYLE
Xml attribute for the linestyle property

See Also:
Constant Field Values

ATTR_MINVALUE

public static final String ATTR_MINVALUE
Xml attribute for the min value property

See Also:
Constant Field Values

ATTR_MAXVALUE

public static final String ATTR_MAXVALUE
Xml attribute for the max value property

See Also:
Constant Field Values

ATTR_POSITION

public static final String ATTR_POSITION
Xml attribute for the map vertical position property

See Also:
Constant Field Values

ATTR_SOURCE

public static final String ATTR_SOURCE
Xml attribute for the map source property

See Also:
Constant Field Values

ATTR_SPACING

public static final String ATTR_SPACING
Xml attribute for the spacing property

See Also:
Constant Field Values

ATTR_VALID

public static final String ATTR_VALID
Xml attribute for the property

See Also:
Constant Field Values

ATTR_VISIBLE

public static final String ATTR_VISIBLE
Xml attribute for the valid property - used to ignore certain map entries

See Also:
Constant Field Values
Constructor Detail

MapInfo

public MapInfo()
Parameterless ctro for unpersistence


MapInfo

public MapInfo(List mapDataList)
Create the MapInfo object with the given MapData list

Parameters:
mapDataList - List of MapData

MapInfo

public MapInfo(List mapDataList,
               LatLonData latData,
               LatLonData lonData,
               float mapPosition)
Create the MapInfo object with the given MapData list, LatLonData and map position

Parameters:
mapDataList - List of MapData
latData - The lat data
lonData - The lon data
mapPosition - The map position

MapInfo

public MapInfo(Element root)
Create the MapInfo from the given xml

Parameters:
root - The xml

MapInfo

public MapInfo(XmlResourceCollection mapResources,
               boolean stopAfterFirst)
Create the MapInfo from the xml files pointed to by the resource collection

Parameters:
mapResources - Xml resources
stopAfterFirst - Stop loading in maps after the first

MapInfo

public MapInfo(XmlResourceCollection mapResources,
               boolean stopAfterFirst,
               boolean stopAfterEditable)
Create the MapInfo from the xml files pointed to by the resource collection

Parameters:
mapResources - Xml resources
stopAfterFirst - If true then stop after we have loaded an editable resource
stopAfterEditable - If we encounter any local maps.xml file then load it in and quit the loop
Method Detail

getXml

public String getXml()
Return the current state (as an XML string) of this MapInfo

Returns:
The xml representation of the current state

getXml

public String getXml(boolean useFullSourcePath)

getMapPosition

public double getMapPosition()
Get the vertical map position value

Returns:
map position value

setMapPosition

public void setMapPosition(double position)
Set the map position

Parameters:
position - The position

createMapData

public static SampledSet createMapData(String source)
A utility to read in the map data at the given source.

Parameters:
source - The fil, url or java resource to a map file (mcidas or shp)
Returns:
The data or null if this fails.

setLatLonData

public void setLatLonData(List value)
Set the LatLonData property.

Parameters:
value - The new value for LatLonData

getLatLonData

public List getLatLonData()
Get the LatLonData property.

Returns:
The LatLonData

setMapDataList

public void setMapDataList(List value)
Set the MapData property.

Parameters:
value - The new value for MapData

getMapDataList

public List<MapData> getMapDataList()
Get the MapData property.

Returns:
The MapData

getLatData

public LatLonData getLatData()
Find and return the LatLonData object that represents the lat state

Returns:
The lat state

getLonData

public LatLonData getLonData()
Find and return the LatLonData object that represents the lon state

Returns:
The lon state

getJustLoadedLocalMaps

public boolean getJustLoadedLocalMaps()
Get the Flag for just loading local maps

Returns:
the flag

setJustLoadedLocalMaps

public void setJustLoadedLocalMaps(boolean v)
Set the Flag for just loading local maps

Parameters:
v - the flag