#include <genesis/utils/io/deserializer.hpp>
Definition at line 57 of file deserializer.hpp.
|
| Deserializer (std::istream &instream) |
|
| Deserializer (std::string const &file_name) |
|
bool | finished () const |
|
template<typename T > |
T | get_float () |
| Read a floating point number from the stream and return it. More...
|
|
template<typename T > |
void | get_float (T &res) |
| Read an floating point number from the stream and store it in the result. More...
|
|
template<typename T > |
T | get_int () |
| Read an integer number from the stream and return it. More...
|
|
template<typename T > |
void | get_int (T &res) |
| Read an integer number from the stream and store it in the result. More...
|
|
bool | get_null (size_t n) |
| Reads n bytes from the stream and returns whether all of them are \0 bytes. More...
|
|
template<typename T > |
T | get_plain () |
| Read as many bytes from the stream as the type T holds, and return them in form of a value of type T. More...
|
|
template<typename T > |
void | get_plain (T &res) |
| Read as many bytes from the stream as the type T holds, and put them in the result value of type T. More...
|
|
void | get_raw (char *buffer, size_t n) |
| Read n bytes from the stream and store them in the buffer. More...
|
|
std::string | get_raw_string (size_t n) |
| Read n bytes from the stream and return them as a string. More...
|
|
std::string | get_string () |
| Read a string from the stream, provided that its length it written preceding it, as done by put_string(). More...
|
|
| operator bool () const |
|
◆ Deserializer() [1/2]
◆ Deserializer() [2/2]
◆ finished()
◆ get_float() [1/2]
Read a floating point number from the stream and return it.
Definition at line 239 of file deserializer.hpp.
◆ get_float() [2/2]
void get_float |
( |
T & |
res | ) |
|
|
inline |
Read an floating point number from the stream and store it in the result.
Definition at line 248 of file deserializer.hpp.
◆ get_int() [1/2]
Read an integer number from the stream and return it.
Definition at line 221 of file deserializer.hpp.
◆ get_int() [2/2]
Read an integer number from the stream and store it in the result.
Definition at line 230 of file deserializer.hpp.
◆ get_null()
bool get_null |
( |
size_t |
n | ) |
|
|
inline |
Reads n
bytes from the stream and returns whether all of them are \0
bytes.
Definition at line 157 of file deserializer.hpp.
◆ get_plain() [1/2]
Read as many bytes from the stream as the type T holds, and return them in form of a value of type T.
Definition at line 200 of file deserializer.hpp.
◆ get_plain() [2/2]
void get_plain |
( |
T & |
res | ) |
|
|
inline |
Read as many bytes from the stream as the type T holds, and put them in the result value of type T.
Definition at line 212 of file deserializer.hpp.
◆ get_raw()
void get_raw |
( |
char * |
buffer, |
|
|
size_t |
n |
|
) |
| |
|
inline |
Read n
bytes from the stream and store them in the buffer.
The buffer needs to be big enough to hold n
bytes.
Definition at line 143 of file deserializer.hpp.
◆ get_raw_string()
std::string get_raw_string |
( |
size_t |
n | ) |
|
|
inline |
Read n
bytes from the stream and return them as a string.
Definition at line 174 of file deserializer.hpp.
◆ get_string()
std::string get_string |
( |
| ) |
|
|
inline |
Read a string from the stream, provided that its length it written preceding it, as done by put_string().
Definition at line 188 of file deserializer.hpp.
◆ operator bool()
The documentation for this class was generated from the following file: