This class provides a specialized proctor object that, upon destruction and unless the release method has been called, bit‐wise moves the elements in a segment of an array of parameterized OBJECT_TYPE back to some destination, and destroys some other elements in an adjacent segment of the same array. The elements destroyed are delimited by the range [ begin(), middle() )] and those moved to destination() and in the range [ middle(), end() )]. Note that, once constructed, begin() and end() remain fixed. As the guard advances, middle() and destination() move, reflecting the successful transfer of data between the moving range and the destination.
Synopsis
Declared in <bslalg_autoarraymovedestructor.h>
template<
class OBJECT_TYPE,
class ALLOCATOR = bsl::allocator<OBJECT_TYPE>>
class AutoArrayMoveDestructor;
Member Functions
Name |
Description |
|
TBD: document the |
|
Bit‐wise move the range |
Increment both middle and destination pointers by one position. The behavior is undefined if this operation result in |
|
Return the address at the beginning of the guarded range. |
|
Return the destination address, to which the second portion of the guarded range, delimited by |
|
Return the address at the end of the guarded range. |
|
Return the address at the middle of the guarded range. |
Created with MrDocs