17 #ifndef INCLUDED_BMQA_OPENQUEUESTATUS
18 #define INCLUDED_BMQA_OPENQUEUESTATUS
45 #include <bsl_iostream.h>
46 #include <bsl_string.h>
47 #include <bslma_allocator.h>
48 #include <bslma_default.h>
49 #include <bslma_usesbslmaallocator.h>
50 #include <bslmf_nestedtraitdeclaration.h>
51 #include <bsls_unspecifiedbool.h>
73 bsl::string d_errorDescription;
77 BSLMF_NESTED_TRAIT_DECLARATION(
OpenQueueStatus, bslma::UsesBslmaAllocator)
94 bslma::Allocator* allocator = 0);
100 bmqt::OpenQueueResult::Enum
result,
102 bslma::Allocator* allocator = 0);
119 bmqt::OpenQueueResult::Enum
result() const;
135 print(bsl::ostream& stream,
int level = 0,
int spacesPerLevel = 4) const;
152 bsl::ostream& operator<<(bsl::ostream& stream, const
OpenQueueStatus& rhs);
164 : d_queueId(allocator)
165 , d_result(bmqt::OpenQueueResult::e_SUCCESS)
166 , d_errorDescription(allocator)
172 bslma::Allocator* allocator)
173 : d_queueId(other.d_queueId, allocator)
174 , d_result(other.d_result)
175 , d_errorDescription(other.d_errorDescription, allocator)
182 const bsl::string& errorDescription,
183 bslma::Allocator* allocator)
184 : d_queueId(queueId, allocator)
186 , d_errorDescription(errorDescription)
196 d_result = other.
result();
204 return bsls::UnspecifiedBool<OpenQueueStatus>::makeValue(
220 return d_errorDescription;
229 return rhs.
print(stream, 0, -1);
242 return !(lhs == rhs);
Provide a value-semantic efficient identifier for a queue.
Provide enums for various publicly exposed result code.
Definition: bmqa_openqueuestatus.h:62
bsls::UnspecifiedBool< OpenQueueStatus >::BoolType BoolType
Definition: bmqa_openqueuestatus.h:84
bmqt::OpenQueueResult::Enum result() const
Definition: bmqa_openqueuestatus.h:213
const QueueId & queueId() const
Return the queueId associated to this operation result, if any.
Definition: bmqa_openqueuestatus.h:208
OpenQueueStatus & operator=(const OpenQueueStatus &rhs)
Assignment operator from the specified rhs.
Definition: bmqa_openqueuestatus.h:193
OpenQueueStatus(bslma::Allocator *allocator=0)
Default constructor, use the optionally specified allocator.
Definition: bmqa_openqueuestatus.h:163
const bsl::string & errorDescription() const
Definition: bmqa_openqueuestatus.h:218
bsl::ostream & print(bsl::ostream &stream, int level=0, int spacesPerLevel=4) const
Value-semantic efficient identifier for a queue.
Definition: bmqa_queueid.h:59
bool operator!=(const CloseQueueStatus &lhs, const CloseQueueStatus &rhs)
Definition: bmqa_closequeuestatus.h:240
bool operator==(const CloseQueueStatus &lhs, const CloseQueueStatus &rhs)
Definition: bmqa_closequeuestatus.h:233
bsl::ostream & operator<<(bsl::ostream &stream, const CloseQueueStatus &rhs)
Definition: bmqa_closequeuestatus.h:227
Definition: bmqa_abstractsession.h:42
Enum
Definition: bmqt_resultcode.h:137
@ e_SUCCESS
Definition: bmqt_resultcode.h:139