Qt 4.8
Public Functions | Static Public Functions | Public Variables | List of all members
QNetworkCacheMetaDataPrivate Class Reference
Inheritance diagram for QNetworkCacheMetaDataPrivate:
QSharedData

Public Functions

bool operator== (const QNetworkCacheMetaDataPrivate &other) const
 
 QNetworkCacheMetaDataPrivate ()
 
- Public Functions inherited from QSharedData
 QSharedData ()
 Constructs a QSharedData object with a reference count of 0. More...
 
 QSharedData (const QSharedData &)
 Constructs a QSharedData object with reference count 0. More...
 

Static Public Functions

static void load (QDataStream &in, QNetworkCacheMetaData &metaData)
 
static void save (QDataStream &out, const QNetworkCacheMetaData &metaData)
 

Public Variables

QNetworkCacheMetaData::AttributesMap attributes
 
QDateTime expirationDate
 
QNetworkCacheMetaData::RawHeaderList headers
 
QDateTime lastModified
 
bool saveToDisk
 
QUrl url
 
- Public Variables inherited from QSharedData
QAtomicInt ref
 

Detailed Description

Definition at line 52 of file qabstractnetworkcache.cpp.

Constructors and Destructors

◆ QNetworkCacheMetaDataPrivate()

QNetworkCacheMetaDataPrivate::QNetworkCacheMetaDataPrivate ( )
inline

Definition at line 56 of file qabstractnetworkcache.cpp.

57  : QSharedData()
58  , saveToDisk(true)
59  {}
QSharedData()
Constructs a QSharedData object with a reference count of 0.
Definition: qshareddata.h:61

Functions

◆ load()

void QNetworkCacheMetaDataPrivate::load ( QDataStream in,
QNetworkCacheMetaData metaData 
)
static

Definition at line 406 of file qabstractnetworkcache.cpp.

Referenced by QNetworkCacheMetaData::operator>>().

407 {
408  in >> metaData.d->url;
409  in >> metaData.d->expirationDate;
410  in >> metaData.d->lastModified;
411  in >> metaData.d->saveToDisk;
412  in >> metaData.d->attributes;
413  in >> metaData.d->headers;
414 }
QSharedDataPointer< QNetworkCacheMetaDataPrivate > d
QNetworkCacheMetaData::AttributesMap attributes
QNetworkCacheMetaData::RawHeaderList headers

◆ operator==()

bool QNetworkCacheMetaDataPrivate::operator== ( const QNetworkCacheMetaDataPrivate other) const
inline

Definition at line 61 of file qabstractnetworkcache.cpp.

62  {
63  return
64  url == other.url
65  && lastModified == other.lastModified
66  && expirationDate == other.expirationDate
67  && headers == other.headers
68  && saveToDisk == other.saveToDisk;
69  }
QNetworkCacheMetaData::RawHeaderList headers

◆ save()

void QNetworkCacheMetaDataPrivate::save ( QDataStream out,
const QNetworkCacheMetaData metaData 
)
static

Definition at line 350 of file qabstractnetworkcache.cpp.

Referenced by QNetworkCacheMetaData::operator<<().

351 {
352  // note: if you change the contents of the meta data here
353  // remember to bump the cache version in qnetworkdiskcache.cpp CurrentCacheVersion
354  out << metaData.url();
355  out << metaData.expirationDate();
356  out << metaData.lastModified();
357  out << metaData.saveToDisk();
358  out << metaData.attributes();
359  out << metaData.rawHeaders();
360 }
QDateTime expirationDate() const
Returns the date and time when the meta data expires.
QUrl url() const
Returns the URL this network cache meta data is referring to.
RawHeaderList rawHeaders() const
Returns a list of all raw headers that are set in this meta data.
QDateTime lastModified() const
Returns the date and time when the meta data was last modified.
AttributesMap attributes() const
Returns all the attributes stored with this cache item.
bool saveToDisk() const
Returns is this cache should be allowed to be stored on disk.

Properties

◆ attributes

QNetworkCacheMetaData::AttributesMap QNetworkCacheMetaDataPrivate::attributes

◆ expirationDate

QDateTime QNetworkCacheMetaDataPrivate::expirationDate

◆ headers

QNetworkCacheMetaData::RawHeaderList QNetworkCacheMetaDataPrivate::headers

◆ lastModified

QDateTime QNetworkCacheMetaDataPrivate::lastModified

◆ saveToDisk

bool QNetworkCacheMetaDataPrivate::saveToDisk

◆ url

QUrl QNetworkCacheMetaDataPrivate::url

The documentation for this class was generated from the following file: