src/network/access/qnetworkrequest.cpp
changeset 37 758a864f9613
parent 33 3e2da88830cd
equal deleted inserted replaced
36:ef0373b55136 37:758a864f9613
   103     \sa header(), setHeader(), rawHeader(), setRawHeader()
   103     \sa header(), setHeader(), rawHeader(), setRawHeader()
   104 */
   104 */
   105 
   105 
   106 /*!
   106 /*!
   107     \enum QNetworkRequest::Attribute
   107     \enum QNetworkRequest::Attribute
   108 
   108     \since 4.7
       
   109     
   109     Attribute codes for the QNetworkRequest and QNetworkReply.
   110     Attribute codes for the QNetworkRequest and QNetworkReply.
   110 
   111 
   111     Attributes are extra meta-data that are used to control the
   112     Attributes are extra meta-data that are used to control the
   112     behavior of the request and to pass further information from the
   113     behavior of the request and to pass further information from the
   113     reply back to the application. Attributes are also extensible,
   114     reply back to the application. Attributes are also extensible,
   172         Indicates whether the QNetworkAccessManager code is
   173         Indicates whether the QNetworkAccessManager code is
   173         allowed to buffer the upload data, e.g. when doing a HTTP POST.
   174         allowed to buffer the upload data, e.g. when doing a HTTP POST.
   174         When using this flag with sequential upload data, the ContentLengthHeader
   175         When using this flag with sequential upload data, the ContentLengthHeader
   175         header must be set.
   176         header must be set.
   176 
   177 
   177      \value HttpPipeliningAllowedAttribute
   178     \value HttpPipeliningAllowedAttribute
   178         Requests only, type: QVariant::Bool (default: false)
   179         Requests only, type: QVariant::Bool (default: false)
   179         Indicates whether the QNetworkAccessManager code is
   180         Indicates whether the QNetworkAccessManager code is
   180         allowed to use HTTP pipelining with this request.
   181         allowed to use HTTP pipelining with this request.
   181 
   182 
   182      \value HttpPipeliningWasUsedAttribute
   183     \value HttpPipeliningWasUsedAttribute
   183         Replies only, type: QVariant::Bool
   184         Replies only, type: QVariant::Bool
   184         Indicates whether the HTTP pipelining was used for receiving
   185         Indicates whether the HTTP pipelining was used for receiving
   185         this reply.
   186         this reply.
   186 
   187 
   187     \value CustomVerbAttribute
   188     \value CustomVerbAttribute
   188        Requests only, type: QVariant::ByteArray
   189        Requests only, type: QVariant::ByteArray
   189         Holds the value for the custom HTTP verb to send (destined for usage
   190        Holds the value for the custom HTTP verb to send (destined for usage
   190         of other verbs than GET, POST, PUT and DELETE). This verb is set
   191        of other verbs than GET, POST, PUT and DELETE). This verb is set
   191         when calling QNetworkAccessManager::sendCustomRequest().
   192        when calling QNetworkAccessManager::sendCustomRequest().
   192 
   193 
   193     \value CookieLoadControlAttribute
   194     \value CookieLoadControlAttribute
   194         Requests only, type: QVariant::Int (default: QNetworkRequest::Automatic)
   195         Requests only, type: QVariant::Int (default: QNetworkRequest::Automatic)
   195         Indicates whether to send 'Cookie' headers in the request.
   196         Indicates whether to send 'Cookie' headers in the request.
   196 
   197 
   197         This attribute is set to false by QtWebKit when creating a cross-origin
   198         This attribute is set to false by QtWebKit when creating a cross-origin
   198         XMLHttpRequest where withCredentials has not been set explicitly to true by the
   199         XMLHttpRequest where withCredentials has not been set explicitly to true by the
   199         Javascript that created the request.
   200         Javascript that created the request.
   200 
   201 
   201         See http://www.w3.org/TR/XMLHttpRequest2/#credentials-flag for more information.
   202         See \l{http://www.w3.org/TR/XMLHttpRequest2/#credentials-flag}{here} for more information.
   202 
   203 
   203         \since 4.7
   204         (This value was introduced in 4.7.)
   204 
   205 
   205      \value CookieSaveControlAttribute
   206 
       
   207     \value CookieSaveControlAttribute
   206         Requests only, type: QVariant::Int (default: QNetworkRequest::Automatic)
   208         Requests only, type: QVariant::Int (default: QNetworkRequest::Automatic)
   207         Indicates whether to save 'Cookie' headers received from the server in reply
   209         Indicates whether to save 'Cookie' headers received from the server in reply
   208         to the request.
   210         to the request.
   209 
       
   210         This attribute is set to false by QtWebKit when creating a cross-origin
   211         This attribute is set to false by QtWebKit when creating a cross-origin
   211         XMLHttpRequest where withCredentials has not been set explicitly to true by the
   212         XMLHttpRequest where withCredentials has not been set explicitly to true by the
   212         Javascript that created the request.
   213         Javascript that created the request.
   213 
   214 
   214         See http://www.w3.org/TR/XMLHttpRequest2/#credentials-flag for more information.
   215         See \l{http://www.w3.org/TR/XMLHttpRequest2/#credentials-flag} {here} for more information.
   215 
   216 
   216         \since 4.7
   217         (This value was introduced in 4.7.)
   217 
   218 
   218      \value AuthenticationReuseAttribute
   219     \value AuthenticationReuseAttribute
   219         Requests only, type: QVariant::Int (default: QNetworkRequest::Automatic)
   220         Requests only, type: QVariant::Int (default: QNetworkRequest::Automatic)
   220         Indicates whether to use cached authorization credentials in the request,
   221         Indicates whether to use cached authorization credentials in the request,
   221         if available. If this is set to QNetworkRequest::Manual and the authentication
   222         if available. If this is set to QNetworkRequest::Manual and the authentication
   222         mechanism is 'Basic' or 'Digest', Qt will not send an an 'Authorization' HTTP
   223         mechanism is 'Basic' or 'Digest', Qt will not send an an 'Authorization' HTTP
   223         header with any cached credentials it may have for the request's URL.
   224         header with any cached credentials it may have for the request's URL.
   224 
       
   225         This attribute is set to QNetworkRequest::Manual by QtWebKit when creating a cross-origin
   225         This attribute is set to QNetworkRequest::Manual by QtWebKit when creating a cross-origin
   226         XMLHttpRequest where withCredentials has not been set explicitly to true by the
   226         XMLHttpRequest where withCredentials has not been set explicitly to true by the
   227         Javascript that created the request.
   227         Javascript that created the request.
   228 
   228 
   229         See http://www.w3.org/TR/XMLHttpRequest2/#credentials-flag for more information.
   229         See \l{http://www.w3.org/TR/XMLHttpRequest2/#credentials-flag} {here} for more information.
   230 
   230 
   231         \since 4.7
   231         (This value was introduced in 4.7.)
   232 
   232 
   233     \omitvalue MaximumDownloadBufferSizeAttribute
   233     \omitvalue MaximumDownloadBufferSizeAttribute
   234         \since 4.7
   234         (This value was introduced in 4.7.)
   235         \internal
       
   236 
   235 
   237     \omitvalue DownloadBufferAttribute
   236     \omitvalue DownloadBufferAttribute
   238         \since 4.7
   237         (This value was introduced in 4.7.)
   239         \internal
       
   240 
   238 
   241     \value User
   239     \value User
   242         Special type. Additional information can be passed in
   240         Special type. Additional information can be passed in
   243         QVariants with types ranging from User to UserMax. The default
   241         QVariants with types ranging from User to UserMax. The default
   244         implementation of Network Access will ignore any request
   242         implementation of Network Access will ignore any request