Inherit ArcGISTiledLayer

1155
5
06-07-2017 09:54 AM
DexterMorgan
New Contributor II

In ArcGIS 10.2.8 I was able to create a custom layer class that inherited ArcGISTiledMapServiceLayer, override the getTile(int level, int col, int row) function that returned a byte[] to create a map layer with a url and display it on my mapView. 

I'm wondering how this can be achieved in ArcGIS 100.0.0? The ArcGISTiledMapServiceLayer doesn't exist anymore and I get an error when trying to extend the ArcGISTiledLayer.

5 Replies
AlexanderNohe1
Occasional Contributor III

I imagine the team probably designed the class as final for a reason.  Is there something specific that you were trying to accomplish in the getTile function that you cannot do elsewhere? We might be able to submit an enhancement request, however, it would be good to know what you were doing in the getTile function as this would help with justification.

0 Kudos
DexterMorgan
New Contributor II

I need to get the level, row, and column integers from each Tile, the old function getTile(int level, int col, int row) provided those. I noticed in the API reference there is a class called TileInfo but I couldn't find any examples on how to use that class with ArcGISTiledLayer?

0 Kudos
AlexanderNohe1
Occasional Contributor III

Hi Dexter Morgan‌,

In update 1 we are planning on adding a WebTileLayer class which will allow you to fetch features from a url formatted this way:

"http://{subDomain}.tile.opencyclemap.org/cycle/{level}/{col}/{row}.png"

With this, new class, you can override the getTileUrl(TileKey tileKey) method in order to get the Column, Level, and Row from the tiled layer as requests are made to the service.  This should match similar functionality you were looking for in the previous release.

I hope this helps!

DexterMorgan
New Contributor II

That sounds great, do you know when the update would be available?

0 Kudos
AlexanderNohe1
Occasional Contributor III

I can't say for sure but I believe that the plan is within the next few months.

0 Kudos