28 if ( copy.mPluginsServerCaches )
34 mPluginsServerCaches.reset(
nullptr );
40 if ( copy.mPluginsServerCaches )
46 mPluginsServerCaches.reset(
nullptr );
53 mPluginsServerCaches.reset();
59 QString key = getCacheKey( cache, accessControl );
67 QgsServerCacheFilterMap::const_iterator scIterator;
68 for ( scIterator = mPluginsServerCaches->constBegin(); scIterator != mPluginsServerCaches->constEnd(); ++scIterator )
70 content = scIterator.value()->getCachedDocument( project, request, key );
71 if ( !content.isEmpty() )
76 if ( content.isEmpty() )
81 if ( !doc->setContent( content ) )
92 QString key = getCacheKey( cache, accessControl );
99 QgsServerCacheFilterMap::const_iterator scIterator;
100 for ( scIterator = mPluginsServerCaches->constBegin(); scIterator != mPluginsServerCaches->constEnd(); ++scIterator )
102 if ( scIterator.value()->setCachedDocument( doc, project, request, key ) )
113 QString key = getCacheKey( cache, accessControl );
115 QgsServerCacheFilterMap::const_iterator scIterator;
116 for ( scIterator = mPluginsServerCaches->constBegin(); scIterator != mPluginsServerCaches->constEnd(); ++scIterator )
118 if ( scIterator.value()->deleteCachedDocument( project, request, key ) )
128 QgsServerCacheFilterMap::const_iterator scIterator;
129 for ( scIterator = mPluginsServerCaches->constBegin(); scIterator != mPluginsServerCaches->constEnd(); ++scIterator )
131 if ( scIterator.value()->deleteCachedDocuments( project ) )
142 QString key = getCacheKey( cache, accessControl );
144 QgsServerCacheFilterMap::const_iterator scIterator;
145 for ( scIterator = mPluginsServerCaches->constBegin(); scIterator != mPluginsServerCaches->constEnd(); ++scIterator )
147 QByteArray content = scIterator.value()->getCachedImage( project, request, key );
148 if ( !content.isEmpty() )
159 QString key = getCacheKey( cache, accessControl );
161 QgsServerCacheFilterMap::const_iterator scIterator;
162 for ( scIterator = mPluginsServerCaches->constBegin(); scIterator != mPluginsServerCaches->constEnd(); ++scIterator )
164 if ( scIterator.value()->setCachedImage( img, project, request, key ) )
175 QString key = getCacheKey( cache, accessControl );
177 QgsServerCacheFilterMap::const_iterator scIterator;
178 for ( scIterator = mPluginsServerCaches->constBegin(); scIterator != mPluginsServerCaches->constEnd(); ++scIterator )
180 if ( scIterator.value()->deleteCachedImage( project, request, key ) )
190 QgsServerCacheFilterMap::const_iterator scIterator;
191 for ( scIterator = mPluginsServerCaches->constBegin(); scIterator != mPluginsServerCaches->constEnd(); ++scIterator )
193 if ( scIterator.value()->deleteCachedImages( project ) )
203 mPluginsServerCaches->insert( priority, serverCache );
206 QString QgsServerCacheManager::getCacheKey(
bool &cache,
QgsAccessControl *accessControl )
const
208 QStringList cacheKeyList;
217 return cacheKeyList.join(
'-' );