![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
The QHttp2Configuration class controls HTTP/2 parameters and settings. More...
#include <qhttp2configuration.h>
Public Member Functions | |
QHttp2Configuration () | |
Default constructs a QHttp2Configuration object. | |
QHttp2Configuration (const QHttp2Configuration &other) | |
Copy-constructs this QHttp2Configuration. | |
QHttp2Configuration (QHttp2Configuration &&other) noexcept | |
Move-constructs this QHttp2Configuration from other. | |
QHttp2Configuration & | operator= (const QHttp2Configuration &other) |
Copy-assigns other to this QHttp2Configuration. | |
QHttp2Configuration & | operator= (QHttp2Configuration &&other) noexcept |
Move-assigns other to this QHttp2Configuration. | |
~QHttp2Configuration () | |
Destructor. | |
void | setServerPushEnabled (bool enable) |
If enable is true , a remote server can potentially use server push to send responses in advance. | |
bool | serverPushEnabled () const |
Returns true if server push was enabled. | |
void | setHuffmanCompressionEnabled (bool enable) |
If enable is true , HPACK compression will additionally compress string using the Huffman coding. | |
bool | huffmanCompressionEnabled () const |
Returns true if the Huffman coding in HPACK is enabled. | |
bool | setSessionReceiveWindowSize (unsigned size) |
Sets the window size for connection-level flow control. | |
unsigned | sessionReceiveWindowSize () const |
Returns the window size for connection-level flow control. | |
bool | setStreamReceiveWindowSize (unsigned size) |
Sets the window size for stream-level flow control. | |
unsigned | streamReceiveWindowSize () const |
Returns the window size for stream-level flow control. | |
bool | setMaxFrameSize (unsigned size) |
Sets the maximum frame size that QNetworkAccessManager will advertise to the server when sending its initial SETTINGS frame. | |
unsigned | maxFrameSize () const |
Returns the maximum payload size that HTTP/2 frames can have. | |
void | setMaxConcurrentStreams (unsigned value) |
unsigned | maxConcurrentStreams () const |
void | swap (QHttp2Configuration &other) noexcept |
\memberswap{configuration} | |
Friends | |
bool | operator== (const QHttp2Configuration &lhs, const QHttp2Configuration &rhs) noexcept |
Returns true if lhs and rhs have the same set of HTTP/2 parameters. | |
bool | operator!= (const QHttp2Configuration &lhs, const QHttp2Configuration &rhs) noexcept |
Returns true if lhs and rhs do not have the same set of HTTP/2 parameters. | |
The QHttp2Configuration class controls HTTP/2 parameters and settings.
\reentrant \inmodule QtNetwork
QHttp2Configuration controls HTTP/2 parameters and settings that QNetworkAccessManager will use to send requests and process responses when the HTTP/2 protocol is enabled.
The HTTP/2 parameters that QHttp2Configuration currently supports include:
\list
The QHttp2Configuration class also controls if the header compression algorithm (HPACK) is additionally using Huffman coding for string compression.
Definition at line 16 of file qhttp2configuration.h.
QHttp2Configuration::QHttp2Configuration | ( | ) |
Default constructs a QHttp2Configuration object.
Such a configuration has the following values: \list
Definition at line 88 of file qhttp2configuration.cpp.
|
default |
Copy-constructs this QHttp2Configuration.
|
noexcept |
Move-constructs this QHttp2Configuration from other.
Definition at line 101 of file qhttp2configuration.cpp.
QHttp2Configuration::~QHttp2Configuration | ( | ) |
Destructor.
Definition at line 119 of file qhttp2configuration.cpp.
bool QHttp2Configuration::huffmanCompressionEnabled | ( | ) | const |
Returns true
if the Huffman coding in HPACK is enabled.
Definition at line 166 of file qhttp2configuration.cpp.
unsigned QHttp2Configuration::maxConcurrentStreams | ( | ) | const |
Returns the maximum number of concurrent streams.
Definition at line 278 of file qhttp2configuration.cpp.
unsigned QHttp2Configuration::maxFrameSize | ( | ) | const |
Returns the maximum payload size that HTTP/2 frames can have.
The default (initial) value is 16384 octets.
Definition at line 253 of file qhttp2configuration.cpp.
|
default |
Copy-assigns other to this QHttp2Configuration.
|
defaultnoexcept |
Move-assigns other to this QHttp2Configuration.
bool QHttp2Configuration::serverPushEnabled | ( | ) | const |
Returns true if server push was enabled.
Definition at line 142 of file qhttp2configuration.cpp.
unsigned QHttp2Configuration::sessionReceiveWindowSize | ( | ) | const |
Returns the window size for connection-level flow control.
The default value QNetworkAccessManager will be using is 2147483647 octets.
Definition at line 195 of file qhttp2configuration.cpp.
void QHttp2Configuration::setHuffmanCompressionEnabled | ( | bool | enable | ) |
If enable is true
, HPACK compression will additionally compress string using the Huffman coding.
Enabled by default.
Definition at line 156 of file qhttp2configuration.cpp.
void QHttp2Configuration::setMaxConcurrentStreams | ( | unsigned | value | ) |
Sets value as the maximum number of concurrent streams that will be advertised to the peer when sending SETTINGS frame.
Definition at line 266 of file qhttp2configuration.cpp.
bool QHttp2Configuration::setMaxFrameSize | ( | unsigned | size | ) |
Sets the maximum frame size that QNetworkAccessManager will advertise to the server when sending its initial SETTINGS frame.
Returns true
on success, false
otherwise.
Definition at line 238 of file qhttp2configuration.cpp.
void QHttp2Configuration::setServerPushEnabled | ( | bool | enable | ) |
If enable is true
, a remote server can potentially use server push to send responses in advance.
Definition at line 129 of file qhttp2configuration.cpp.
bool QHttp2Configuration::setSessionReceiveWindowSize | ( | unsigned | size | ) |
Sets the window size for connection-level flow control.
size cannot be 0 and must not exceed 2147483647 octets.
Returns true
on success, false
otherwise.
Definition at line 179 of file qhttp2configuration.cpp.
bool QHttp2Configuration::setStreamReceiveWindowSize | ( | unsigned | size | ) |
Sets the window size for stream-level flow control.
size cannot be 0 and must not exceed 2147483647 octets.
Returns true
on success, false
otherwise.
Definition at line 208 of file qhttp2configuration.cpp.
unsigned QHttp2Configuration::streamReceiveWindowSize | ( | ) | const |
Returns the window size for stream-level flow control.
The default value QNetworkAccessManager will be using is 214748364 octets (see \l {https://httpwg.org/specs/rfc7540.html#SettingValues}{RFC 7540}).
Definition at line 224 of file qhttp2configuration.cpp.
|
noexcept |
\memberswap{configuration}
Definition at line 286 of file qhttp2configuration.cpp.
|
friend |
Returns true
if lhs and rhs do not have the same set of HTTP/2 parameters.
Definition at line 54 of file qhttp2configuration.h.
|
friend |
Returns true
if lhs and rhs have the same set of HTTP/2 parameters.
Definition at line 52 of file qhttp2configuration.h.