QGIS API Documentation
3.8.0-Zanzibar (11aff65)
|
Encapsulates parameters and properties of a network request. More...
#include <qgsnetworkaccessmanager.h>
Public Types | |
enum | RequestAttributes { AttributeInitiatorClass = QNetworkRequest::User + 3000, AttributeInitiatorRequestId } |
Custom request attributes. More... | |
Public Member Functions | |
QgsNetworkRequestParameters ()=default | |
Default constructor. More... | |
QgsNetworkRequestParameters (QNetworkAccessManager::Operation operation, const QNetworkRequest &request, int requestId, const QByteArray &content=QByteArray()) | |
Constructor for QgsNetworkRequestParameters, with the specified network operation and original request. More... | |
QByteArray | content () const |
Returns the request's content. More... | |
QString | initiatorClassName () const |
Returns the class name of the object which initiated this request. More... | |
QVariant | initiatorRequestId () const |
Returns the internal ID used by the object which initiated this request to identify individual requests. More... | |
QNetworkAccessManager::Operation | operation () const |
Returns the request operation, e.g. More... | |
QString | originatingThreadId () const |
Returns a string identifying the thread which the request originated from. More... | |
QNetworkRequest | request () const |
Returns the network request. More... | |
int | requestId () const |
Returns a unique ID identifying the request. More... | |
Encapsulates parameters and properties of a network request.
Definition at line 51 of file qgsnetworkaccessmanager.h.
Custom request attributes.
Enumerator | |
---|---|
AttributeInitiatorClass | Class name of original object which created the request. |
AttributeInitiatorRequestId | Internal ID used by originator object to identify requests. |
Definition at line 56 of file qgsnetworkaccessmanager.h.
|
default |
Default constructor.
QgsNetworkRequestParameters::QgsNetworkRequestParameters | ( | QNetworkAccessManager::Operation | operation, |
const QNetworkRequest & | request, | ||
int | requestId, | ||
const QByteArray & | content = QByteArray() |
||
) |
Constructor for QgsNetworkRequestParameters, with the specified network operation and original request.
Definition at line 647 of file qgsnetworkaccessmanager.cpp.
|
inline |
Returns the request's content.
This is only used for POST or PUT operation requests.
Definition at line 103 of file qgsnetworkaccessmanager.h.
|
inline |
Returns the class name of the object which initiated this request.
This is only available for QNetworkRequests which have had the QgsNetworkRequestParameters::AttributeInitiatorClass attribute set.
Definition at line 113 of file qgsnetworkaccessmanager.h.
|
inline |
Returns the internal ID used by the object which initiated this request to identify individual requests.
This is only available for QNetworkRequests which have had the QgsNetworkRequestParameters::AttributeInitiatorRequestId attribute set.
Definition at line 124 of file qgsnetworkaccessmanager.h.
|
inline |
Returns the request operation, e.g.
GET or POST.
Definition at line 79 of file qgsnetworkaccessmanager.h.
|
inline |
Returns a string identifying the thread which the request originated from.
Definition at line 92 of file qgsnetworkaccessmanager.h.
|
inline |
Returns the network request.
This is the original network request sent to QgsNetworkAccessManager, but with QGIS specific configuration options such as proxy handling and SSL exceptions applied.
Definition at line 87 of file qgsnetworkaccessmanager.h.
|
inline |
Returns a unique ID identifying the request.
Definition at line 97 of file qgsnetworkaccessmanager.h.