Stroika Library
3.0d16
Help-Home
Loading...
Searching...
No Matches
Deflate.h
Go to the documentation of this file.
1
/*
2
* Copyright(c) Sophist Solutions, Inc. 1990-2025. All rights reserved
3
*/
4
#ifndef _Stroika_Foundation_DataExchange_Compression_Deflate_h_
5
#define _Stroika_Foundation_DataExchange_Compression_Deflate_h_ 1
6
7
#include "Stroika/Foundation/StroikaPreComp.h"
8
9
#include "
Stroika/Foundation/DataExchange/Compression/Common.h
"
10
11
/**
12
* \file
13
*
14
* https://en.wikipedia.org/wiki/Deflate
15
*
16
* \note Code-Status: <a href="Code-Status.md#Beta">Beta</a>
17
*/
18
19
namespace
Stroika::Foundation::DataExchange::Compression::Deflate {
20
21
/**
22
* Check at compile time if deflate is supported.
23
*/
24
constexpr
bool
kSupported
=
25
#if qStroika_HasComponent_zlib
26
true
27
#else
28
false
29
#endif
30
;
31
32
/**
33
* \par Example Usage
34
* \code
35
* Memory::BLOB kSample1_ = Memory::BLOB::Hex ("aa1234abcd01010102030405");
36
* Memory::BLOB compressed = Compression::Deflate::Compress::New ().Transform (kSample1_);
37
* Assert (kSample1_ == Compression::Compression::Deflate::Decompress::New ().Transform (compressed));
38
* \endcode
39
*
40
* \note if not kSupported, these 'New ()' functions just throw FeatureNotSupportedException{}
41
*/
42
namespace
Compress {
43
using
Compression::Compress::Options;
44
Ptr New (
const
Options& o = {});
45
}
46
namespace
Decompress {
47
using
Compression::Decompress::Options;
48
Ptr New (
const
Options& o = {});
49
}
50
51
}
52
53
/*
54
********************************************************************************
55
***************************** Implementation Details ***************************
56
********************************************************************************
57
*/
58
59
#endif
/*_Stroika_Foundation_DataExchange_Compression_Deflate_h_*/
Stroika::Foundation::DataExchange::Compression::Deflate::kSupported
constexpr bool kSupported
Definition
Deflate.h:24
Common.h
Library
Sources
Stroika
Foundation
DataExchange
Compression
Deflate.h
Generated by
1.9.8