The QNetworkAccessManager class allows the application to send network requests and receive replies.
QNetworkReply * get(const QNetworkRequest &request)
Posts a request to obtain the contents of the target request and returns a new QNetworkReply object o...
void setCache(QAbstractNetworkCache *cache)
The QNetworkDiskCache class provides a very basic disk cache.
void setCacheDirectory(const QString &cacheDir)
Sets the directory where cached files will be stored to cacheDir.
The QNetworkReply class contains the data and headers for a request sent with QNetworkAccessManager.
QVariant attribute(QNetworkRequest::Attribute code) const
Returns the attribute associated with the code code.
The QNetworkRequest class holds a request to be sent with QNetworkAccessManager.
@ SourceIsFromCacheAttribute
@ CacheLoadControlAttribute
void setAttribute(Attribute code, const QVariant &value)
Sets the attribute associated with code code to be value value.
static QString writableLocation(StandardLocation type)
\macro QT_RESTRICTED_CAST_FROM_ASCII
bool toBool() const
Returns the variant as a bool if the variant has userType() Bool.
QNetworkRequest request2(QUrl(u"http://qt-project.org"_s))
QNetworkAccessManager * manager
[0]
QNetworkRequest request(QUrl(u"http://qt-project.org"_s))
void replyFinished(QNetworkReply *reply)
[1]
QNetworkDiskCache * diskCache