Changeset 3569 for TI05-delivery


Ignore:
Timestamp:
07/03/08 16:49:21 (11 years ago)
Author:
spascoe
Message:

Slight changing to caching code. tweeking capabilities to test
compatibility with mapClient.

Location:
TI05-delivery/ows_framework/branches/ows_framework-refactor/ows_common/ows_common/pylons
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • TI05-delivery/ows_framework/branches/ows_framework-refactor/ows_common/ows_common/pylons/templates/wms_capabilities_1_1_1.xml

    r3563 r3569  
    6666               name="${d_n}" units="${d.valuesUnit}" 
    6767               unitSymbol="${d.unitSymbol}"/> 
    68     <Extent py:for="d_n, d in ds.dimensions.iteritems()" name="${d_n}" default="${d.defaultValue}" nearestValue="${int(d.nearestValue)}" 
     68    <Extent py:for="d_n, d in ds.dimensions.iteritems()" name="${d_n}" default="${d.defaultValue}"  
    6969            py:content="','.join(d.possibleValues.allowedValues)"/> 
     70<!--! nearestValue="${int(d.nearestValue)}" --> 
    7071 
    7172  </Layer> 
  • TI05-delivery/ows_framework/branches/ows_framework-refactor/ows_common/ows_common/pylons/wms_controller.py

    r3561 r3569  
    153153        # Find the slab in the cache first 
    154154        cacheKey = layerObj.getCacheKey(srs, dimValues) 
    155         try: 
    156             slab = self._layerSlabCache[cacheKey] 
    157         except KeyError: 
     155 
     156        slab = self._layerSlabCache.get(cacheKey) 
     157        if slab is None: 
    158158            slab = layerObj.getSlab(srs, dimValues, dict(minValue=0, maxValue=100)) 
    159             self._layerSlabCache[cacheKey] = slab 
     159            if cacheKey is not None: 
     160                self._layerSlabCache[cacheKey] = slab 
    160161 
    161162        # We must request a bbox within the layer's bbox. 
Note: See TracChangeset for help on using the changeset viewer.