twaver.gis
Class GisNetworkAdapter

java.lang.Object
  extended bytwaver.gis.GisNetworkAdapter

public class GisNetworkAdapter
extends java.lang.Object

This class helps wrap a TNetowrk object(network) with a geographical map. After installAdapter() or installAdapter(int) is invoked, all the TWaver elements stored in network's databox can be located by their geographical coordinate automatically.


Constructor Summary
GisNetworkAdapter(twaver.network.TNetwork network)
           
 
Method Summary
 GeographyMap getMap()
          Gets the map used as the background of the network.
 void installAdapter()
          Wraps the network by setting a map as the background of the network and setting the mechanism used to synchronize the topological datas and the geographical datas.
 void installAdapter(int mapType)
          Wraps the network by setting a map as the background of the network and setting the mechanism used to synchronize the topological data and the geographical data.
 void unInstallAdapter()
          UnWraps the network.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GisNetworkAdapter

public GisNetworkAdapter(twaver.network.TNetwork network)
Method Detail

getMap

public GeographyMap getMap()
Gets the map used as the background of the network.

Returns:
the map object used as the background

unInstallAdapter

public void unInstallAdapter()
UnWraps the network. Removes the map and some event listeners from the network.


installAdapter

public void installAdapter()
Wraps the network by setting a map as the background of the network and setting the mechanism used to synchronize the topological datas and the geographical datas.


installAdapter

public void installAdapter(int mapType)
Wraps the network by setting a map as the background of the network and setting the mechanism used to synchronize the topological data and the geographical data.

Parameters:
mapType - specified the type of the map.
See Also:
GeographyMap.GEOGRAPHYMAP_TYPE_SHPFILE, GeographyMap.GEOGRAPHYMAP_TYPE_TILE