BDE 4.14.0 Production release
|
#include <bdld_datum.h>
Public Types | |
typedef const bdld::Datum | element_type |
typedef bdld::Datum | value_type |
typedef bsl::size_t | size_type |
typedef bsl::ptrdiff_t | difference_type |
typedef element_type * | pointer |
typedef const element_type * | const_pointer |
typedef element_type & | reference |
typedef const element_type & | const_reference |
typedef pointer | iterator |
typedef const_pointer | const_iterator |
typedef bsl::reverse_iterator< iterator > | reverse_iterator |
typedef bsl::reverse_iterator< const_iterator > | const_reverse_iterator |
typedef Datum::SizeType | SizeType |
This class
provides a read-only view to an array of datums. It holds the array by a const
pointer and an integral length value. It acts as return value for accessors inside the Datum
class that return an array of datums. Note that zero-length arrays are valid.
See bdld_datum
typedef const element_type* bdld::DatumArrayRef::const_pointer |
typedef const element_type& bdld::DatumArrayRef::const_reference |
typedef bsl::reverse_iterator<const_iterator> bdld::DatumArrayRef::const_reverse_iterator |
typedef bsl::ptrdiff_t bdld::DatumArrayRef::difference_type |
typedef const bdld::Datum bdld::DatumArrayRef::element_type |
typedef pointer bdld::DatumArrayRef::iterator |
typedef element_type* bdld::DatumArrayRef::pointer |
typedef bsl::reverse_iterator<iterator> bdld::DatumArrayRef::reverse_iterator |
typedef bsl::size_t bdld::DatumArrayRef::size_type |
SizeType
is an alias for an unsigned integral value, representing the length of a datum array.
|
inline |
Create a DatumArrayRef
object having the specified data
and length
. The behavior is undefined unless 0 != data
or 0 == length
. Note that the pointer to the array is just copied.
|
default |
Create a DatumArrayRef
object having the value of the specified original
object.
|
default |
|
inline |
Return a reference providing non-modifiable access to the last element of the array this reference object represents. The behavior is undefined unless size() > 0
.
|
inline |
bdld::DatumArrayRef::BSLMF_NESTED_TRAIT_DECLARATION | ( | DatumArrayRef | , |
bdlb::HasPrintMethod | |||
) |
bdld::DatumArrayRef::BSLMF_NESTED_TRAIT_DECLARATION | ( | DatumArrayRef | , |
bsl::is_trivially_copyable | |||
) |
|
inline |
Return an iterator providing non-modifiable access to the first element of the array this reference object represents; return a past-the-end iterator if size() == 0
.
|
inline |
Return an iterator providing non-modifiable access pointing past-the-end of the array this reference object represents.
|
inline |
Return a reverse iterator providing non-modifiable access to the last element of the array this reference object represents, and the past-the-end reverse iterator if size() == 0
.
|
inline |
Return a reverse iterator providing non-modifiable access pointing past-the-end of the array this reference object represents.
|
inline |
Return the address providing non-modifiable access to the first element of the array this reference object represents. Return a valid pointer which cannot be dereferenced if the size() == 0
.
|
inline |
|
inline |
|
inline |
Return a reference providing non-modifiable access to the first element of the array this reference object represents. The behavior is undefined unless size() > 0
.
|
inline |
|
default |
|
inline |
Return a reference providing non-modifiable access to the element at the specified position
in the array this reference object represents. The behavior is undefined unless position < size()
.
bsl::ostream & bdld::DatumArrayRef::print | ( | bsl::ostream & | stream, |
int | level = 0 , |
||
int | spacesPerLevel = 4 |
||
) | const |
Write the value of this object to the specified output stream
in a human-readable format, and return a reference to the modifiable stream
. Optionally specify an initial indentation level
, whose absolute value is incremented recursively for nested objects. If level
is specified, optionally specify spacesPerLevel
, whose absolute value indicates the number of spaces per indentation level for this and all of its nested objects. If level
is negative, suppress indentation of the first line. If spacesPerLevel
is negative, format the entire output on one line, suppressing all but the initial indentation (as governed by level
). If stream
is not valid on entry, this operation has no effect. Note that this human-readable format is not fully specified, and can change without notice.
|
inline |
|
inline |
|
inline |
Return a const-pointer to the number of elements of the array this reference object represents.