Wrapper implementation of QNetworkDiskCache with all methods guarded by a mutex solely for internal use of QgsNetworkAccessManagers.
More...
#include <qgsnetworkdiskcache.h>
|
| static qint64 | smartCacheSize (const QString &path) |
| | Returns a smart cache size, in bytes, based on available free space.
|
Wrapper implementation of QNetworkDiskCache with all methods guarded by a mutex solely for internal use of QgsNetworkAccessManagers.
- Note
- not available in Python bindings
Definition at line 53 of file qgsnetworkdiskcache.h.
◆ cacheDirectory()
| QString QgsNetworkDiskCache::cacheDirectory |
( |
| ) |
const |
◆ cacheSize()
| qint64 QgsNetworkDiskCache::cacheSize |
( |
| ) |
const |
|
override |
◆ clear
| void QgsNetworkDiskCache::clear |
( |
| ) |
|
|
overrideslot |
◆ data()
| QIODevice * QgsNetworkDiskCache::data |
( |
const QUrl & | url | ) |
|
|
override |
◆ expire()
| qint64 QgsNetworkDiskCache::expire |
( |
| ) |
|
|
overrideprotected |
◆ fileMetaData()
| QNetworkCacheMetaData QgsNetworkDiskCache::fileMetaData |
( |
const QString & | fileName | ) |
const |
◆ hasInvalidMatchForRequest()
| bool QgsNetworkDiskCache::hasInvalidMatchForRequest |
( |
const QNetworkRequest & | request | ) |
|
Returns true if the cache has a matching but invalid entry for a request.
Since QNetworkDiskCache entirely basis cache storage on URLs alone, we may get situations where there's a match for a URL in the cache but it should NOT be used for the specified request (e.g. when the previous response had a non-matching "Vary" attribute).
If this method returns false, then the request should be amended to prevent potential false-positive retrieval from cache.
This method is thread-safe.
Definition at line 58 of file qgsnetworkdiskcache.cpp.
◆ hasPendingRequestForUrl()
| bool QgsNetworkDiskCache::hasPendingRequestForUrl |
( |
const QUrl & | url | ) |
const |
◆ insert()
| void QgsNetworkDiskCache::insert |
( |
QIODevice * | device | ) |
|
|
override |
◆ insertPendingRequestHeaders()
| void QgsNetworkDiskCache::insertPendingRequestHeaders |
( |
const QUrl & | url, |
|
|
const QVariantMap & | headers ) |
◆ maximumCacheSize()
| qint64 QgsNetworkDiskCache::maximumCacheSize |
( |
| ) |
const |
◆ metaData()
| QNetworkCacheMetaData QgsNetworkDiskCache::metaData |
( |
const QUrl & | url | ) |
|
|
override |
◆ prepare()
| QIODevice * QgsNetworkDiskCache::prepare |
( |
const QNetworkCacheMetaData & | metaData | ) |
|
|
override |
◆ remove()
| bool QgsNetworkDiskCache::remove |
( |
const QUrl & | url | ) |
|
|
override |
◆ removePendingRequestForUrl()
| void QgsNetworkDiskCache::removePendingRequestForUrl |
( |
const QUrl & | url | ) |
const |
◆ setCacheDirectory()
| void QgsNetworkDiskCache::setCacheDirectory |
( |
const QString & | cacheDir | ) |
|
◆ setMaximumCacheSize()
| void QgsNetworkDiskCache::setMaximumCacheSize |
( |
qint64 | size | ) |
|
◆ smartCacheSize()
| qint64 QgsNetworkDiskCache::smartCacheSize |
( |
const QString & | path | ) |
|
|
static |
Returns a smart cache size, in bytes, based on available free space.
- Since
- QGIS 3.40
Definition at line 275 of file qgsnetworkdiskcache.cpp.
◆ updateMetaData()
| void QgsNetworkDiskCache::updateMetaData |
( |
const QNetworkCacheMetaData & | metaData | ) |
|
|
override |
◆ QgsNetworkAccessManager
The documentation for this class was generated from the following files: