CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes
edm::OldProvenanceReader Class Reference
Inheritance diagram for edm::OldProvenanceReader:
edm::ProvenanceReaderBase

Public Member Functions

 OldProvenanceReader (RootTree *rootTree, EntryDescriptionMap const &theMap, DaqProvenanceHelper const *daqProvenanceHelper)
 
virtual ~OldProvenanceReader ()
 
- Public Member Functions inherited from edm::ProvenanceReaderBase
 ProvenanceReaderBase ()
 
virtual ~ProvenanceReaderBase ()
 

Private Member Functions

virtual void readProvenance (ProductProvenanceRetriever const &provRetriever, unsigned int transitionIndex) const override
 

Private Attributes

DaqProvenanceHelper const * daqProvenanceHelper_
 
EntryDescriptionMap const & entryDescriptionMap_
 
std::vector< EventEntryInfoinfoVector_
 
std::vector< EventEntryInfo > * pInfoVector_
 
SharedResourcesAcquirer resourceAcquirer_
 
RootTreerootTree_
 

Detailed Description

Definition at line 1946 of file RootFile.cc.

Constructor & Destructor Documentation

edm::OldProvenanceReader::OldProvenanceReader ( RootTree rootTree,
EntryDescriptionMap const &  theMap,
DaqProvenanceHelper const *  daqProvenanceHelper 
)
explicit

Definition at line 1960 of file RootFile.cc.

1960  :
1962  rootTree_(rootTree),
1963  infoVector_(),
1965  entryDescriptionMap_(theMap),
1966  daqProvenanceHelper_(daqProvenanceHelper),
1967  resourceAcquirer_(SharedResourcesRegistry::instance()->createAcquirerForSourceDelayedReader()) {
1968  }
EntryDescriptionMap const & entryDescriptionMap_
Definition: RootFile.cc:1955
static SharedResourcesRegistry * instance()
SharedResourcesAcquirer resourceAcquirer_
Definition: RootFile.cc:1957
std::vector< EventEntryInfo > * pInfoVector_
Definition: RootFile.cc:1954
std::vector< EventEntryInfo > infoVector_
Definition: RootFile.cc:1953
DaqProvenanceHelper const * daqProvenanceHelper_
Definition: RootFile.cc:1956
virtual edm::OldProvenanceReader::~OldProvenanceReader ( )
inlinevirtual

Definition at line 1949 of file RootFile.cc.

1949 {}

Member Function Documentation

void edm::OldProvenanceReader::readProvenance ( ProductProvenanceRetriever const &  provRetriever,
unsigned int  transitionIndex 
) const
overrideprivatevirtual

Implements edm::ProvenanceReaderBase.

Definition at line 1971 of file RootFile.cc.

References edm::RootTree::branchEntryInfoBranch(), daqProvenanceHelper_, entryDescriptionMap_, edm::RootTree::entryNumberForIndex(), edm::roottree::getEntry(), info(), infoVector_, edm::ProductProvenanceRetriever::insertIntoSet(), getDQMSummary::iter, edm::DaqProvenanceHelper::mapBranchID(), edm::DaqProvenanceHelper::mapParentageID(), pInfoVector_, resourceAcquirer_, rootTree_, and edm::setRefCoreStreamer().

1971  {
1972  {
1973  std::lock_guard<SharedResourcesAcquirer> guard(resourceAcquirer_);
1974  rootTree_->branchEntryInfoBranch()->SetAddress(&pInfoVector_);
1976  setRefCoreStreamer(true);
1977  }
1978  for(auto const& info : infoVector_) {
1979  EntryDescriptionMap::const_iterator iter = entryDescriptionMap_.find(info.entryDescriptionID());
1980  assert(iter != entryDescriptionMap_.end());
1981  Parentage parentage(iter->second.parents());
1982  if(daqProvenanceHelper_) {
1983  ProductProvenance entry(daqProvenanceHelper_->mapBranchID(info.branchID()),
1984  daqProvenanceHelper_->mapParentageID(parentage.id()));
1985  provRetriever.insertIntoSet(entry);
1986  } else {
1987  ProductProvenance entry(info.branchID(), parentage.id());
1988  provRetriever.insertIntoSet(entry);
1989  }
1990 
1991  }
1992  }
Int_t getEntry(TBranch *branch, EntryNumber entryNumber)
Definition: RootTree.cc:461
static const TGPicture * info(bool iBackgroundIsBlack)
BranchID const & mapBranchID(BranchID const &branchID) const
void setRefCoreStreamer(bool resetAll=false)
EntryDescriptionMap const & entryDescriptionMap_
Definition: RootFile.cc:1955
TBranch * branchEntryInfoBranch() const
Definition: RootTree.h:145
EntryNumber const & entryNumberForIndex(unsigned int index) const
Definition: RootTree.cc:92
SharedResourcesAcquirer resourceAcquirer_
Definition: RootFile.cc:1957
std::vector< EventEntryInfo > * pInfoVector_
Definition: RootFile.cc:1954
ParentageID const & mapParentageID(ParentageID const &phid) const
std::vector< EventEntryInfo > infoVector_
Definition: RootFile.cc:1953
DaqProvenanceHelper const * daqProvenanceHelper_
Definition: RootFile.cc:1956

Member Data Documentation

DaqProvenanceHelper const* edm::OldProvenanceReader::daqProvenanceHelper_
private

Definition at line 1956 of file RootFile.cc.

Referenced by readProvenance().

EntryDescriptionMap const& edm::OldProvenanceReader::entryDescriptionMap_
private

Definition at line 1955 of file RootFile.cc.

Referenced by readProvenance().

std::vector<EventEntryInfo> edm::OldProvenanceReader::infoVector_
private

Definition at line 1953 of file RootFile.cc.

Referenced by readProvenance().

std::vector<EventEntryInfo>* edm::OldProvenanceReader::pInfoVector_
mutableprivate

Definition at line 1954 of file RootFile.cc.

Referenced by readProvenance().

SharedResourcesAcquirer edm::OldProvenanceReader::resourceAcquirer_
mutableprivate

Definition at line 1957 of file RootFile.cc.

Referenced by readProvenance().

RootTree* edm::OldProvenanceReader::rootTree_
private

Definition at line 1952 of file RootFile.cc.

Referenced by readProvenance().