Fray Engine
Loading...
Searching...
No Matches
fray::message::FrameBuilder Class Reference

Builds outgoing frames sent by the Engine (sender is always the Engine). Stateless; safe to use from any thread. More...

#include <message.hpp>

Public Member Functions

F_err build (const FrameOptions &options, std::shared_ptr< const std::vector< F_uchar > > &out) const
 Builds an Engine frame from the options, stamping the protocol version, a new message id and the current time.

Detailed Description

Builds outgoing frames sent by the Engine (sender is always the Engine). Stateless; safe to use from any thread.

Definition at line 450 of file message.hpp.

Member Function Documentation

◆ build()

F_err fray::message::FrameBuilder::build ( const FrameOptions & options,
std::shared_ptr< const std::vector< F_uchar > > & out ) const
inline

Builds an Engine frame from the options, stamping the protocol version, a new message id and the current time.

Parameters
optionsDestination, operation, category, payload and header fields.
outReceives the shared immutable frame only on success.
Returns
errors::NONE on success; INVALID_MESSAGE if a payload has no payloadType or the frame cannot be built; MESSAGE_TOO_LARGE if the frame exceeds MAX_FRAME_LENGTH.

Definition at line 460 of file message.hpp.


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