[ka-Map-dev] New Cache structure

Paul Spencer pspencer at dmsolutions.ca
Fri Jun 22 13:03:43 EDT 2007


Pablo,

what is the purpose of changing the cache structure.  Your changes  
look okay at first glance, but there may be a way to achieve what you  
are trying to do without modifying ka-Map.

Cheers

Paul

On 21-Jun-07, at 3:01 AM, Pablo Martínez Pérez wrote:

> Hi,
>
> I need for my kaMaps applications a new cache structure.
> This is what I make:
>
> Objetive:
>
> 	- Make cache available for different kaMap applications.
> 	- New cache directory structure:
>
> 		[cache_dir]/[layer]/[scales]
>
> 		example of new cache dir:
>
> 		/cache/raster_2007/80000/def/...
> 		/cache/rivers/30000/def/...
>
> Implementation:
>
>
> - Config.php:
>
> //$szMapCacheDir = $szBaseCacheDir.$szMap;
> $szMapCacheDir = $szBaseCacheDir;
>
>
>
> - Tile.php:
>
> //$szCacheDir = $szMapCacheDir."/".$scale."/".$szGroupDir."/". 
> $szLayerDir."/".$szMetaTileId;
>
> $oMap = ms_newMapObj($szMapFile);
> $aLayersIdx = $oMap->getLayersIndexByGroup($groups);
> $oLayer = $oMap->getLayer($aLayersIdx[0]);
>
> $szMetaGroupDir = $oLayer->getMetaData('tile_folder');
> $szCacheDir = $szMapCacheDir."/".$szMetaGroupDir."/".$scale."/". 
> $szMetaTileId;
>
> ...
>
> //$oMap = ms_newMapObj($szMapFile);
>
>
> - MAP FILE:
>
> METADATA
> 	"tile_folder"  "[directory]"    ->   "tile_folder" "raster_2007"
> END
>
>
> Its all ok?
> I need your opinion.
>
>
>
> -------------------
> Pablo Martínez
>
>
>
>
>
> _______________________________________________
> ka-Map-dev mailing list
> ka-Map-dev at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/ka-map-dev

+-----------------------------------------------------------------+
|Paul Spencer                          pspencer at dmsolutions.ca    |
+-----------------------------------------------------------------+
|Chief Technology Officer                                         |
|DM Solutions Group Inc                http://www.dmsolutions.ca/ |
+-----------------------------------------------------------------+








More information about the ka-Map-dev mailing list