1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242
|
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_US" lang="en_US">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- qabstractnetworkcache.cpp -->
<title>Qt 4.8: QNetworkCacheMetaData Class Reference</title>
<link rel="stylesheet" type="text/css" href="style/offline.css" />
</head>
<body>
<div class="header" id="qtdocheader">
<div class="content">
<a href="index.html" class="qtref"><span>Qt Reference Documentation</span></a>
</div>
<div class="breadcrumb toolblock">
<ul>
<li class="first"><a href="index.html">Home</a></li>
<!-- Breadcrumbs go here -->
<li><a href="modules.html">Modules</a></li>
<li><a href="qtnetwork.html">QtNetwork</a></li>
<li>QNetworkCacheMetaData</li>
</ul>
</div>
</div>
<div class="content mainContent">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<li class="level1"><a href="#public-types">Public Types</a></li>
<li class="level1"><a href="#public-functions">Public Functions</a></li>
<li class="level1"><a href="#related-non-members">Related Non-Members</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
</ul>
</div>
<h1 class="title">QNetworkCacheMetaData Class Reference</h1>
<!-- $$$QNetworkCacheMetaData-brief -->
<p>The QNetworkCacheMetaData class provides cache information. <a href="#details">More...</a></p>
<!-- @@@QNetworkCacheMetaData -->
<pre class="cpp"> <span class="preprocessor">#include <QNetworkCacheMetaData></span></pre><p>This class was introduced in Qt 4.5.</p>
<ul>
<li><a href="qnetworkcachemetadata-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="public-types"></a>
<h2>Public Types</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> typedef </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#AttributesMap-typedef">AttributesMap</a></b></td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> typedef </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#RawHeader-typedef">RawHeader</a></b></td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> typedef </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#RawHeaderList-typedef">RawHeaderList</a></b></td></tr>
</table>
<a name="public-functions"></a>
<h2>Public Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#QNetworkCacheMetaData">QNetworkCacheMetaData</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#QNetworkCacheMetaData-2">QNetworkCacheMetaData</a></b> ( const QNetworkCacheMetaData & <i>other</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#dtor.QNetworkCacheMetaData">~QNetworkCacheMetaData</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> AttributesMap </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#attributes">attributes</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QDateTime </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#expirationDate">expirationDate</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#isValid">isValid</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QDateTime </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#lastModified">lastModified</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> RawHeaderList </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#rawHeaders">rawHeaders</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#saveToDisk">saveToDisk</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#setAttributes">setAttributes</a></b> ( const AttributesMap & <i>attributes</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#setExpirationDate">setExpirationDate</a></b> ( const QDateTime & <i>dateTime</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#setLastModified">setLastModified</a></b> ( const QDateTime & <i>dateTime</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#setRawHeaders">setRawHeaders</a></b> ( const RawHeaderList & <i>list</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#setSaveToDisk">setSaveToDisk</a></b> ( bool <i>allow</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#setUrl">setUrl</a></b> ( const QUrl & <i>url</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QUrl </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#url">url</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#operator-not-eq">operator!=</a></b> ( const QNetworkCacheMetaData & <i>other</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QNetworkCacheMetaData & </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#operator-eq">operator=</a></b> ( const QNetworkCacheMetaData & <i>other</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#operator-eq-eq">operator==</a></b> ( const QNetworkCacheMetaData & <i>other</i> ) const</td></tr>
</table>
<a name="related-non-members"></a>
<h2>Related Non-Members</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> QDataStream & </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#operator-lt-lt-85">operator<<</a></b> ( QDataStream & <i>out</i>, const QNetworkCacheMetaData & <i>metaData</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QDataStream & </td><td class="memItemRight bottomAlign"><b><a href="qnetworkcachemetadata.html#operator-gt-gt-44">operator>></a></b> ( QDataStream & <i>in</i>, QNetworkCacheMetaData & <i>metaData</i> )</td></tr>
</table>
<a name="details"></a>
<!-- $$$QNetworkCacheMetaData-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The QNetworkCacheMetaData class provides cache information.</p>
<p>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.</p>
</div>
<p><b>See also </b><a href="qabstractnetworkcache.html">QAbstractNetworkCache</a>.</p>
<!-- @@@QNetworkCacheMetaData -->
<div class="types">
<h2>Member Type Documentation</h2>
<!-- $$$AttributesMap -->
<h3 class="fn"><a name="AttributesMap-typedef"></a>typedef QNetworkCacheMetaData::<span class="name">AttributesMap</span></h3>
<p>Synonym for <a href="qhash.html">QHash</a><<a href="qnetworkrequest.html#Attribute-enum">QNetworkRequest::Attribute</a>, <a href="qvariant.html">QVariant</a>></p>
<!-- @@@AttributesMap -->
<!-- $$$RawHeader -->
<h3 class="fn"><a name="RawHeader-typedef"></a>typedef QNetworkCacheMetaData::<span class="name">RawHeader</span></h3>
<p>Synonym for <a href="qpair.html">QPair</a><<a href="qbytearray.html">QByteArray</a>, <a href="qbytearray.html">QByteArray</a>></p>
<!-- @@@RawHeader -->
<!-- $$$RawHeaderList -->
<h3 class="fn"><a name="RawHeaderList-typedef"></a>typedef QNetworkCacheMetaData::<span class="name">RawHeaderList</span></h3>
<p>Synonym for <a href="qlist.html">QList</a><<a href="qnetworkcachemetadata.html#RawHeader-typedef">RawHeader</a>></p>
<!-- @@@RawHeaderList -->
</div>
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$QNetworkCacheMetaData[overload1]$$$QNetworkCacheMetaData -->
<h3 class="fn"><a name="QNetworkCacheMetaData"></a>QNetworkCacheMetaData::<span class="name">QNetworkCacheMetaData</span> ()</h3>
<p>Constructs an invalid network cache meta data.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#isValid">isValid</a>().</p>
<!-- @@@QNetworkCacheMetaData -->
<!-- $$$QNetworkCacheMetaData$$$QNetworkCacheMetaDataconstQNetworkCacheMetaData& -->
<h3 class="fn"><a name="QNetworkCacheMetaData-2"></a>QNetworkCacheMetaData::<span class="name">QNetworkCacheMetaData</span> ( const <span class="type">QNetworkCacheMetaData</span> & <i>other</i> )</h3>
<p>Constructs a copy of the <i>other</i> <a href="qnetworkcachemetadata.html">QNetworkCacheMetaData</a>.</p>
<!-- @@@QNetworkCacheMetaData -->
<!-- $$$~QNetworkCacheMetaData[overload1]$$$~QNetworkCacheMetaData -->
<h3 class="fn"><a name="dtor.QNetworkCacheMetaData"></a>QNetworkCacheMetaData::<span class="name">~QNetworkCacheMetaData</span> ()</h3>
<p>Destroys the network cache meta data.</p>
<!-- @@@~QNetworkCacheMetaData -->
<!-- $$$attributes[overload1]$$$attributes -->
<h3 class="fn"><a name="attributes"></a><span class="type"><a href="qnetworkcachemetadata.html#AttributesMap-typedef">AttributesMap</a></span> QNetworkCacheMetaData::<span class="name">attributes</span> () const</h3>
<p>Returns all the attributes stored with this cache item.</p>
<p>This function was introduced in Qt 4.6.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#setAttributes">setAttributes</a>() and <a href="qnetworkrequest.html#Attribute-enum">QNetworkRequest::Attribute</a>.</p>
<!-- @@@attributes -->
<!-- $$$expirationDate[overload1]$$$expirationDate -->
<h3 class="fn"><a name="expirationDate"></a><span class="type"><a href="qdatetime.html">QDateTime</a></span> QNetworkCacheMetaData::<span class="name">expirationDate</span> () const</h3>
<p>Returns the date and time when the meta data expires.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#setExpirationDate">setExpirationDate</a>().</p>
<!-- @@@expirationDate -->
<!-- $$$isValid[overload1]$$$isValid -->
<h3 class="fn"><a name="isValid"></a><span class="type">bool</span> QNetworkCacheMetaData::<span class="name">isValid</span> () const</h3>
<p>Returns true if this network cache meta data has attributes that have been set otherwise false.</p>
<!-- @@@isValid -->
<!-- $$$lastModified[overload1]$$$lastModified -->
<h3 class="fn"><a name="lastModified"></a><span class="type"><a href="qdatetime.html">QDateTime</a></span> QNetworkCacheMetaData::<span class="name">lastModified</span> () const</h3>
<p>Returns the date and time when the meta data was last modified.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#setLastModified">setLastModified</a>().</p>
<!-- @@@lastModified -->
<!-- $$$rawHeaders[overload1]$$$rawHeaders -->
<h3 class="fn"><a name="rawHeaders"></a><span class="type"><a href="qnetworkcachemetadata.html#RawHeaderList-typedef">RawHeaderList</a></span> QNetworkCacheMetaData::<span class="name">rawHeaders</span> () const</h3>
<p>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.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#setRawHeaders">setRawHeaders</a>().</p>
<!-- @@@rawHeaders -->
<!-- $$$saveToDisk[overload1]$$$saveToDisk -->
<h3 class="fn"><a name="saveToDisk"></a><span class="type">bool</span> QNetworkCacheMetaData::<span class="name">saveToDisk</span> () const</h3>
<p>Returns is this cache should be allowed to be stored on disk.</p>
<p>Some cache implementations can keep these cache items in memory for performance reasons, but for security reasons they should not be written to disk.</p>
<p>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.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#setSaveToDisk">setSaveToDisk</a>().</p>
<!-- @@@saveToDisk -->
<!-- $$$setAttributes[overload1]$$$setAttributesconstAttributesMap& -->
<h3 class="fn"><a name="setAttributes"></a><span class="type">void</span> QNetworkCacheMetaData::<span class="name">setAttributes</span> ( const <span class="type"><a href="qnetworkcachemetadata.html#AttributesMap-typedef">AttributesMap</a></span> & <i>attributes</i> )</h3>
<p>Sets all attributes of this cache item to be the map <i>attributes</i>.</p>
<p>This function was introduced in Qt 4.6.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#attributes">attributes</a>() and <a href="qnetworkrequest.html#setAttribute">QNetworkRequest::setAttribute</a>().</p>
<!-- @@@setAttributes -->
<!-- $$$setExpirationDate[overload1]$$$setExpirationDateconstQDateTime& -->
<h3 class="fn"><a name="setExpirationDate"></a><span class="type">void</span> QNetworkCacheMetaData::<span class="name">setExpirationDate</span> ( const <span class="type"><a href="qdatetime.html">QDateTime</a></span> & <i>dateTime</i> )</h3>
<p>Sets the date and time when the meta data expires to <i>dateTime</i>.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#expirationDate">expirationDate</a>().</p>
<!-- @@@setExpirationDate -->
<!-- $$$setLastModified[overload1]$$$setLastModifiedconstQDateTime& -->
<h3 class="fn"><a name="setLastModified"></a><span class="type">void</span> QNetworkCacheMetaData::<span class="name">setLastModified</span> ( const <span class="type"><a href="qdatetime.html">QDateTime</a></span> & <i>dateTime</i> )</h3>
<p>Sets the date and time when the meta data was last modified to <i>dateTime</i>.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#lastModified">lastModified</a>().</p>
<!-- @@@setLastModified -->
<!-- $$$setRawHeaders[overload1]$$$setRawHeadersconstRawHeaderList& -->
<h3 class="fn"><a name="setRawHeaders"></a><span class="type">void</span> QNetworkCacheMetaData::<span class="name">setRawHeaders</span> ( const <span class="type"><a href="qnetworkcachemetadata.html#RawHeaderList-typedef">RawHeaderList</a></span> & <i>list</i> )</h3>
<p>Sets the raw headers to <i>list</i>.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#rawHeaders">rawHeaders</a>().</p>
<!-- @@@setRawHeaders -->
<!-- $$$setSaveToDisk[overload1]$$$setSaveToDiskbool -->
<h3 class="fn"><a name="setSaveToDisk"></a><span class="type">void</span> QNetworkCacheMetaData::<span class="name">setSaveToDisk</span> ( <span class="type">bool</span> <i>allow</i> )</h3>
<p>Sets whether this network cache meta data and associated content should be allowed to be stored on disk to <i>allow</i>.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#saveToDisk">saveToDisk</a>().</p>
<!-- @@@setSaveToDisk -->
<!-- $$$setUrl[overload1]$$$setUrlconstQUrl& -->
<h3 class="fn"><a name="setUrl"></a><span class="type">void</span> QNetworkCacheMetaData::<span class="name">setUrl</span> ( const <span class="type"><a href="qurl.html">QUrl</a></span> & <i>url</i> )</h3>
<p>Sets the URL this network cache meta data to to be <i>url</i>.</p>
<p>The password and fragment are removed from the url.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#url">url</a>().</p>
<!-- @@@setUrl -->
<!-- $$$url[overload1]$$$url -->
<h3 class="fn"><a name="url"></a><span class="type"><a href="qurl.html">QUrl</a></span> QNetworkCacheMetaData::<span class="name">url</span> () const</h3>
<p>Returns the URL this network cache meta data is referring to.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#setUrl">setUrl</a>().</p>
<!-- @@@url -->
<!-- $$$operator!=[overload1]$$$operator!=constQNetworkCacheMetaData& -->
<h3 class="fn"><a name="operator-not-eq"></a><span class="type">bool</span> QNetworkCacheMetaData::<span class="name">operator!=</span> ( const <span class="type">QNetworkCacheMetaData</span> & <i>other</i> ) const</h3>
<p>Returns true if this meta data is not equal to the <i>other</i> meta data; otherwise returns false.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#operator-eq-eq">operator==</a>().</p>
<!-- @@@operator!= -->
<!-- $$$operator=[overload1]$$$operator=constQNetworkCacheMetaData& -->
<h3 class="fn"><a name="operator-eq"></a><span class="type">QNetworkCacheMetaData</span> & QNetworkCacheMetaData::<span class="name">operator=</span> ( const <span class="type">QNetworkCacheMetaData</span> & <i>other</i> )</h3>
<p>Makes a copy of the <i>other</i> <a href="qnetworkcachemetadata.html">QNetworkCacheMetaData</a> and returns a reference to the copy.</p>
<!-- @@@operator= -->
<!-- $$$operator==[overload1]$$$operator==constQNetworkCacheMetaData& -->
<h3 class="fn"><a name="operator-eq-eq"></a><span class="type">bool</span> QNetworkCacheMetaData::<span class="name">operator==</span> ( const <span class="type">QNetworkCacheMetaData</span> & <i>other</i> ) const</h3>
<p>Returns true if this meta data is equal to the <i>other</i> meta data; otherwise returns false.</p>
<p><b>See also </b><a href="qnetworkcachemetadata.html#operator-not-eq">operator!=</a>().</p>
<!-- @@@operator== -->
</div>
<div class="relnonmem">
<h2>Related Non-Members</h2>
<!-- $$$operator<<$$$operator<<QDataStream&constQNetworkCacheMetaData& -->
<h3 class="fn"><a name="operator-lt-lt-85"></a><span class="type"><a href="qdatastream.html">QDataStream</a></span> & <span class="name">operator<<</span> ( <span class="type"><a href="qdatastream.html">QDataStream</a></span> & <i>out</i>, const <span class="type">QNetworkCacheMetaData</span> & <i>metaData</i> )</h3>
<p>Writes <i>metaData</i> to the <i>out</i> stream.</p>
<p>This function was introduced in Qt 4.5.</p>
<p><b>See also </b><a href="datastreamformat.html">Serializing Qt Data Types</a>.</p>
<!-- @@@operator<< -->
<!-- $$$operator>>$$$operator>>QDataStream&QNetworkCacheMetaData& -->
<h3 class="fn"><a name="operator-gt-gt-44"></a><span class="type"><a href="qdatastream.html">QDataStream</a></span> & <span class="name">operator>></span> ( <span class="type"><a href="qdatastream.html">QDataStream</a></span> & <i>in</i>, <span class="type">QNetworkCacheMetaData</span> & <i>metaData</i> )</h3>
<p>Reads a <a href="qnetworkcachemetadata.html">QNetworkCacheMetaData</a> from the stream <i>in</i> into <i>metaData</i>.</p>
<p>This function was introduced in Qt 4.5.</p>
<p><b>See also </b><a href="datastreamformat.html">Serializing Qt Data Types</a>.</p>
<!-- @@@operator>> -->
</div>
<div class="ft">
<span></span>
</div>
</div>
<div class="footer">
<p>
<acronym title="Copyright">©</acronym> 2012 Nokia Corporation and/or its
subsidiaries. Documentation contributions included herein are the copyrights of
their respective owners.</p>
<br />
<p>
The documentation provided herein is licensed under the terms of the
<a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation
License version 1.3</a> as published by the Free Software Foundation.</p>
<p>
Documentation sources may be obtained from <a href="http://www.qt-project.org">
www.qt-project.org</a>.</p>
<br />
<p>
Nokia, Qt and their respective logos are trademarks of Nokia Corporation
in Finland and/or other countries worldwide. All other trademarks are property
of their respective owners. <a title="Privacy Policy"
href="http://en.gitorious.org/privacy_policy/">Privacy Policy</a></p>
</div>
</body>
</html>
|