| 266 | } |
| 267 | |
| 268 | Result<int64_t> Compress(int64_t input_len, const uint8_t* input, |
| 269 | int64_t output_buffer_len, uint8_t* output_buffer) override { |
| 270 | auto output_len = |
| 271 | LZ4F_compressFrame(output_buffer, static_cast<size_t>(output_buffer_len), input, |
| 272 | static_cast<size_t>(input_len), &prefs_); |
| 273 | if (LZ4F_isError(output_len)) { |
| 274 | return LZ4Error(output_len, "Lz4 compression failure: "); |
| 275 | } |
| 276 | return static_cast<int64_t>(output_len); |
| 277 | } |
| 278 | |
| 279 | Result<int64_t> Decompress(int64_t input_len, const uint8_t* input, |
| 280 | int64_t output_buffer_len, uint8_t* output_buffer) override { |
nothing calls this directly
no test coverage detected