Fray Engine
Loading...
Searching...
No Matches
fray::message::detail Namespace Reference

Internal helpers for big-endian encoding. More...

Functions

void put32 (F_uchar *out, F_ulong v)
 Writes a 32-bit value as 4 big-endian bytes.
F_ulong get32 (const F_uchar *in)
 Reads 4 big-endian bytes as a 32-bit value.

Detailed Description

Internal helpers for big-endian encoding.

Function Documentation

◆ get32()

F_ulong fray::message::detail::get32 ( const F_uchar * in)
inline

Reads 4 big-endian bytes as a 32-bit value.

Parameters
inSource; must hold at least 4 bytes.
Returns
The decoded value.

Definition at line 206 of file message.hpp.

◆ put32()

void fray::message::detail::put32 ( F_uchar * out,
F_ulong v )
inline

Writes a 32-bit value as 4 big-endian bytes.

Parameters
outDestination; must have room for 4 bytes.
vValue to write.

Definition at line 191 of file message.hpp.