C++ Actor Framework 1.0.0
Loading...
Searching...
No Matches
caf::net::web_socket::client Class Reference

Implements the client part for the WebSocket Protocol as defined in RFC. More...

#include <client.hpp>

Inheritance diagram for caf::net::web_socket::client:
caf::net::octet_stream::upper_layer caf::net::generic_upper_layer

Public Types

using handshake_ptr = std::unique_ptr<handshake>
 
using upper_layer_ptr = std::unique_ptr<web_socket::upper_layer>
 

Static Public Member Functions

static std::unique_ptr< clientmake (handshake_ptr hs, upper_layer_ptr up)
 
static std::unique_ptr< clientmake (handshake &&hs, upper_layer_ptr up)
 

Additional Inherited Members

- Public Member Functions inherited from caf::net::octet_stream::upper_layer
virtual error start (lower_layer *down)=0
 Initializes the upper layer.
 
virtual ptrdiff_t consume (byte_span buffer, byte_span delta)=0
 Consumes bytes from the lower layer.
 
virtual void written (size_t num_bytes)
 Called from the lower layer whenever data has been written.
 
- Public Member Functions inherited from caf::net::generic_upper_layer
virtual void prepare_send ()=0
 Gives the upper layer an opportunity to add additional data to the output buffer.
 
virtual bool done_sending ()=0
 Queries whether all pending data has been sent.
 
virtual void abort (const error &reason)=0
 Called by the lower layer for cleaning up any state in case of an error or when disposed.
 

Detailed Description

Implements the client part for the WebSocket Protocol as defined in RFC.

  1. Initially, the layer performs the WebSocket handshake. Once completed, this layer decodes RFC 6455 frames and forwards binary and text messages to UpperLayer.

The documentation for this class was generated from the following files: