CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Private Attributes | Friends
edm::reftobase::IndirectHolder< T > Class Template Reference

#include <EDProductfwd.h>

Inheritance diagram for edm::reftobase::IndirectHolder< T >:
edm::reftobase::BaseHolder< T >

Public Member Functions

virtual BaseHolder< T > * clone () const override
 
virtual bool fillRefIfMyTypeMatches (RefHolderBase &fillme, std::string &msg) const override
 
virtual T const * getPtr () const override
 
virtual std::unique_ptr< RefHolderBaseholder () const override
 
virtual ProductID id () const override
 
 IndirectHolder ()
 
 IndirectHolder (std::shared_ptr< RefHolderBase > p)
 
template<typename U >
 IndirectHolder (std::unique_ptr< U > p)
 
 IndirectHolder (IndirectHolder const &other)
 
virtual bool isAvailable () const override
 
virtual bool isEqualTo (BaseHolder< T > const &rhs) const override
 
virtual bool isTransient () const override
 
virtual size_t key () const override
 
virtual std::unique_ptr< BaseVectorHolder< T > > makeVectorHolder () const override
 
IndirectHolderoperator= (IndirectHolder const &rhs)
 
virtual EDProductGetter const * productGetter () const override
 
void swap (IndirectHolder &other)
 
virtual ~IndirectHolder ()
 
- Public Member Functions inherited from edm::reftobase::BaseHolder< T >
 BaseHolder ()
 
void swap (BaseHolder &)
 
virtual ~BaseHolder ()
 

Static Public Member Functions

static short Class_Version ()
 
- Static Public Member Functions inherited from edm::reftobase::BaseHolder< T >
static short Class_Version ()
 

Private Attributes

RefHolderBasehelper_
 

Friends

class IndirectVectorHolder< T >
 
class RefToBase< T >
 

Additional Inherited Members

- Protected Member Functions inherited from edm::reftobase::BaseHolder< T >
 BaseHolder (BaseHolder const &other)
 
BaseHolderoperator= (BaseHolder const &rhs)
 

Detailed Description

template<typename T>
class edm::reftobase::IndirectHolder< T >

Definition at line 36 of file EDProductfwd.h.

Constructor & Destructor Documentation

template<typename T>
edm::reftobase::IndirectHolder< T >::IndirectHolder ( )
inline

Definition at line 29 of file IndirectHolder.h.

Referenced by edm::reftobase::IndirectHolder< reco::GsfElectronCore >::IndirectHolder().

29 : BaseHolder<T>(), helper_( nullptr ) { }
template<typename T >
edm::reftobase::IndirectHolder< T >::IndirectHolder ( std::shared_ptr< RefHolderBase p)
inline

Definition at line 69 of file IndirectHolder.h.

69  :
70  BaseHolder<T>(), helper_(p->clone())
71  { }
template<typename T>
template<typename U >
edm::reftobase::IndirectHolder< T >::IndirectHolder ( std::unique_ptr< U >  p)
inline

Definition at line 32 of file IndirectHolder.h.

template<typename T >
edm::reftobase::IndirectHolder< T >::IndirectHolder ( IndirectHolder< T > const &  other)
inline

Definition at line 75 of file IndirectHolder.h.

75  :
76  BaseHolder<T>(other), helper_(other.helper_->clone())
77  { }
template<typename T >
edm::reftobase::IndirectHolder< T >::~IndirectHolder ( )
virtual

Member Function Documentation

template<typename T>
static short edm::reftobase::IndirectHolder< T >::Class_Version ( )
inlinestatic

Definition at line 57 of file IndirectHolder.h.

59 :
60  friend class RefToBase<T>;
long double T
template<typename T >
BaseHolder< T > * edm::reftobase::IndirectHolder< T >::clone ( void  ) const
overridevirtual

Implements edm::reftobase::BaseHolder< T >.

Definition at line 106 of file IndirectHolder.h.

Referenced by edm::reftobase::IndirectHolder< reco::GsfElectronCore >::IndirectHolder().

107  {
108  return new IndirectHolder<T>(*this);
109  }
template<typename T >
bool edm::reftobase::IndirectHolder< T >::fillRefIfMyTypeMatches ( RefHolderBase fillme,
std::string &  msg 
) const
overridevirtual
template<typename T >
T const * edm::reftobase::IndirectHolder< T >::getPtr ( ) const
overridevirtual

Implements edm::reftobase::BaseHolder< T >.

Definition at line 113 of file IndirectHolder.h.

References edm::reftobase::IndirectHolder< T >::helper_.

Referenced by edm::reftobase::IndirectHolder< reco::GsfElectronCore >::IndirectHolder().

114  {
115  return helper_-> template getPtr<T>();
116  }
template<typename T >
std::unique_ptr< RefHolderBase > edm::reftobase::IndirectHolder< T >::holder ( ) const
overridevirtual

Implements edm::reftobase::BaseHolder< T >.

Definition at line 155 of file IndirectHolder.h.

References edm::reftobase::RefHolderBase::clone(), and edm::reftobase::IndirectHolder< T >::helper_.

Referenced by edm::reftobase::IndirectHolder< reco::GsfElectronCore >::IndirectHolder().

155  {
156  return std::unique_ptr<RefHolderBase>( helper_->clone() );
157  }
virtual RefHolderBase * clone() const =0
template<typename T >
ProductID edm::reftobase::IndirectHolder< T >::id ( ) const
overridevirtual
template<typename T>
virtual bool edm::reftobase::IndirectHolder< T >::isAvailable ( ) const
inlineoverridevirtual

Checks if product collection is in memory or available in the Event. No type checking is done.

Implements edm::reftobase::BaseHolder< T >.

Definition at line 52 of file IndirectHolder.h.

52 { return helper_->isAvailable(); }
virtual bool isAvailable() const =0
template<typename T>
bool edm::reftobase::IndirectHolder< T >::isEqualTo ( BaseHolder< T > const &  rhs) const
overridevirtual

Implements edm::reftobase::BaseHolder< T >.

Definition at line 140 of file IndirectHolder.h.

References edm::reftobase::IndirectHolder< T >::helper_, and edm::reftobase::RefHolderBase::isEqualTo().

Referenced by edm::reftobase::IndirectHolder< reco::GsfElectronCore >::IndirectHolder().

141  {
142  IndirectHolder const* h = dynamic_cast<IndirectHolder const*>(&rhs);
143  return h && helper_->isEqualTo(*h->helper_);
144  }
virtual bool isEqualTo(RefHolderBase const &rhs) const =0
template<typename T>
virtual bool edm::reftobase::IndirectHolder< T >::isTransient ( ) const
inlineoverridevirtual

Implements edm::reftobase::BaseHolder< T >.

Definition at line 54 of file IndirectHolder.h.

54 { return helper_->isTransient(); }
virtual bool isTransient() const =0
template<typename T >
size_t edm::reftobase::IndirectHolder< T >::key ( ) const
overridevirtual
template<typename T >
std::unique_ptr< BaseVectorHolder< T > > edm::reftobase::IndirectHolder< T >::makeVectorHolder ( ) const
overridevirtual

Implements edm::reftobase::BaseHolder< T >.

Definition at line 176 of file IndirectHolder.h.

References edm::reftobase::IndirectHolder< T >::helper_, edm::reftobase::RefHolderBase::makeVectorHolder(), and AlCaHLTBitMon_ParallelJobs::p.

Referenced by edm::reftobase::IndirectHolder< reco::GsfElectronCore >::IndirectHolder().

176  {
177  std::unique_ptr<RefVectorHolderBase> p = helper_->makeVectorHolder();
178  std::shared_ptr<RefVectorHolderBase> sp( p.release() );
179  return std::unique_ptr<BaseVectorHolder<T> >( new IndirectVectorHolder<T>( sp ) );
180  }
virtual std::unique_ptr< RefVectorHolderBase > makeVectorHolder() const =0
template<typename T >
IndirectHolder< T > & edm::reftobase::IndirectHolder< T >::operator= ( IndirectHolder< T > const &  rhs)
inline
template<typename T >
EDProductGetter const * edm::reftobase::IndirectHolder< T >::productGetter ( ) const
inlineoverridevirtual
template<typename T >
void edm::reftobase::IndirectHolder< T >::swap ( IndirectHolder< T > &  other)
inline

Friends And Related Function Documentation

template<typename T>
friend class IndirectVectorHolder< T >
friend

Definition at line 61 of file IndirectHolder.h.

template<typename T>
friend class RefToBase< T >
friend

Definition at line 60 of file IndirectHolder.h.

Member Data Documentation

template<typename T>
RefHolderBase* edm::reftobase::IndirectHolder< T >::helper_
private