#include <DataFormats/Common/interface/RefProd.h>
Public Types | |
typedef C | product_type |
typedef C | value_type |
Public Member Functions | |
product_type const * | get () const |
Returns C++ pointer to the product Will attempt to retrieve product. | |
bool | hasCache () const |
Checks if product is in memory. | |
bool | hasProductCache () const |
Checks if product is in memory. | |
ProductID | id () const |
Accessor for product ID. | |
bool | isAvailable () const |
Checks if collection is in memory or available in the Event. | |
bool | isNonnull () const |
Checks for non-null. | |
bool | isNull () const |
Checks for null. | |
bool | isTransient () const |
Checks if this RefProd is transient (i.e. not persistable). | |
product_type const & | operator * () const |
Dereference operator. | |
bool | operator! () const |
Checks for null. | |
product_type const * | operator-> () const |
Member dereference operator. | |
product_type const * | product () const |
Returns C++ pointer to the product Will attempt to retrieve product. | |
EDProductGetter const * | productGetter () const |
Accessor for product getter. | |
RefCore const & | refCore () const |
RefProd (ProductID const &productID, EDProductGetter const *prodGetter) | |
template<typename T, typename F> | |
RefProd (RefVector< C, T, F > const &ref) | |
Constructor from RefVector<C,T,F>. | |
template<typename T, typename F> | |
RefProd (Ref< C, T, F > const &ref) | |
Constructor from Ref<C,T,F>. | |
RefProd (TestHandle< C > const &handle) | |
General purpose constructor from test handle. | |
RefProd (C const *product) | |
Constructor for ref to object that is not in an event. | |
RefProd (OrphanHandle< C > const &handle) | |
General purpose constructor from orphan handle. | |
RefProd (Handle< C > const &handle) | |
General purpose constructor from handle. | |
RefProd () | |
Default constructor needed for reading from persistent store. Not for direct use. | |
void | swap (RefProd< C > &) |
~RefProd () | |
Destructor. | |
Private Member Functions | |
void | checkTypeAtCompileTime (C const *ptr) |
Private Attributes | |
RefCore | product_ |
Definition at line 51 of file RefProd.h.
typedef C edm::RefProd< C >::product_type |
typedef C edm::RefProd< C >::value_type |
edm::RefProd< C >::RefProd | ( | ) | [inline] |
edm::RefProd< C >::RefProd | ( | Handle< C > const & | handle | ) | [inline, explicit] |
General purpose constructor from handle.
Definition at line 60 of file RefProd.h.
00060 : 00061 product_(handle.id(), handle.product(), 0, false) { 00062 checkTypeAtCompileTime(handle.product()); 00063 }
edm::RefProd< C >::RefProd | ( | OrphanHandle< C > const & | handle | ) | [inline, explicit] |
General purpose constructor from orphan handle.
Definition at line 66 of file RefProd.h.
00066 : 00067 product_(handle.id(), handle.product(), 0, false) { 00068 checkTypeAtCompileTime(handle.product()); 00069 }
edm::RefProd< C >::RefProd | ( | C const * | product | ) | [inline] |
edm::RefProd< C >::RefProd | ( | TestHandle< C > const & | handle | ) | [inline, explicit] |
General purpose constructor from test handle.
Definition at line 86 of file RefProd.h.
00086 : 00087 product_(handle.id(), handle.product(), 0, true) { 00088 checkTypeAtCompileTime(handle.product()); 00089 }
edm::RefProd< C >::RefProd | ( | Ref< C, T, F > const & | ref | ) | [inline, explicit] |
edm::RefProd< C >::RefProd | ( | RefVector< C, T, F > const & | ref | ) | [inline, explicit] |
edm::RefProd< C >::RefProd | ( | ProductID const & | productID, | |
EDProductGetter const * | prodGetter | |||
) | [inline] |
Definition at line 102 of file RefProd.h.
00102 : 00103 product_(productID, 0, mustBeNonZero(prodGetter, "RefProd", productID), false) { 00104 }
edm::RefProd< C >::~RefProd | ( | ) | [inline] |
void edm::RefProd< C >::checkTypeAtCompileTime | ( | C const * | ptr | ) | [inline, private] |
product_type const* edm::RefProd< C >::get | ( | void | ) | const [inline] |
Returns C++ pointer to the product Will attempt to retrieve product.
Definition at line 117 of file RefProd.h.
Referenced by l1extra::L1ParticleMap::candidateInCombo(), l1extra::L1ParticleMap::etMissParticleInCombo(), pat::TriggerEvent::filters(), pat::TriggerEvent::objects(), and pat::TriggerEvent::paths().
00117 { 00118 return isNull() ? 0 : this->operator->(); 00119 }
bool edm::RefProd< C >::hasCache | ( | ) | const [inline] |
Checks if product is in memory.
Definition at line 147 of file RefProd.h.
Referenced by edm::RefProd< edm::OwnVector >::hasProductCache().
00147 {return product_.productPtr() != 0;}
bool edm::RefProd< C >::hasProductCache | ( | ) | const [inline] |
ProductID edm::RefProd< C >::id | ( | void | ) | const [inline] |
Accessor for product ID.
Definition at line 141 of file RefProd.h.
Referenced by GenParticleProducer::produce(), edm::RefToBaseProd< T >::RefToBaseProd(), and edm::Association< C >::setRef().
00141 {return product_.id();}
bool edm::RefProd< C >::isAvailable | ( | ) | const [inline] |
bool edm::RefProd< C >::isNonnull | ( | ) | const [inline] |
Checks for non-null.
Definition at line 135 of file RefProd.h.
Referenced by edm::RefProd< edm::OwnVector >::isNull().
00135 {return product_.isNonnull();}
bool edm::RefProd< C >::isNull | ( | ) | const [inline] |
Checks for null.
Definition at line 132 of file RefProd.h.
Referenced by edm::RefProd< edm::OwnVector >::get(), edm::RefProd< edm::OwnVector >::operator!(), edm::RefProd< edm::OwnVector >::product(), and edm::Association< C >::setRef().
00132 {return !isNonnull();}
bool edm::RefProd< C >::isTransient | ( | ) | const [inline] |
C const & edm::RefProd< C >::operator * | ( | ) | const [inline] |
Dereference operator.
Definition at line 196 of file RefProd.h.
References edm::RefProd< C >::product_.
00196 { 00197 return *(edm::template getProduct<C>(product_)); 00198 }
bool edm::RefProd< C >::operator! | ( | ) | const [inline] |
C const * edm::RefProd< C >::operator-> | ( | ) | const [inline] |
Member dereference operator.
Definition at line 203 of file RefProd.h.
References edm::RefProd< C >::product_.
Referenced by edm::RefProd< edm::OwnVector >::get(), and edm::RefProd< edm::OwnVector >::product().
00203 { 00204 return edm::template getProduct<C>(product_); 00205 }
product_type const* edm::RefProd< C >::product | ( | ) | const [inline] |
Returns C++ pointer to the product Will attempt to retrieve product.
Definition at line 123 of file RefProd.h.
Referenced by edm::RefToBaseProd< T >::RefToBaseProd().
00123 { 00124 return isNull() ? 0 : this->operator->(); 00125 }
EDProductGetter const* edm::RefProd< C >::productGetter | ( | ) | const [inline] |
RefCore const& edm::RefProd< C >::refCore | ( | ) | const [inline] |
Definition at line 127 of file RefProd.h.
Referenced by edm::operator==(), and edm::Ref< C, T, F >::Ref().
00127 { 00128 return product_; 00129 }
void edm::RefProd< C >::swap | ( | RefProd< C > & | other | ) | [inline] |
Definition at line 210 of file RefProd.h.
References edm::RefProd< C >::product_, and std::swap().
Referenced by edm::swap(), and edm::Association< C >::swap().
RefCore edm::RefProd< C >::product_ [private] |
Definition at line 166 of file RefProd.h.
Referenced by edm::RefProd< edm::OwnVector >::hasCache(), edm::RefProd< edm::OwnVector >::id(), edm::RefProd< edm::OwnVector >::isAvailable(), edm::RefProd< edm::OwnVector >::isNonnull(), edm::RefProd< edm::OwnVector >::isTransient(), edm::RefProd< C >::operator *(), edm::RefProd< C >::operator->(), edm::RefProd< edm::OwnVector >::productGetter(), edm::RefProd< edm::OwnVector >::refCore(), and edm::RefProd< C >::swap().