#include <coder.hpp>
|
| virtual | ~Encoder ()=default |
| |
| virtual bool | encode_string (const std::string &decoded, std::string &encoded) |
| |
| virtual bool | encode_file (const std::filesystem::path &decoded, const std::filesystem::path &encoded) |
| |
Virtual interface to encode a string or file with a binary encoder. Coders for specific algorithms should inherit from this class to perform encoding.
- Author
- Timothy Flynn (trfly.nosp@m.nn89.nosp@m.@pm.m.nosp@m.e)
- Version
- May 3, 2020
◆ encode_binary()
| virtual bool fly::coders::BinaryEncoder::encode_binary |
( |
std::istream & |
decoded, |
|
|
fly::BitStreamWriter & |
encoded |
|
) |
| |
|
protectedpure virtual |
Encode a stream.
- Parameters
-
| decoded | Stream holding the contents to encode. |
| encoded | Stream to store the encoded contents. |
- Returns
- True if the input stream was successfully encoded.
Implemented in fly::coders::HuffmanEncoder.
◆ encode_internal()
| bool fly::coders::BinaryEncoder::encode_internal |
( |
std::istream & |
decoded, |
|
|
std::ostream & |
encoded |
|
) |
| |
|
finalprotectedvirtual |
Encode a stream.
- Parameters
-
| decoded | Stream holding the contents to encode. |
| encoded | Stream to store the encoded contents. |
- Returns
- True if the input stream was successfully encoded.
Implements fly::coders::Encoder.
The documentation for this class was generated from the following files: