//////////////////////////////////////////////////////////////////////////// //--------------------------------- REVISIONS ------------------------------ // Date Name Tracking # Description // --------- ------------------- ------------- ---------------------- // 18JUN2009 James Shen Initial Creation //////////////////////////////////////////////////////////////////////////// /** * Add a map layer to the tail of the container. * @param mapLayer */ public void AddMapLayer(MapLayer mapLayer) { lock (_mapLayers) { if (!_mapLayers.Contains(mapLayer)) { _mapLayers.Add(mapLayer); } } }
//////////////////////////////////////////////////////////////////////////// //--------------------------------- REVISIONS ------------------------------ // Date Name Tracking # Description // --------- ------------------- ------------- ---------------------- // 18JUN2009 James Shen Initial Creation //////////////////////////////////////////////////////////////////////////// /** * Get all map layers as an array. * @return all map layers included in this container. */ public MapLayer[] GetMapLayers() { lock (_mapLayers) { MapLayer[] retArray = new MapLayer[_mapLayers.Count]; _mapLayers.CopyTo(retArray); return retArray; } }
//////////////////////////////////////////////////////////////////////////// //--------------------------------- REVISIONS ------------------------------ // Date Name Tracking # Description // --------- ------------------- ------------- ---------------------- // 18JUN2009 James Shen Initial Creation //////////////////////////////////////////////////////////////////////////// /** * remove a givne map layer from the container. * @param mapLayer */ public void RemoveMapLayer(MapLayer mapLayer) { lock (_mapLayers) { _mapLayers.Remove(mapLayer); } }
//////////////////////////////////////////////////////////////////////////// //--------------------------------- REVISIONS ------------------------------ // Date Name Tracking # Description // --------- ------------------- ------------- ---------------------- // 18JUN2009 James Shen Initial Creation //////////////////////////////////////////////////////////////////////////// /** * Add a map layer after given index * @param index the index after which a new map layer is added * @param mapLayer a map layer inserted into the container */ public void AddMapLayerAt(int index, MapLayer mapLayer) { lock (_mapLayers) { _mapLayers.Insert(index, mapLayer); } }