
We bake cookies in your browser for a better experience. Using this site means that you consent.Read More
TheQNetworkCacheMetaData class provides cache information.More...
| Header: | #include <QNetworkCacheMetaData> |
| Since: | Qt 4.5 |
| typedef | AttributesMap |
| typedef | RawHeader |
| typedef | RawHeaderList |
| QNetworkCacheMetaData() | |
| QNetworkCacheMetaData(const QNetworkCacheMetaData & other) | |
| ~QNetworkCacheMetaData() | |
| AttributesMap | attributes() const |
| QDateTime | expirationDate() const |
| bool | isValid() const |
| QDateTime | lastModified() const |
| RawHeaderList | rawHeaders() const |
| bool | saveToDisk() const |
| void | setAttributes(const AttributesMap & attributes) |
| void | setExpirationDate(const QDateTime & dateTime) |
| void | setLastModified(const QDateTime & dateTime) |
| void | setRawHeaders(const RawHeaderList & list) |
| void | setSaveToDisk(bool allow) |
| void | setUrl(const QUrl & url) |
| QUrl | url() const |
| bool | operator!=(const QNetworkCacheMetaData & other) const |
| QNetworkCacheMetaData & | operator=(const QNetworkCacheMetaData & other) |
| bool | operator==(const QNetworkCacheMetaData & other) const |
| QDataStream & | operator<<(QDataStream & out, const QNetworkCacheMetaData & metaData) |
| QDataStream & | operator>>(QDataStream & in, QNetworkCacheMetaData & metaData) |
TheQNetworkCacheMetaData class provides cache information.
QNetworkCacheMetaData provides information about a cache file including the url, when it was last modified, when the cache file was created, headers for file and if the file should be saved onto a disk.
See alsoQAbstractNetworkCache.
Synonym forQHash<QNetworkRequest::Attribute,QVariant>
Synonym forQPair<QByteArray,QByteArray>
Constructs an invalid network cache meta data.
See alsoisValid().
Constructs a copy of theotherQNetworkCacheMetaData.
Destroys the network cache meta data.
Returns all the attributes stored with this cache item.
This function was introduced in Qt 4.6.
See alsosetAttributes() andQNetworkRequest::Attribute.
Returns the date and time when the meta data expires.
See alsosetExpirationDate().
Returns true if this network cache meta data has attributes that have been set otherwise false.
Returns the date and time when the meta data was last modified.
See alsosetLastModified().
Returns a list of all raw headers that are set in this meta data. The list is in the same order that the headers were set.
See alsosetRawHeaders().
Returns is this cache should be allowed to be stored on disk.
Some cache implementations can keep these cache items in memory for performance reasons, but for security reasons they should not be written to disk.
Specifically with http, documents marked with Pragma: no-cache, or have a Cache-control set to no-store or no-cache or any https document that doesn't have "Cache-control: public" set will set the saveToDisk to false.
See alsosetSaveToDisk().
Sets all attributes of this cache item to be the mapattributes.
This function was introduced in Qt 4.6.
See alsoattributes() andQNetworkRequest::setAttribute().
Sets the date and time when the meta data expires todateTime.
See alsoexpirationDate().
Sets the date and time when the meta data was last modified todateTime.
See alsolastModified().
Sets the raw headers tolist.
See alsorawHeaders().
Sets whether this network cache meta data and associated content should be allowed to be stored on disk toallow.
See alsosaveToDisk().
Sets the URL this network cache meta data to to beurl.
The password and fragment are removed from the url.
See alsourl().
Returns the URL this network cache meta data is referring to.
See alsosetUrl().
Returns true if this meta data is not equal to theother meta data; otherwise returns false.
See alsooperator==().
Makes a copy of theotherQNetworkCacheMetaData and returns a reference to the copy.
Returns true if this meta data is equal to theother meta data; otherwise returns false.
See alsooperator!=().
WritesmetaData to theout stream.
This function was introduced in Qt 4.5.
See alsoSerializing Qt Data Types.
Reads aQNetworkCacheMetaData from the streamin intometaData.
This function was introduced in Qt 4.5.
See alsoSerializing Qt Data Types.
© 2016 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of theGNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.