Hello every body
how do i display online layer below of offline layer
Online Layer
ArcGISTiledMapServiceLayer tileLayer = new ArcGISTiledMapServiceLayer( "http://services.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer"); mMapView.addLayer(tileLayer);
Offline Layer from .geodatabase
Geodatabase geodatabase = new Geodatabase(Environment
.getExternalStorageDirectory().getPath()
+ "/ArcGIS/samples/OfflineRouting/Routing/5512.geodatabase")
;geodatabaseFeatureTablesList = geodatabase.getGeodatabaseTables();
for (int i = geodatabaseFeatureTablesList.size() - 1; i >= 0; i--) {
addLayer();
}
Edit :
Please note that I'm using Esri-android-Sdk
This works:
for (GeodatabaseFeatureTable gdbFeatureTable : localGdb .getGeodatabaseTables()) { if (gdbFeatureTable.hasGeometry()){ FeatureLayer fl = new FeatureLayer(gdbFeatureTable); mMapView.addLayer(fl);
So I guess in your example it would be
FeatureLayer fl = geodatabaseFeatureTableslist; mmapview.addLayer(fl);
is this will display layers from .geodatabase above this layer
I am not quite sure what you mean? But I am refering to your last example in the first post. The one above is online layer.
first I'm appreciate your response
let me try to do more explanation for what I wont
-------------------------------------------------------------------
I have an online layer like my comment above I add it to MapView
so can I read layers from offline .geodatabase file stored on SDcard and add it above the online layer so I can see my offline layer and out of its bound there will be an online layer
Yes, I believe it will be shown on top of your online layer if you just add it to mapview after it as a featurelayer. Is that your question?
1. Add Baselayer (streetmap as in above)
2. Add Featurelayer from geodatabase