UNISTDX_BASE_WEBSOCKETBUF
template <class Ch, class Tr = std::char_traits<Ch>>
class sys::basic_websocketbuf

Stream buffer that encodes/decodes its contents using WebSocket protocol. The implementation

  • supports only the latest WebSocket standard,
  • supports only binary frames,
  • supports only binary WebSocket protocol,
  • does not perform closing handshake,
  • always masks payloads,
  • uses secure random device for key generation and masking.

Base classes
Enumerations
  • enum role_type

    The role of this stream buffer.

Methods
  • client_handshake() -> bool

    Perform client WebSocket opening handshake.

  • server_handshake() -> bool

    Perform server WebSocket opening handshake.

  • handshake() -> boolvirtual

    Perform WebSocket opening handshake.

  • role() const -> role_type

    Get stream buffer role.

  • role(role_type r) -> void

    Set stream buffer role.