Defines a buffer filter header.
More...
#include <BufferFilterHeader.h>
|
char | id [8] = {'\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0'} |
| filter id More...
|
|
uint64_t | size = 0 |
| the size of this header plus the updates More...
|
|
uint32_t | version = 0 |
| filter version More...
|
|
Defines a buffer filter header.
Format:
[00] [8 byte unsigned size] <br />
[08] [8 byte id string] <br />
[16] [4 byte version] <br />
Definition at line 32 of file BufferFilterHeader.h.
◆ BufferFilterHeader()
madara::filters::BufferFilterHeader::BufferFilterHeader |
( |
| ) |
|
|
inline |
◆ check_filter()
Checks compatability between the header and the filter.
- Parameters
-
filter | the filter to check |
- Returns
- true if the filter matches the header
Definition at line 23 of file BufferFilterHeader.inl.
◆ encoded_size()
static uint64_t madara::filters::BufferFilterHeader::encoded_size |
( |
void |
| ) |
|
|
inlinestatic |
◆ read() [1/2]
const char * madara::filters::BufferFilterHeader::read |
( |
const char * |
buffer, |
|
|
int64_t & |
buffer_remaining |
|
) |
| |
|
inline |
Reads a BufferFiltefrHeader instance from a buffer and updates the amount of buffer room remaining.
- Parameters
-
buffer | the readable buffer where data is stored |
buffer_remaining | the count of bytes remaining in the buffer to read |
- Returns
- current buffer position for next read
- Exceptions
-
Definition at line 59 of file BufferFilterHeader.inl.
◆ read() [2/2]
Reads relevant fields from a filter.
- Parameters
-
filter | the filter to refer to |
Definition at line 40 of file BufferFilterHeader.inl.
◆ write()
char * madara::filters::BufferFilterHeader::write |
( |
char * |
buffer, |
|
|
int64_t & |
buffer_remaining |
|
) |
| |
|
inline |
Writes a BufferFilterHeader instance to a buffer and updates the amount of buffer room remaining.
- Parameters
-
buffer | the readable buffer where data is stored |
buffer_remaining | the count of bytes remaining in the buffer to read |
- Returns
- current buffer position for next write
- Exceptions
-
Definition at line 87 of file BufferFilterHeader.inl.
◆ id
char madara::filters::BufferFilterHeader::id[8] = {'\0', '\0', '\0', '\0', '\0', '\0', '\0', '\0'} |
◆ size
uint64_t madara::filters::BufferFilterHeader::size = 0 |
◆ version
uint32_t madara::filters::BufferFilterHeader::version = 0 |
The documentation for this class was generated from the following files: