8#ifndef INCLUDED_S_BALTST_BASICRECORD
9#define INCLUDED_S_BALTST_BASICRECORD
43#include <bslalg_typetraits.h>
59#include <bsl_string.h>
61#include <bsl_iosfwd.h>
62#include <bsl_limits.h>
66namespace bslma {
class Allocator; }
68namespace s_baltst {
class BasicRecord; }
143#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
144 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
168#if defined(BSLS_COMPILERFEATURES_SUPPORT_RVALUE_REFERENCES) \
169 && defined(BSLS_COMPILERFEATURES_SUPPORT_NOEXCEPT)
186 template <
typename t_MANIPULATOR>
195 template <
typename t_MANIPULATOR>
204 template <
typename t_MANIPULATOR>
235 bsl::ostream&
print(bsl::ostream& stream,
237 int spacesPerLevel = 4)
const;
245 template <
typename t_ACCESSOR>
253 template <
typename t_ACCESSOR>
262 template <
typename t_ACCESSOR>
265 int nameLength)
const;
288 return lhs.isEqualTo(rhs);
294 return !(lhs == rhs);
302 return rhs.print(stream, 0, -1);
326bool BasicRecord::isEqualTo(
const BasicRecord& rhs)
const
328 return this->
i1() == rhs.i1() &&
329 this->
i2() == rhs.i2() &&
330 this->
dt() == rhs.dt() &&
331 this->
s() == rhs.s();
336template <
typename t_MANIPULATOR>
364template <
typename t_MANIPULATOR>
367 enum { NOT_FOUND = -1 };
387template <
typename t_MANIPULATOR>
389 t_MANIPULATOR& manipulator,
393 enum { NOT_FOUND = -1 };
397 if (0 == attributeInfo) {
429template <
typename t_ACCESSOR>
457template <
typename t_ACCESSOR>
460 enum { NOT_FOUND = -1 };
480template <
typename t_ACCESSOR>
482 t_ACCESSOR& accessor,
484 int nameLength)
const
486 enum { NOT_FOUND = -1 };
490 if (0 == attributeInfo) {
Definition bdlt_datetimetz.h:308
Definition bslstl_string.h:1252
Definition bslma_allocator.h:545
Definition s_baltst_basicrecord.h:78
static const char CLASS_NAME[]
Definition s_baltst_basicrecord.h:110
bdlt::DatetimeTz & dt()
Return a reference to the modifiable "Dt" attribute of this object.
Definition s_baltst_basicrecord.h:417
bsl::string & s()
Return a reference to the modifiable "S" attribute of this object.
Definition s_baltst_basicrecord.h:423
friend bool operator!=(const BasicRecord &lhs, const BasicRecord &rhs)
Returns !(lhs == rhs)
Definition s_baltst_basicrecord.h:292
BasicRecord(bslma::Allocator *basicAllocator=0)
BasicRecord & operator=(const BasicRecord &rhs)
Assign to this object the value of the specified rhs object.
int accessAttributes(t_ACCESSOR &accessor) const
Definition s_baltst_basicrecord.h:430
~BasicRecord()
Destroy this object.
static const bdlat_AttributeInfo * lookupAttributeInfo(const char *name, int nameLength)
int & i1()
Return a reference to the modifiable "I1" attribute of this object.
Definition s_baltst_basicrecord.h:405
bsl::ostream & print(bsl::ostream &stream, int level=0, int spacesPerLevel=4) const
static const bdlat_AttributeInfo ATTRIBUTE_INFO_ARRAY[]
Definition s_baltst_basicrecord.h:112
int & i2()
Return a reference to the modifiable "I2" attribute of this object.
Definition s_baltst_basicrecord.h:411
friend bool operator==(const BasicRecord &lhs, const BasicRecord &rhs)
Definition s_baltst_basicrecord.h:286
@ NUM_ATTRIBUTES
Definition s_baltst_basicrecord.h:99
static const bdlat_AttributeInfo * lookupAttributeInfo(int id)
@ ATTRIBUTE_ID_I2
Definition s_baltst_basicrecord.h:93
@ ATTRIBUTE_ID_S
Definition s_baltst_basicrecord.h:95
@ ATTRIBUTE_ID_I1
Definition s_baltst_basicrecord.h:92
@ ATTRIBUTE_ID_DT
Definition s_baltst_basicrecord.h:94
int manipulateAttribute(t_MANIPULATOR &manipulator, int id)
Definition s_baltst_basicrecord.h:365
BasicRecord(const BasicRecord &original, bslma::Allocator *basicAllocator=0)
friend bsl::ostream & operator<<(bsl::ostream &stream, const BasicRecord &rhs)
Definition s_baltst_basicrecord.h:299
int accessAttribute(t_ACCESSOR &accessor, int id) const
Definition s_baltst_basicrecord.h:458
@ ATTRIBUTE_INDEX_I2
Definition s_baltst_basicrecord.h:104
@ ATTRIBUTE_INDEX_S
Definition s_baltst_basicrecord.h:106
@ ATTRIBUTE_INDEX_DT
Definition s_baltst_basicrecord.h:105
@ ATTRIBUTE_INDEX_I1
Definition s_baltst_basicrecord.h:103
int manipulateAttributes(t_MANIPULATOR &manipulator)
Definition s_baltst_basicrecord.h:337
#define BDLAT_DECL_SEQUENCE_WITH_ALLOCATOR_BITWISEMOVEABLE_TRAITS(ClassName)
Definition bdlat_typetraits.h:301
#define BSLS_IDENT_RCSID(tag, str)
BSLS_IDENT_RCSID() - insert ident str (specific to platform/compiler)
Definition bsls_ident.h:244
#define BSLS_IDENT_PRAGMA_ONCE
BSLS_IDENT_PRAGMA_ONCE - macro to avoid multiple inclusion
Definition bsls_ident.h:263
Definition baljsn_encoder_testtypes.h:76
Definition s_baltst_address.h:66
Definition bdlat_attributeinfo.h:139
int d_id
Definition bdlat_attributeinfo.h:142
Definition bdlat_typetraits.h:146