Your opinion will help to improve our service
Leave a feedback >#include <userver/dump/operations.hpp>
A general interface for binary data output.
Definition at line 23 of file operations.hpp.
Public Member Functions | |
template<typename T> | |
void | Write (const T &data) |
Writes binary data. | |
virtual void | Finish ()=0 |
Must be called once all data has been written. | |
Protected Member Functions | |
virtual void | WriteRaw (std::string_view data)=0 |
Writes binary data. | |
|
pure virtual |
Must be called once all data has been written.
Write
/Read
`Error` | on write operation failure |
Implemented in dump::EncryptedWriter, dump::FileWriter, and dump::MockWriter.
void dump::Writer::Write | ( | const T & | data | ) |
Writes binary data.
Calls ADL-found Write(writer, data)
`Error` | and any user-thrown std::exception |
Definition at line 98 of file operations.hpp.
|
protectedpure virtual |
Writes binary data.
Unlike Write
, doesn't write the size of data
`Error` | on write operation failure |
|
friend |
Writes a non-size-prefixed std::string_view
writer.Write(str)
should normally be used instead to write strings