BDE 4.14.0 Production release
Loading...
Searching...
No Matches
bslma::SharedPtrInplaceRep_ImpUtil Struct Reference

#include <bslma_sharedptrinplacerep.h>

Static Public Member Functions

template<class TYPE >
static const TYPE & forward (const TYPE &reference)
 
template<class TYPE >
static BloombergLP::bslmf::MovableRef< TYPE > forward (const BloombergLP::bslmf::MovableRef< TYPE > &reference)
 
template<class TYPE >
static void * voidify (TYPE *address)
 
template<class TYPE >
static void dispose (const TYPE &object)
 Destroy the specified object.
 
template<class TYPE , size_t SIZE>
static void dispose (const TYPE(&object)[SIZE])
 Destroy each element of the specified object.
 

Detailed Description

This struct provides a namespace for several static methods that ease the implementation of many methods of the SharedPtrInplaceRep class.

Member Function Documentation

◆ dispose() [1/2]

template<class TYPE >
void bslma::SharedPtrInplaceRep_ImpUtil::dispose ( const TYPE &  object)
inlinestatic

◆ dispose() [2/2]

template<class TYPE , size_t SIZE>
void bslma::SharedPtrInplaceRep_ImpUtil::dispose ( const TYPE(&)  object[SIZE])
inlinestatic

◆ forward() [1/2]

template<class TYPE >
BloombergLP::bslmf::MovableRef< TYPE > bslma::SharedPtrInplaceRep_ImpUtil::forward ( const BloombergLP::bslmf::MovableRef< TYPE > &  reference)
inlinestatic

◆ forward() [2/2]

template<class TYPE >
const TYPE & bslma::SharedPtrInplaceRep_ImpUtil::forward ( const TYPE &  reference)
inlinestatic

Return the specified reference. Note that this pair of overloaded functions is necessary to correctly forward movable references when providing explicit move-semantics for C++03; otherwise the MovableRef is likely to be wrapped in multiple layers of reference wrappers, and not be recognized as the movable vocabulary type.

◆ voidify()

template<class TYPE >
void * bslma::SharedPtrInplaceRep_ImpUtil::voidify ( TYPE *  address)
inlinestatic

Return the specified address cast as a pointer to void, even if (the template parameter) TYPE is cv-qualified.


The documentation for this struct was generated from the following file: