The concept of "temporary resource" has its own extension-point; looks like you can add a placeholder for an in memory grid coverage; right now I just see a single implementation for turning a FeatureType into a temporary MemoryDataStore. What would a good descriptor be in this case? Probably a GridCoverage2D (I think that is the in memory implementation of grid coverage is it not).
Cheers, Jody On Mon, Jan 12, 2009 at 1:07 AM, andrea antonello < [email protected]> wrote: > Hi Graham, > were you able to solve this? > > > I have a coverage object I've created in code by resampling an image. I > > want to place this coverage on the map as a layer. I can't seem to find > any > > examples of how to add a coverage object as a layer. I've seen this: > > > > IGeoResource resource = > > > CatalogPlugin.getDefault().getLocalCatalog().createTemporaryResource(descriptor); > > > > ApplicationGIS.addLayersToMap(map, Collections.singletonList(resource), > -1); > > > > But I don't know what descriptor is in relation to my coverage object, or > if > > this will even work for what I'm trying to do. > > I assume you could have a look at the geotiff service implementation. > In the GeoTiffServiceExtension class the service is created. > > >From a quick (very quick) look at extractId: > private URL extractID( Map<String, Serializable> params ) { > URL id; > if (params.containsKey(URL_PARAM)) { > Object param = params.get(URL_PARAM); > ... > > > it looks to me that the url should be enough. > > Humpf, now I see your point, you have an in memory thing? Is that the > real problem? > > Andrea > > > > > > > -- > > Graham Davis > > Refractions Research Inc. > > [email protected] > > > > _______________________________________________ > > User-friendly Desktop Internet GIS (uDig) > > http://udig.refractions.net > > http://lists.refractions.net/mailman/listinfo/udig-devel > > > _______________________________________________ > User-friendly Desktop Internet GIS (uDig) > http://udig.refractions.net > http://lists.refractions.net/mailman/listinfo/udig-devel >
_______________________________________________ User-friendly Desktop Internet GIS (uDig) http://udig.refractions.net http://lists.refractions.net/mailman/listinfo/udig-devel
