#include <PtrVectorBase.h>
Public Types | |
typedef unsigned long | key_type |
typedef key_type | size_type |
Public Member Functions | |
size_type | capacity () const |
Capacity of the RefVector. More... | |
void | clear () |
Clear the PtrVector. More... | |
bool | empty () const |
Is the RefVector empty. More... | |
bool | hasCache () const |
ProductID | id () const |
Accessor for product ID. More... | |
bool | isAvailable () const |
bool | isNonnull () const |
Checks for non-null. More... | |
bool | isNull () const |
Checks for null. More... | |
bool | isTransient () const |
bool | operator! () const |
Checks for null. More... | |
bool | operator== (PtrVectorBase const &iRHS) const |
void const * | product () const |
EDProductGetter const * | productGetter () const |
Accessor for product getter. More... | |
PtrVectorBase (ProductID const &productID, void const *prodPtr=nullptr, EDProductGetter const *prodGetter=nullptr) | |
PtrVectorBase (const PtrVectorBase &) | |
void | reserve (size_type n) |
Reserve space for RefVector. More... | |
void | setProductGetter (EDProductGetter *iGetter) const |
size_type | size () const |
Size of the RefVector. More... | |
virtual | ~PtrVectorBase () |
Protected Member Functions | |
template<typename TPtr > | |
TPtr | makePtr (unsigned long iIndex) const |
template<typename TPtr > | |
TPtr | makePtr (std::vector< void const * >::const_iterator const iIt) const |
PtrVectorBase () | |
void | push_back_base (RefCore const &core, key_type iKey, void const *iData) |
void | swap (PtrVectorBase &other) |
swap More... | |
std::vector< void const * >::const_iterator | void_begin () const |
std::vector< void const * >::const_iterator | void_end () const |
Private Member Functions | |
bool | checkCachedItems () const |
void | getProduct_ () const |
PtrVectorBase & | operator= (const PtrVectorBase &)=delete |
virtual std::type_info const & | typeInfo () const |
Static Private Member Functions | |
static const std::vector< void const * > & | emptyCache () |
Private Attributes | |
std::atomic< std::vector< void const * > * > | cachedItems_ |
RefCore | core_ |
std::vector< key_type > | indicies_ |
Description: Base class for PtrVector
Usage: This class defines the common behavior for the PtrVector template class instances
Definition at line 32 of file PtrVectorBase.h.
typedef unsigned long edm::PtrVectorBase::key_type |
Definition at line 35 of file PtrVectorBase.h.
Definition at line 36 of file PtrVectorBase.h.
|
inlineexplicit |
Definition at line 38 of file PtrVectorBase.h.
References PtrVectorBase(), and ~PtrVectorBase().
edm::PtrVectorBase::PtrVectorBase | ( | const PtrVectorBase & | iOther | ) |
Definition at line 42 of file PtrVectorBase.cc.
References utilities::cache(), and cachedItems_.
|
virtual |
Definition at line 38 of file PtrVectorBase.cc.
References cachedItems_.
Referenced by PtrVectorBase().
|
protected |
Definition at line 35 of file PtrVectorBase.cc.
Referenced by product(), and PtrVectorBase().
|
inline |
|
private |
Definition at line 167 of file PtrVectorBase.cc.
References cachedItems_, Exception, id(), edm::errors::InvalidReference, and tmp.
Referenced by typeInfo(), void_begin(), and void_end().
|
inline |
Clear the PtrVector.
Definition at line 80 of file PtrVectorBase.h.
References cachedItems_, core_, indicies_, and operator==().
Referenced by ConvertedPhotonProducer::buildCollections(), Vispa.Views.WidgetView.WidgetView::closeEvent(), Vispa.Views.BoxDecayView.BoxDecayView::closeEvent(), Vispa.Share.FindAlgorithm.FindAlgorithm::findUsingFindDialog(), BremRecoveryClusterAlgo::makeIslandSuperClusters(), HiBremRecoveryClusterAlgo::makeIslandSuperClusters(), Multi5x5BremRecoveryClusterAlgo::makeIslandSuperClusters(), ReducedEGProducer::relinkCaloClusters(), Vispa.Views.LineDecayView.LineDecayView::setDataObjects(), Vispa.Views.WidgetView.WidgetView::setDataObjects(), BeautifulSoup.Tag::setString(), Vispa.Views.TreeView.TreeView::updateContent(), Vispa.Views.TableView.TableView::updateContent(), Vispa.Views.BoxDecayView.BoxDecayView::updateContent(), and Vispa.Views.PropertyView.PropertyView::updateContent().
|
inline |
Is the RefVector empty.
Definition at line 71 of file PtrVectorBase.h.
References indicies_.
Referenced by Multi5x5BremRecoveryClusterAlgo::makeIslandSuperClusters(), ReducedEGProducer::relinkCaloClusters(), Vispa.Gui.VispaWidget.TextField::setAutosizeFont(), and Vispa.Gui.VispaWidget.TextField::setAutotruncate().
|
staticprivate |
Definition at line 198 of file PtrVectorBase.cc.
References edm::s_emptyCache.
Referenced by typeInfo(), void_begin(), and void_end().
|
private |
Definition at line 115 of file PtrVectorBase.cc.
References cachedItems_, Exception, edm::WrapperBase::fillPtrVector(), hasCache(), indicies_, gen::k, edm::errors::LogicError, product(), productGetter(), and typeInfo().
Referenced by isAvailable(), makePtr(), void_begin(), and void_end().
|
inline |
Definition at line 64 of file PtrVectorBase.h.
References cachedItems_, and isAvailable().
Referenced by getProduct_(), isAvailable(), and makePtr().
|
inline |
Accessor for product ID.
Definition at line 59 of file PtrVectorBase.h.
References core_, and edm::RefCore::id().
Referenced by checkCachedItems(), pf2pat::TopProjectorAlgo< Top, Bottom >::printAncestors(), and pf2pat::TopProjectorAlgo< Top, Bottom >::processCollection().
bool edm::PtrVectorBase::isAvailable | ( | ) | const |
True if the data is in memory or is available in the Event No type checking is done.
Definition at line 92 of file PtrVectorBase.cc.
References cachedItems_, core_, getProduct_(), hasCache(), indicies_, edm::RefCore::isAvailable(), and productGetter().
Referenced by hasCache().
|
inline |
Checks for non-null.
Definition at line 53 of file PtrVectorBase.h.
References core_, and edm::RefCore::isNonnull().
Referenced by isNull().
|
inline |
Checks for null.
Definition at line 49 of file PtrVectorBase.h.
References isNonnull().
Referenced by operator!().
|
inline |
Definition at line 93 of file PtrVectorBase.h.
References core_, and edm::RefCore::isTransient().
Referenced by makePtr().
|
inlineprotected |
Definition at line 123 of file PtrVectorBase.h.
References cachedItems_, hasCache(), indicies_, isTransient(), and productGetter().
|
inlineprotected |
Definition at line 137 of file PtrVectorBase.h.
References getProduct_(), hasCache(), indicies_, isTransient(), and productGetter().
|
inline |
|
privatedelete |
Referenced by typeInfo().
bool edm::PtrVectorBase::operator== | ( | PtrVectorBase const & | iRHS | ) | const |
Definition at line 180 of file PtrVectorBase.cc.
References core_, cond::serialization::equal(), and indicies_.
Referenced by clear().
|
inline |
Definition at line 95 of file PtrVectorBase.h.
References trackingPlots::other, PtrVectorBase(), push_back_base(), and swap().
Referenced by getProduct_().
|
inline |
Accessor for product getter.
Definition at line 62 of file PtrVectorBase.h.
References core_, and edm::RefCore::productGetter().
Referenced by getProduct_(), isAvailable(), makePtr(), PATObjectCrossLinker::matchElectronToPhoton(), and PATObjectCrossLinker::matchOneToMany().
|
protected |
Definition at line 70 of file PtrVectorBase.cc.
References cachedItems_, core_, indicies_, and edm::RefCore::pushBackItem().
Referenced by product().
|
inline |
Reserve space for RefVector.
Definition at line 88 of file PtrVectorBase.h.
References cachedItems_, and indicies_.
Referenced by Multi5x5SuperClusterProducer::getClusterPtrVector().
|
inline |
Definition at line 91 of file PtrVectorBase.h.
References core_, and edm::RefCore::setProductGetter().
|
inline |
Size of the RefVector.
Definition at line 74 of file PtrVectorBase.h.
References indicies_.
Referenced by ntupleDataFormat._Collection::__iter__(), ntupleDataFormat._Collection::__len__(), reco::PFMETProducerMVA::chargedEnFrac(), reco::SuperCluster::clustersSize(), NamedCandCombinerBase::combine(), convertToPFCandidatePtr(), reco::Conversion::EoverP(), reco::Conversion::EoverPrefittedTracks(), SCEnergyCorrectorSemiParm::getCorrections(), main(), Multi5x5BremRecoveryClusterAlgo::makeIslandSuperClusters(), HybridClusterAlgo::makeSuperClusters(), pf2pat::TopProjectorAlgo< Top, Bottom >::maskAncestors(), reco::SuperCluster::preshowerClustersSize(), and pf2pat::TopProjectorAlgo< Top, Bottom >::printAncestors().
|
protected |
swap
Definition at line 63 of file PtrVectorBase.cc.
References cachedItems_, core_, indicies_, and edm::RefCore::swap().
Referenced by product(), and edm::PtrVector< reco::reco::PFCluster >::swap().
|
inlineprivatevirtual |
Reimplemented in edm::PtrVector< T >, edm::PtrVector< CaloCluster >, edm::PtrVector< Candidate >, edm::PtrVector< reco::reco::BasicCluster >, and edm::PtrVector< reco::reco::PFCluster >.
Definition at line 153 of file PtrVectorBase.h.
References checkCachedItems(), emptyCache(), and operator=().
Referenced by getProduct_().
|
inlineprotected |
Definition at line 107 of file PtrVectorBase.h.
References checkCachedItems(), emptyCache(), and getProduct_().
|
inlineprotected |
Definition at line 114 of file PtrVectorBase.h.
References checkCachedItems(), emptyCache(), and getProduct_().
|
mutableprivate |
Definition at line 169 of file PtrVectorBase.h.
Referenced by checkCachedItems(), clear(), getProduct_(), hasCache(), isAvailable(), makePtr(), PtrVectorBase(), push_back_base(), reserve(), swap(), and ~PtrVectorBase().
|
private |
Definition at line 167 of file PtrVectorBase.h.
Referenced by clear(), id(), isAvailable(), isNonnull(), isTransient(), operator==(), productGetter(), push_back_base(), setProductGetter(), and swap().
|
private |
Definition at line 168 of file PtrVectorBase.h.
Referenced by capacity(), clear(), empty(), getProduct_(), isAvailable(), makePtr(), operator==(), push_back_base(), reserve(), size(), and swap().