C++ Actor Framework 1.0.0
Loading...
Searching...
No Matches
caf::net::receive_policy Struct Reference

Configures how many bytes an octet stream transport receives before calling consume on its upper layer. More...

#include <receive_policy.hpp>

Static Public Member Functions

static constexpr receive_policy between (uint32_t min_size, uint32_t max_size)
 
static constexpr receive_policy exactly (uint32_t size)
 
static constexpr receive_policy up_to (uint32_t max_size)
 
static constexpr receive_policy stop ()
 

Public Attributes

uint32_t min_size
 Configures how many bytes the transport must read before it may call consume on its upper layer.
 
uint32_t max_size
 Configures how many bytes the transport may read at most before it calls consume on its upper layer.
 

Detailed Description

Configures how many bytes an octet stream transport receives before calling consume on its upper layer.

Member Function Documentation

◆ between()

static constexpr receive_policy caf::net::receive_policy::between ( uint32_t min_size,
uint32_t max_size )
staticconstexpr
Precondition
min_size > 0
min_size <= max_size

◆ exactly()

static constexpr receive_policy caf::net::receive_policy::exactly ( uint32_t size)
staticconstexpr
Precondition
size > 0

◆ up_to()

static constexpr receive_policy caf::net::receive_policy::up_to ( uint32_t max_size)
staticconstexpr
Precondition
max_size >= 1

The documentation for this struct was generated from the following file: