cpp-msgpack-light 0.3.0
A light library to serialize MessagePack.
|
Class of views of mutable buffers with static sizes. More...
#include <msgpack_light/details/mutable_static_binary_view.h>
Public Member Functions | |
mutable_static_binary_view (unsigned char *buffer) noexcept | |
Constructor. | |
unsigned char * | data () noexcept |
Access the buffer. | |
unsigned char | operator[] (std::size_t index) const noexcept |
Get a byte. | |
unsigned char & | operator[] (std::size_t index) noexcept |
Access to a byte. | |
std::size_t | size () const noexcept |
Get the size of the buffer. | |
template<std::size_t Start, std::size_t Size = N - Start> | |
mutable_static_binary_view< Size > | sub_buffer () const noexcept |
Get a subset of this buffer. |
Private Attributes | |
unsigned char * | buffer_ |
Buffer. |
Class of views of mutable buffers with static sizes.
N | Number of elements. |
Definition at line 32 of file mutable_static_binary_view.h.
|
inlineexplicitnoexcept |
Constructor.
[in] | buffer | Buffer. |
Definition at line 39 of file mutable_static_binary_view.h.
|
inlinenoexcept |
|
inlinenoexcept |
Get a byte.
[in] | index | Index of the byte. |
Definition at line 58 of file mutable_static_binary_view.h.
|
inlinenoexcept |
Access to a byte.
[in] | index | Index of the byte. |
Definition at line 48 of file mutable_static_binary_view.h.
|
inlinenodiscardnoexcept |
Get the size of the buffer.
Definition at line 74 of file mutable_static_binary_view.h.
|
inlinenodiscardnoexcept |
Get a subset of this buffer.
Start | Index of the first byte in the current buffer. |
Definition at line 83 of file mutable_static_binary_view.h.
|
private |
Buffer.
Definition at line 91 of file mutable_static_binary_view.h.