Crypto++
8.6
Free C++ class library of cryptographic schemes
config_ns.h
Go to the documentation of this file.
1
// config_ns.h - written and placed in public domain by Jeffrey Walton
2
// the bits that make up this source file are from the
3
// library's monolithic config.h.
4
5
/// \file config_ns.h
6
/// \brief Library configuration file
7
/// \details <tt>config_ns.h</tt> provides defines for C++ and library
8
/// namespaces.
9
/// \details <tt>config.h</tt> was split into components in May 2019 to better
10
/// integrate with Autoconf and its feature tests. The splitting occurred so
11
/// users could continue to include <tt>config.h</tt> while allowing Autoconf
12
/// to write new <tt>config_asm.h</tt> and new <tt>config_cxx.h</tt> using
13
/// its feature tests.
14
/// \note You should include <tt>config.h</tt> rather than <tt>config_ns.h</tt>
15
/// directly.
16
/// \sa <A HREF="https://github.com/weidai11/cryptopp/issues/835">Issue 835,
17
/// Make config.h more autoconf friendly</A>,
18
/// <A HREF="https://www.cryptopp.com/wiki/Configure.sh">Configure.sh script</A>
19
/// on the Crypto++ wiki
20
/// \since Crypto++ 8.3
21
22
#ifndef CRYPTOPP_CONFIG_NAMESPACE_H
23
#define CRYPTOPP_CONFIG_NAMESPACE_H
24
25
// namespace support is now required
26
#ifdef NO_NAMESPACE
27
# error namespace support is now required
28
#endif
29
30
#ifdef CRYPTOPP_DOXYGEN_PROCESSING
31
32
/// \namespace CryptoPP
33
/// \brief Crypto++ library namespace
34
/// \details Nearly all classes are located in the CryptoPP namespace. Within
35
/// the namespace, there are four additional namespaces.
36
/// <ul>
37
/// <li>Name - namespace for names used with NameValuePairs and documented
38
/// in argnames.h
39
/// <li>NaCl - namespace for NaCl test functions like crypto_box,
40
/// crypto_box_open, crypto_sign, and crypto_sign_open
41
/// <li>Donna - namespace for curve25519 library operations. The name was
42
/// selected due to use of Langley and Moon's curve25519-donna.
43
/// <li>Test - namespace for testing and benchmarks classes
44
/// <li>Weak - namespace for weak and wounded algorithms, like ARC4, MD5
45
/// and Pananma
46
/// </ul>
47
/// \since Crypto++ 3.0
48
namespace
CryptoPP
{ }
49
50
// Bring in the symbols found in the weak namespace; and fold Weak1 into Weak
51
#define CRYPTOPP_ENABLE_NAMESPACE_WEAK 1
52
#define Weak1 Weak
53
// Avoid putting "CryptoPP::" in front of everything in Doxygen output
54
#define CryptoPP
55
#define NAMESPACE_BEGIN(x)
56
#define NAMESPACE_END
57
// Get Doxygen to generate better documentation for these typedefs
58
#define DOCUMENTED_TYPEDEF(x, y) class y : public x {}
59
// Make "protected" "private" so the functions and members are not documented
60
#define protected private
61
62
#else
63
// Not Doxygen
64
#define NAMESPACE_BEGIN(x) namespace x {
65
#define NAMESPACE_END }
66
#define DOCUMENTED_TYPEDEF(x, y) typedef x y
67
68
#endif // CRYPTOPP_DOXYGEN_PROCESSING
69
70
#define ANONYMOUS_NAMESPACE_BEGIN namespace {
71
#define ANONYMOUS_NAMESPACE_END }
72
#define USING_NAMESPACE(x) using namespace x;
73
#define DOCUMENTED_NAMESPACE_BEGIN(x) namespace x {
74
#define DOCUMENTED_NAMESPACE_END }
75
76
#endif // CRYPTOPP_CONFIG_NAMESPACE_H
CryptoPP
Crypto++ library namespace.
Generated on Sun Sep 26 2021 00:00:00 for Crypto++ by
1.8.20