public class LayerGroup extends Layer Fields mDisplay

protected GISDisplay mDisplay mLayerDrawIndex

protected int mLayerDrawIndex mLayerFactory

protected LayerFactory mLayerFactory mLayers

protected final List<ILayer> mLayers mOnAllLayersAddedListener

protected OnAllLayersAddedListener mOnAllLayersAddedListener Constructors LayerGroup

public LayerGroup(Context context, File path, LayerFactory layerFactory) Methods addLayer

public void addLayer(ILayer layer)

Create existed layer from path and add it to the map

  • layer – A layer object cancelDraw

public void cancelDraw() clearLayers

public void clearLayers() createLayerStorage

public File createLayerStorage(String layerName)

Create the layer folder of specified name

  • layerName – The name of folder

Path to the layer folder createLayerStorage

public File createLayerStorage()

Create the layer folder of random name

Returns:Path to the layer folder delete

public boolean delete() fromJSON

public void fromJSON(JSONObject jsonObject) getExtents

public GeoEnvelope getExtents() getLayer

public ILayer getLayer(int index) getLayerById

public ILayer getLayerById(int id)

Get layer by identificator

  • id – Layer identificator

Layer or null getLayerByName

public ILayer getLayerByName(String name)

search layer by it human readabler name

  • name – Name to search

ILayer or null getLayerByPathName

public ILayer getLayerByPathName(String name)

Search layer by it folder name

  • name – Name to search

ILayer or null getLayerCount

public int getLayerCount() getLayerFactory

public LayerFactory getLayerFactory() getLayersByType

public static void getLayersByType(LayerGroup layerGroup, int types, List<ILayer> layerList)

Get a list of specified type layers

  • layerGroup – to inspect for layers
  • types – A layer type
  • layerList – A list to fill with find layers getVectorLayersByType

public static void getVectorLayersByType(LayerGroup layerGroup, int types, List<ILayer> layerList) getVisibleLayerCount

public int getVisibleLayerCount() getVisibleTopLayerId

public int getVisibleTopLayerId() haveFeaturesNotSyncFlag

public boolean haveFeaturesNotSyncFlag() insertLayer

public void insertLayer(int index, ILayer layer) isChanges

public boolean isChanges() isVisible

public boolean isVisible() moveLayer

public void moveLayer(int newPosition, ILayer layer) onExtentChanged

protected void onExtentChanged(float zoom, GeoPoint center) onLayerAdded

protected void onLayerAdded(ILayer layer) onLayerChanged

protected void onLayerChanged(ILayer layer) onLayerDeleted

protected void onLayerDeleted(int id) onLayersReordered

protected void onLayersReordered() onUpgrade

public void onUpgrade(SQLiteDatabase sqLiteDatabase, int oldVersion, int newVersion) removeLayer

public int removeLayer(ILayer layer) runDraw

public void runDraw(GISDisplay display) save

public boolean save() setOnAllLayersAddedListener

protected void setOnAllLayersAddedListener(OnAllLayersAddedListener listener) setViewSize

public void setViewSize(int w, int h) setVisible

public void setVisible(boolean visible) toJSON

public JSONObject toJSON()