Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions
CLHEP::sp::ctrl_block_pd< P, D > Class Template Reference

#include <memory.h>

Inheritance diagram for CLHEP::sp::ctrl_block_pd< P, D >:
CLHEP::sp::abstract_ctrl_block CLHEP::noncopyable

Public Member Functions

 ctrl_block_pd (P *, D)
 
 ~ctrl_block_pd () throw ()
 
voidoperator new (std::size_t)
 
void operator delete (void *)
 
virtual voidget_deleter (std::type_info const &)
 
virtual void dispose () throw ()
 
- Public Member Functions inherited from CLHEP::sp::abstract_ctrl_block
void class_invariant () const throw ()
 
 abstract_ctrl_block ()
 
virtual ~abstract_ctrl_block () throw ()
 
void add_ref ()
 
bool add_ref_lock ()
 
void weak_add_ref () throw ()
 
void release () throw ()
 
void weak_release () throw ()
 
virtual void destroy () throw ()
 
long use_count () const throw ()
 

Additional Inherited Members

- Protected Member Functions inherited from CLHEP::noncopyable
 noncopyable () throw ()
 
 ~noncopyable () throw ()
 

Detailed Description

template<typename P, typename D>
class CLHEP::sp::ctrl_block_pd< P, D >

Definition at line 270 of file memory.h.

Constructor & Destructor Documentation

template<typename P , typename D >
CLHEP::sp::ctrl_block_pd< P, D >::ctrl_block_pd ( P *  p,
d 
)
inline

Definition at line 296 of file memory.h.

298  , owned_ptr( p )
299  , deleter ( d )
300 { }
const char * p
Definition: xmltok.h:285
template<typename P , typename D >
CLHEP::sp::ctrl_block_pd< P, D >::~ctrl_block_pd ( )
throw (
)
inline

Definition at line 303 of file memory.h.

304 { }

Member Function Documentation

template<typename P , typename D >
void CLHEP::sp::ctrl_block_pd< P, D >::dispose ( )
throw (
)
inlinevirtual

Implements CLHEP::sp::abstract_ctrl_block.

Definition at line 308 of file memory.h.

309 {
310  deleter( owned_ptr );
311 }
template<typename P , typename D >
void * CLHEP::sp::ctrl_block_pd< P, D >::get_deleter ( std::type_info const &  ti)
inlinevirtual

Implements CLHEP::sp::abstract_ctrl_block.

Definition at line 315 of file memory.h.

316 {
317  return ti == typeid(D) ? &reinterpret_cast<char&>( deleter ) : 0;
318 }
template<typename P , typename D >
void CLHEP::sp::ctrl_block_pd< P, D >::operator delete ( void p)
inline

Definition at line 329 of file memory.h.

330 {
331  std::allocator<this_type>().deallocate( static_cast<this_type*>(p), 1 );
332 }
const char * p
Definition: xmltok.h:285
template<typename P , typename D >
void * CLHEP::sp::ctrl_block_pd< P, D >::operator new ( std::size_t  )
inline

Definition at line 322 of file memory.h.

323 {
324  return std::allocator<this_type>().allocate( 1 );
325 }

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