AnsweredAssumed Answered

ArcGISvectorTileLayer: What's an ItemResourceCache and how do I make one?

Question asked by Crittermap on May 30, 2018

One of the constructors for ArcGISVectorTiledLayer takes a vectorTileCache.

I'm hoping this one will let me specify a style for the vtpk without recreating an entire vtpk.

public ArcGISVectorTiledLayer (VectorTileCache vectorTileCache, ItemResourceCache itemResourceCache)

Creates a new ArcGISVectorTiledLayer from the specified VectorTileCache and ItemResourceCache objects. If itemResourceCache is null, it is equivalent to the constructor ArcGISVectorTiledLayer(VectorTileCache)

Parameters
vectorTileCachethe vector tile cache to use
itemResourceCachethe vector tile style to use
Throws
IllegalArgumentExceptionif vectorTileCache is null.

 

 

 

ItemResourceCache(String path)
Constructs an ItemResourceCache with absolute path to a directory containing item resources.

So how is the directory structured?

 

My best guess so far:

If I unzip a .vtpk, one of the folders inside is called p2/resources

Inside that folder there is:

fonts

info

sprites

styles

root.json.

 

Is this the structure I need to recreate?

 

Since there are no examples nor documentation on this, I though it was worth asking.

Outcomes