TEC
A lightweight C++ library enabling safe, efficient execution in multithreaded and concurrent systems.
Loading...
Searching...
No Matches
tec_compression.hpp
Go to the documentation of this file.
1
// Time-stamp: <Last changed 2026-02-20 16:20:58 by magnolia>
2
/*----------------------------------------------------------------------
3
------------------------------------------------------------------------
4
Copyright (c) 2020-2026 The Emacs Cat (https://github.com/olddeuteronomy/tec).
5
6
Licensed under the Apache License, Version 2.0 (the "License");
7
you may not use this file except in compliance with the License.
8
You may obtain a copy of the License at
9
10
http://www.apache.org/licenses/LICENSE-2.0
11
12
Unless required by applicable law or agreed to in writing, software
13
distributed under the License is distributed on an "AS IS" BASIS,
14
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
See the License for the specific language governing permissions and
16
limitations under the License.
17
------------------------------------------------------------------------
18
----------------------------------------------------------------------*/
26
#pragma once
27
28
#include <cstddef>
29
30
31
namespace
tec {
32
33
34
struct
CompressionParams
{
35
// Compression type, 0..15
36
static
constexpr
int
kNoCompression{0};
37
static
constexpr
int
kCompressionZlib{1};
38
39
static
constexpr
int
kDefaultCompression{kNoCompression};
40
41
// Compression level, 0..9
42
static
constexpr
int
kCompressionLevelMin{0};
43
static
constexpr
int
kCompressionLevelMax{9};
44
45
static
constexpr
int
kDefaultCompressionLevel{4};
46
47
// Minimum data size in bytes for compression.
48
static
constexpr
size_t
kMinSize{128};
49
};
50
51
52
}
// namespace tec
tec::CompressionParams
Definition
tec_compression.hpp:34
net
tec_compression.hpp
Generated by
1.9.8