byteme
Read/write bytes from various sources
Loading...
Searching...
No Matches
Writer.hpp
Go to the documentation of this file.
1#ifndef BYTEME_WRITER_HPP
2#define BYTEME_WRITER_HPP
3
4#include <string>
5#include <cstring>
6#include <cstddef>
7
8#include "utils.hpp"
9
16namespace byteme {
17
21class Writer {
22public:
26 virtual ~Writer() = default;
27
36 virtual void write(const unsigned char* buffer, std::size_t n) = 0;
37
42 virtual void finish() = 0;
43};
44
45}
46
47#endif
Virtual class for writing bytes to a sink.
Definition Writer.hpp:21
virtual void finish()=0
virtual void write(const unsigned char *buffer, std::size_t n)=0
virtual ~Writer()=default
Simple byte readers and writers.
Definition BufferedReader.hpp:21