BDE 4.14.0 Production release
Loading...
Searching...
No Matches
s_baltst_featuretestmessageutil.h
Go to the documentation of this file.
1/// @file s_baltst_featuretestmessageutil.h
2///
3/// The content of this file has been pre-processed for Doxygen.
4///
5
6
7// s_baltst_featuretestmessageutil.h -*-C++-*-
8#ifndef INCLUDED_S_BALTST_FEATURETESTMESSAGEUTIL
9#define INCLUDED_S_BALTST_FEATURETESTMESSAGEUTIL
10
11#include <bsls_ident.h>
12BSLS_IDENT("$Id: $")
13
14/// @defgroup s_baltst_featuretestmessageutil s_baltst_featuretestmessageutil
15/// @brief Provide utilities for testing codecs with feature-test messages.
16/// @addtogroup Standalones
17/// @{
18/// @addtogroup s_baltst
19/// @{
20/// @addtogroup s_baltst_featuretestmessageutil
21/// @{
22///
23/// <h1> Outline </h1>
24/// * <a href="#s_baltst_featuretestmessageutil-purpose"> Purpose</a>
25/// * <a href="#s_baltst_featuretestmessageutil-classes"> Classes </a>
26/// * <a href="#s_baltst_featuretestmessageutil-description"> Description </a>
27///
28/// # Purpose {#s_baltst_featuretestmessageutil-purpose}
29/// Provide utilities for testing codecs with feature-test messages.
30///
31/// # Classes {#s_baltst_featuretestmessageutil-classes}
32///
33/// - s_baltst::FeatureTestMessageUtil: utilities for feature-test messages
34///
35/// @see s_baltst_featuretestmessage
36///
37/// # Description {#s_baltst_featuretestmessageutil-description}
38/// This component provides a utility `struct`,
39/// `s_baltst::FeatureTestMessageUtil`, that provides the encoded representation
40/// of many `s_baltst::FeatureTestMessage` values in 3 different formats:
41/// pretty JSON, compact JSON, and XML. These encoded representations may be
42/// incorporated into the testing infrastructure of codecs.
43/// @}
44/** @} */
45/** @} */
46
47/** @addtogroup Standalones
48 * @{
49 */
50/** @addtogroup s_baltst
51 * @{
52 */
53/** @addtogroup s_baltst_featuretestmessageutil
54 * @{
55 */
56
57#include <bsls_platform.h>
58
59
60namespace s_baltst {
61
62 // =============================
63 // struct FeatureTestMessageUtil
64 // =============================
65
66/// This utility `struct` provides a namespace for a set of encoded
67/// representations of `s_baltst::FeatureTestMessage` objects in 3
68/// different formats: pretty JSON, compact JSON, and XML. The
69/// `s_COMPACT_JSON_MESSAGES`, `s_PRETTY_JSON_MESSAGES`, and
70/// `s_XML_MESSAGES` static data members provide these sets as arrays of
71/// string literals. For all integer indices `0 <= i < k_NUM_MESSAGES`, the
72/// string literal at index `i` in each array is an encoded representation
73/// of the same value.
75
76 // TYPES
77 enum {
78#ifdef BSLS_PLATFORM_OS_WINDOWS
79 k_NUM_MESSAGES = 68,
80#else
82#endif
83 // the number of encoded values stored the
84 // 's_COMPACT_JSON_MESSAGES', 's_PRETTY_JSON_MESSAGES', and
85 // 's_XML_MESSAGES' arrays
86 };
87
88 // CLASS DATA
89
90 /// an array of `s_baltst::FeatureTestMessage` values encoded in
91 /// human-readable ("pretty") JSON
93
94 /// an array of `s_baltst::FeatureTestMessage` values encoded in
95 /// JSON having no unnecessary whitespace
97
98 /// an array of `s_baltst::FeatureTestMessage` values encoded in
99 /// human-readable ("pretty") XML
100 static const char *s_XML_MESSAGES[k_NUM_MESSAGES];
101};
102
103
104} // close package namespace
105
106#endif // ! defined(INCLUDED_S_BALTST_FEATURETESTMESSAGEUTIL)
107
108// ----------------------------------------------------------------------------
109// Copyright 2020 Bloomberg Finance L.P.
110//
111// Licensed under the Apache License, Version 2.0 (the "License");
112// you may not use this file except in compliance with the License.
113// You may obtain a copy of the License at
114//
115// http://www.apache.org/licenses/LICENSE-2.0
116//
117// Unless required by applicable law or agreed to in writing, software
118// distributed under the License is distributed on an "AS IS" BASIS,
119// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
120// See the License for the specific language governing permissions and
121// limitations under the License.
122// ----------------------------- END-OF-FILE ----------------------------------
123
124/** @} */
125/** @} */
126/** @} */
#define BSLS_IDENT(str)
Definition bsls_ident.h:195
Definition s_baltst_address.h:66
Definition s_baltst_featuretestmessageutil.h:74
static const char * s_PRETTY_JSON_MESSAGES[k_NUM_MESSAGES]
Definition s_baltst_featuretestmessageutil.h:96
static const char * s_COMPACT_JSON_MESSAGES[k_NUM_MESSAGES]
Definition s_baltst_featuretestmessageutil.h:92
@ k_NUM_MESSAGES
Definition s_baltst_featuretestmessageutil.h:81
static const char * s_XML_MESSAGES[k_NUM_MESSAGES]
Definition s_baltst_featuretestmessageutil.h:100