#pragma once

#include <iostream>
#include <stdexcept>
#include <algorithm>
#include <vector>
#define ZSTD_STATIC_LINKING_ONLY
#include <zstd.h>

#if ZSTD_VERSION_NUMBER < 10400
#error "Wymagane zstd >= 1.4.0 dla ZSTD_c_format / ZSTD_f_zstd1_magicless"
#endif

#define COMPRESSION_LEVEL   3 

class CompressionManager
{
public:
	CompressionManager();
	~CompressionManager();

	std::vector<char> compress(const std::vector<char>&);
	std::vector<char> decompress(const std::vector<char>&, const size_t&);

private:
	ZSTD_CCtx* cctx;
	ZSTD_DCtx* dctx;
};

