QWebSocketHandshakeOptions#

Collects options for the WebSocket handshake. More

Inheritance diagram of PySide6.QtWebSockets.QWebSocketHandshakeOptions

New in version 6.4.

Synopsis#

Functions#

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

Detailed Description#

QWebSocketHandshakeOptions collects options that are passed along to the WebSocket handshake, such as WebSocket subprotocols and WebSocket Extensions.

At the moment, only WebSocket subprotocols are supported.

See also

open()

class PySide6.QtWebSockets.QWebSocketHandshakeOptions#

PySide6.QtWebSockets.QWebSocketHandshakeOptions(other)

Parameters:

otherPySide6.QtWebSockets.QWebSocketHandshakeOptions

Constructs an empty QWebSocketHandshakeOptions object.

Constructs a QWebSocketHandshakeOptions that is a copy of other.

PySide6.QtWebSockets.QWebSocketHandshakeOptions.__ne__(rhs)#
Parameters:

rhsPySide6.QtWebSockets.QWebSocketHandshakeOptions

Return type:

bool

PySide6.QtWebSockets.QWebSocketHandshakeOptions.__eq__(rhs)#
Parameters:

rhsPySide6.QtWebSockets.QWebSocketHandshakeOptions

Return type:

bool

PySide6.QtWebSockets.QWebSocketHandshakeOptions.setSubprotocols(protocols)#
Parameters:

protocols – list of strings

Sets the list of WebSocket subprotocols protocols to send along with the websocket handshake.

WebSocket subprotocol names may only consist of those US-ASCII characters that are in the unreserved group. Invalid protocol names will not be included in the handshake.

See also

subprotocols()

PySide6.QtWebSockets.QWebSocketHandshakeOptions.subprotocols()#
Return type:

list of strings

Returns the list of WebSocket subprotocols to send along with the websocket handshake.

PySide6.QtWebSockets.QWebSocketHandshakeOptions.swap(other)#
Parameters:

otherPySide6.QtWebSockets.QWebSocketHandshakeOptions