1#pragma once
2
3#include <Compression/ICompressionCodec.h>
4
5namespace DB
6{
7
8class CompressionCodecMultiple final : public ICompressionCodec
9{
10public:
11 CompressionCodecMultiple() = default;
12 explicit CompressionCodecMultiple(Codecs codecs_);
13
14 UInt8 getMethodByte() const override;
15
16 String getCodecDesc() const override;
17
18 UInt32 getMaxCompressedDataSize(UInt32 uncompressed_size) const override;
19
20 void useInfoAboutType(DataTypePtr data_type) override;
21
22protected:
23 UInt32 doCompressData(const char * source, UInt32 source_size, char * dest) const override;
24
25 void doDecompressData(const char * source, UInt32 source_size, char * dest, UInt32 uncompressed_size) const override;
26
27private:
28 Codecs codecs;
29
30};
31
32
33class CompressionCodecFactory;
34void registerCodecMultiple(CompressionCodecFactory & factory);
35
36}
37