Classes | Public Types | Public Member Functions | Private Attributes | List of all members
gallery::ValidHandle< T > Class Template Reference

#include <ValidHandle.h>

Classes

class  HandleTag
 

Public Types

using element_type = T
 

Public Member Functions

 ValidHandle ()=delete
 
 ValidHandle (T const *prod, art::ProductID) noexcept(false)
 
 ValidHandle (ValidHandle const &)=default
 
ValidHandleoperator= (ValidHandle const &)=default
 
T const & operator* () const noexcept
 
T const * operator-> () const noexcept
 
T const * product () const noexcept
 
art::ProductID id () const noexcept
 

Private Attributes

T const * prod_
 
art::ProductID productID_
 

Detailed Description

template<typename T>
class gallery::ValidHandle< T >

Definition at line 15 of file ValidHandle.h.

Member Typedef Documentation

template<typename T>
using gallery::ValidHandle< T >::element_type = T

Definition at line 17 of file ValidHandle.h.

Constructor & Destructor Documentation

template<typename T>
gallery::ValidHandle< T >::ValidHandle ( )
delete
template<class T >
gallery::ValidHandle< T >::ValidHandle ( T const *  prod,
art::ProductID  productID 
)
explicitnoexcept

Definition at line 38 of file ValidHandle.h.

40  : prod_{prod}, productID_{productID}
41  {
42  if (prod == nullptr) {
44  }
45  }
void throwValidHandleNullPointer()
Definition: ValidHandle.cc:8
art::ProductID productID_
Definition: ValidHandle.h:34
template<typename T>
gallery::ValidHandle< T >::ValidHandle ( ValidHandle< T > const &  )
default

Member Function Documentation

template<class T >
art::ProductID gallery::ValidHandle< T >::id ( ) const
inlinenoexcept

Definition at line 68 of file ValidHandle.h.

69  {
70  return productID_;
71  }
art::ProductID productID_
Definition: ValidHandle.h:34
template<class T >
T const & gallery::ValidHandle< T >::operator* ( ) const
inlinenoexcept

Definition at line 48 of file ValidHandle.h.

49  {
50  return *prod_;
51  }
template<class T >
T const * gallery::ValidHandle< T >::operator-> ( ) const
inlinenoexcept

Definition at line 54 of file ValidHandle.h.

55  {
56  return prod_;
57  }
template<typename T>
ValidHandle& gallery::ValidHandle< T >::operator= ( ValidHandle< T > const &  )
default
template<class T >
T const * gallery::ValidHandle< T >::product ( ) const
inlinenoexcept

Definition at line 61 of file ValidHandle.h.

62  {
63  return prod_;
64  }

Member Data Documentation

template<typename T>
T const* gallery::ValidHandle< T >::prod_
private

Definition at line 33 of file ValidHandle.h.

template<typename T>
art::ProductID gallery::ValidHandle< T >::productID_
private

Definition at line 34 of file ValidHandle.h.


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