DD4hep  1.30.0
Detector Description Toolkit for High Energy Physics
Public Types | Public Member Functions | List of all members
dd4hep::dd4hep_ptr< T > Class Template Reference

Out version of the std auto_ptr implementation base either on auto_ptr or unique_ptr. More...

#include <Memory.h>

Inheritance diagram for dd4hep::dd4hep_ptr< T >:

Public Types

typedef std::unique_ptr< T > base_t
 

Public Member Functions

 dd4hep_ptr ()
 Default Constructor. More...
 
 dd4hep_ptr (T *p)
 Constructor from pointer. More...
 
 dd4hep_ptr (base_t &c)
 Constructor from copy. More...
 
dd4hep_ptroperator= (base_t &c)
 Assignment operator. More...
 
dd4hep_ptradopt (T *ptr)
 Assignment operator. More...
 

Detailed Description

template<typename T>
class dd4hep::dd4hep_ptr< T >

Out version of the std auto_ptr implementation base either on auto_ptr or unique_ptr.

Only need to overload constructor. Everything else like operator->, operator*, get, release etc. comes from base.

Author
M.Frank
Version
1.0

Definition at line 45 of file Memory.h.

Member Typedef Documentation

◆ base_t

template<typename T >
typedef std::unique_ptr<T> dd4hep::dd4hep_ptr< T >::base_t

Definition at line 48 of file Memory.h.

Constructor & Destructor Documentation

◆ dd4hep_ptr() [1/3]

template<typename T >
dd4hep::dd4hep_ptr< T >::dd4hep_ptr ( )
inline

Default Constructor.

Definition at line 51 of file Memory.h.

◆ dd4hep_ptr() [2/3]

template<typename T >
dd4hep::dd4hep_ptr< T >::dd4hep_ptr ( T *  p)
inline

Constructor from pointer.

Definition at line 53 of file Memory.h.

◆ dd4hep_ptr() [3/3]

template<typename T >
dd4hep::dd4hep_ptr< T >::dd4hep_ptr ( base_t c)
inline

Constructor from copy.

Definition at line 55 of file Memory.h.

Member Function Documentation

◆ adopt()

template<typename T >
dd4hep_ptr& dd4hep::dd4hep_ptr< T >::adopt ( T *  ptr)
inline

Assignment operator.

Definition at line 64 of file Memory.h.

◆ operator=()

template<typename T >
dd4hep_ptr& dd4hep::dd4hep_ptr< T >::operator= ( base_t c)
inline

Assignment operator.

Definition at line 57 of file Memory.h.


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