|
Galois
|
Buffer for serialization of data. More...
#include <Serialize.h>
Public Types | |
| using | size_type = vTy::size_type |
Public Member Functions | |
| SerializeBuffer ()=default | |
| default constructor More... | |
| SerializeBuffer (SerializeBuffer &&rhs)=default | |
| disabled copy constructor More... | |
| SerializeBuffer (const char *d, unsigned len) | |
| Creates a buffer from another buffer. More... | |
| void | push (const char c) |
| Push a character onto the serialize buffer. More... | |
| void | insert (const uint8_t *c, size_t bytes) |
| Insert characters from a buffer into the serialize buffer. More... | |
| void | insertAt (const uint8_t *c, size_t bytes, size_t offset) |
| Insert characters from a buffer into the serialize buffer at a particular offset. More... | |
| size_t | encomber (size_t bytes) |
| Reserve space at the end for inserting new data into the serialize buffer. More... | |
| void | resize (size_t bytes) |
| void | reserve (size_t s) |
| Reserve more space in the serialize buffer. More... | |
| const uint8_t * | linearData () const |
| Returns a pointer to the data stored in this serialize buffer. More... | |
| vTy & | getVec () |
| Returns vector of data stored in this serialize buffer. More... | |
| vTy::const_iterator | begin () const |
| Returns an iterator to the beginning of the data in this serialize buffer. More... | |
| vTy::const_iterator | end () const |
| Returns an iterator to the end of the data in this serialize buffer. More... | |
| size_type | size () const |
| Returns the size of the serialize buffer. More... | |
| void | print (std::ostream &o) const |
| Utility print function for the serialize buffer. More... | |
Friends | |
| std::ostream & | operator<< (std::ostream &os, const SerializeBuffer &b) |
| Operator that calls the print function of the serialize buffer. More... | |
Buffer for serialization of data.
Mainly used during network communication.
|
default |
default constructor
|
default |
disabled copy constructor
|
inline |
Creates a buffer from another buffer.
| d | buffer to create from |
| len | amount of copy from buffer d |
|
inline |
Returns an iterator to the beginning of the data in this serialize buffer.
|
inline |
Reserve space at the end for inserting new data into the serialize buffer.
| bytes | number of bytes to reserve at the end |
|
inline |
Returns an iterator to the end of the data in this serialize buffer.
|
inline |
Returns vector of data stored in this serialize buffer.
|
inline |
Insert characters from a buffer into the serialize buffer.
|
inline |
Insert characters from a buffer into the serialize buffer at a particular offset.
|
inline |
Returns a pointer to the data stored in this serialize buffer.
|
inline |
Utility print function for the serialize buffer.
| o | stream to print to |
|
inline |
Push a character onto the serialize buffer.
|
inline |
Reserve more space in the serialize buffer.
| s | extra space to reserve |
|
inline |
|
inline |
Returns the size of the serialize buffer.
|
friend |
Operator that calls the print function of the serialize buffer.