8#ifndef INCLUDED_S_BALTST_TOPCHOICE
9#define INCLUDED_S_BALTST_TOPCHOICE
43#include <bslalg_typetraits.h>
59#include <bsl_vector.h>
67#include <bsl_iosfwd.h>
68#include <bsl_limits.h>
72namespace bslma {
class Allocator; }
74namespace s_baltst {
class Topchoice; }
161#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
162 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
186#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
187 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
211#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
212 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
221#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
222 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
231#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
232 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
241#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
242 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
251#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
252 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
261#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
262 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
277#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
278 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
290 template<
class MANIPULATOR>
346 bsl::ostream&
print(bsl::ostream& stream,
348 int spacesPerLevel = 4)
const;
358 template<
class ACCESSOR>
480: d_selectionId(SELECTION_ID_UNDEFINED)
481, d_allocator_p(
bslma::Default::allocator(basicAllocator))
492template <
class MANIPULATOR>
495 switch (d_selectionId) {
586 return d_selectionId;
589template <
class ACCESSOR>
592 switch (d_selectionId) {
744 case Class::SELECTION_ID_SELECTION1:
746 case Class::SELECTION_ID_SELECTION2:
748 case Class::SELECTION_ID_SELECTION3:
750 case Class::SELECTION_ID_SELECTION4:
752 case Class::SELECTION_ID_SELECTION5:
754 case Class::SELECTION_ID_SELECTION6:
756 case Class::SELECTION_ID_SELECTION7:
758 case Class::SELECTION_ID_SELECTION8:
775 return !(lhs == rhs);
780 bsl::ostream& stream,
783 return rhs.
print(stream, 0, -1);
Definition bdlt_datetimetz.h:308
Definition bslstl_vector.h:1025
Definition bslma_allocator.h:457
Definition s_baltst_ratsnest.h:984
Definition s_baltst_customstring.h:71
Definition s_baltst_ratsnest.h:2224
Definition s_baltst_ratsnest.h:2474
Definition s_baltst_ratsnest.h:95
Definition s_baltst_topchoice.h:81
s_baltst::CustomString & makeSelection6()
@ SELECTION_INDEX_SELECTION6
Definition s_baltst_topchoice.h:123
@ SELECTION_INDEX_SELECTION8
Definition s_baltst_topchoice.h:125
@ SELECTION_INDEX_SELECTION3
Definition s_baltst_topchoice.h:120
@ SELECTION_INDEX_SELECTION7
Definition s_baltst_topchoice.h:124
@ SELECTION_INDEX_SELECTION2
Definition s_baltst_topchoice.h:119
@ SELECTION_INDEX_SELECTION5
Definition s_baltst_topchoice.h:122
@ SELECTION_INDEX_SELECTION1
Definition s_baltst_topchoice.h:118
@ SELECTION_INDEX_SELECTION4
Definition s_baltst_topchoice.h:121
bsls::ObjectBuffer< bsl::vector< char > > d_selection2
Definition s_baltst_topchoice.h:86
bsls::ObjectBuffer< s_baltst::CustomString > d_selection6
Definition s_baltst_topchoice.h:90
s_baltst::Sequence1 & makeSelection1()
const char * selectionName() const
Return the symbolic name of the current selection of this object.
bsls::ObjectBuffer< bdlt::DatetimeTz > d_selection5
Definition s_baltst_topchoice.h:89
s_baltst::Sequence3 * d_selection4
Definition s_baltst_topchoice.h:88
bool isSelection1Value() const
Definition s_baltst_topchoice.h:680
bdlt::DatetimeTz & makeSelection5(const bdlt::DatetimeTz &value)
static const char CLASS_NAME[]
Definition s_baltst_topchoice.h:129
s_baltst::Sequence2 & makeSelection3()
s_baltst::CustomString & selection6()
Definition s_baltst_topchoice.h:562
bool isSelection8Value() const
Definition s_baltst_topchoice.h:722
bool isUndefinedValue() const
Definition s_baltst_topchoice.h:728
bool isSelection4Value() const
Definition s_baltst_topchoice.h:698
bool isSelection7Value() const
Definition s_baltst_topchoice.h:716
s_baltst::Sequence1 & makeSelection1(const s_baltst::Sequence1 &value)
bool isSelection6Value() const
Definition s_baltst_topchoice.h:710
@ NUM_SELECTIONS
Definition s_baltst_topchoice.h:114
int accessSelection(ACCESSOR &accessor) const
Definition s_baltst_topchoice.h:590
s_baltst::Sequence1 & selection1()
Definition s_baltst_topchoice.h:527
bsl::vector< char > & selection2()
Definition s_baltst_topchoice.h:534
int makeSelection(const char *name, int nameLength)
Topchoice(bslma::Allocator *basicAllocator=0)
Definition s_baltst_topchoice.h:479
s_baltst::Enumerated::Value & selection7()
Definition s_baltst_topchoice.h:569
bool isSelection2Value() const
Definition s_baltst_topchoice.h:686
static const bdlat_SelectionInfo * lookupSelectionInfo(const char *name, int nameLength)
@ SELECTION_ID_SELECTION8
Definition s_baltst_topchoice.h:110
@ SELECTION_ID_UNDEFINED
Definition s_baltst_topchoice.h:102
@ SELECTION_ID_SELECTION5
Definition s_baltst_topchoice.h:107
@ SELECTION_ID_SELECTION2
Definition s_baltst_topchoice.h:104
@ SELECTION_ID_SELECTION1
Definition s_baltst_topchoice.h:103
@ SELECTION_ID_SELECTION3
Definition s_baltst_topchoice.h:105
@ SELECTION_ID_SELECTION4
Definition s_baltst_topchoice.h:106
@ SELECTION_ID_SELECTION7
Definition s_baltst_topchoice.h:109
@ SELECTION_ID_SELECTION6
Definition s_baltst_topchoice.h:108
s_baltst::Choice3 & makeSelection8(const s_baltst::Choice3 &value)
s_baltst::Sequence2 & makeSelection3(const s_baltst::Sequence2 &value)
bdlt::DatetimeTz & makeSelection5()
bsls::ObjectBuffer< s_baltst::Sequence2 > d_selection3
Definition s_baltst_topchoice.h:87
Topchoice(const Topchoice &original, bslma::Allocator *basicAllocator=0)
int selectionId() const
Definition s_baltst_topchoice.h:584
s_baltst::Sequence3 & selection4()
Definition s_baltst_topchoice.h:548
bool isSelection5Value() const
Definition s_baltst_topchoice.h:704
int manipulateSelection(MANIPULATOR &manipulator)
Definition s_baltst_topchoice.h:493
s_baltst::Sequence3 & makeSelection4()
bsls::ObjectBuffer< s_baltst::Choice3 > d_selection8
Definition s_baltst_topchoice.h:92
bsls::ObjectBuffer< s_baltst::Sequence1 > d_selection1
Definition s_baltst_topchoice.h:85
s_baltst::Enumerated::Value & makeSelection7(s_baltst::Enumerated::Value value)
Topchoice & operator=(const Topchoice &rhs)
Assign to this object the value of the specified rhs object.
static const bdlat_SelectionInfo SELECTION_INFO_ARRAY[]
Definition s_baltst_topchoice.h:131
s_baltst::Enumerated::Value & makeSelection7()
bsls::ObjectBuffer< s_baltst::Enumerated::Value > d_selection7
Definition s_baltst_topchoice.h:91
static const bdlat_SelectionInfo * lookupSelectionInfo(int id)
bdlt::DatetimeTz & selection5()
Definition s_baltst_topchoice.h:555
s_baltst::Choice3 & selection8()
Definition s_baltst_topchoice.h:576
~Topchoice()
Destroy this object.
Definition s_baltst_topchoice.h:486
int makeSelection(int selectionId)
s_baltst::Sequence3 & makeSelection4(const s_baltst::Sequence3 &value)
bsl::ostream & print(bsl::ostream &stream, int level=0, int spacesPerLevel=4) const
bsl::vector< char > & makeSelection2(const bsl::vector< char > &value)
bool isSelection3Value() const
Definition s_baltst_topchoice.h:692
s_baltst::CustomString & makeSelection6(const s_baltst::CustomString &value)
s_baltst::Sequence2 & selection3()
Definition s_baltst_topchoice.h:541
bsl::vector< char > & makeSelection2()
s_baltst::Choice3 & makeSelection8()
#define BDLAT_DECL_CHOICE_WITH_ALLOCATOR_BITWISEMOVEABLE_TRAITS(ClassName)
Definition bdlat_typetraits.h:249
#define BSLS_ASSERT(X)
Definition bsls_assert.h:1804
#define BSLS_IDENT_RCSID(tag, str)
Definition bsls_ident.h:260
#define BSLS_IDENT_PRAGMA_ONCE
Definition bsls_ident.h:310
Definition balxml_encoderoptions.h:68
Definition s_baltst_address.h:66
bool operator!=(const Address &lhs, const Address &rhs)
bool operator==(const Address &lhs, const Address &rhs)
bsl::ostream & operator<<(bsl::ostream &stream, const Address &rhs)
Definition bdlat_selectioninfo.h:136
Value
Definition s_baltst_enumerated.h:71
TYPE & object()
Definition bsls_objectbuffer.h:351