Go to the documentation of this file.
9 #ifndef EAGINE_SERIALIZE_PACKED_BLOCK_SINK_HPP
10 #define EAGINE_SERIALIZE_PACKED_BLOCK_SINK_HPP
12 #include "../compression.hpp"
31 , _compressor{std::move(compressor)} {}
53 #endif // EAGINE_SERIALIZE_PACKED_BLOCK_SINK_HPP
auto finalize() -> serialization_errors final
Does additional finalization, like compression after serialization operation.
Definition: packed_block_sink.hpp:39
Common code is placed in this namespace.
Definition: eagine.hpp:21
Class for manipulating and testing a group of enumeration-based bits.
Definition: bitfield.hpp:19
Serialization data sink backed by a pre-allocated memory block.
Definition: block_sink.hpp:23
auto done() const noexcept -> memory::block
Returns the part of the backing block already written to.
Definition: block_sink.hpp:43
basic_block< false > block
Alias for non-const byte memory span.
Definition: block.hpp:27
auto replace_with(memory::const_block blk) -> serialization_errors
Replaces the content of the backing block with the content of the argument.
Definition: block_sink.hpp:77
packed_block_data_sink(data_compressor compressor, memory::block dst) noexcept
Constructor setting the backing block and data compressor.
Definition: packed_block_sink.hpp:27
Non-owning view of a contiguous range of memory with ValueType elements.
Definition: flatten_fwd.hpp:16
Packing serialization data sink backed by a pre-allocated memory block.
Definition: packed_block_sink.hpp:21
auto compress(memory::const_block input, const data_handler &handler, data_compression_level level) -> bool
Compress the input block, passing the packed data to handler.
Class implementing data compression and decompresson.
Definition: compression.hpp:37
packed_block_data_sink() noexcept=default
Default constructor.
@ backend_error
Internal error in the serialization backend.
@ normal
Normal compression level.