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 1867 of file RootFile.cc.

Constructor & Destructor Documentation

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

Definition at line 1881 of file RootFile.cc.

1881  :
1883  rootTree_(rootTree),
1884  infoVector_(),
1886  entryDescriptionMap_(theMap),
1887  daqProvenanceHelper_(daqProvenanceHelper),
1888  resourceAcquirer_(SharedResourcesRegistry::instance()->createAcquirerForSourceDelayedReader()) {
1889  }
EntryDescriptionMap const & entryDescriptionMap_
Definition: RootFile.cc:1876
static SharedResourcesRegistry * instance()
SharedResourcesAcquirer resourceAcquirer_
Definition: RootFile.cc:1878
std::vector< EventEntryInfo > * pInfoVector_
Definition: RootFile.cc:1875
std::vector< EventEntryInfo > infoVector_
Definition: RootFile.cc:1874
DaqProvenanceHelper const * daqProvenanceHelper_
Definition: RootFile.cc:1877
virtual edm::OldProvenanceReader::~OldProvenanceReader ( )
inlinevirtual

Definition at line 1870 of file RootFile.cc.

1870 {}

Member Function Documentation

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

Implements edm::ProvenanceReaderBase.

Definition at line 1892 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().

1892  {
1893  {
1894  std::lock_guard<SharedResourcesAcquirer> guard(resourceAcquirer_);
1895  rootTree_->branchEntryInfoBranch()->SetAddress(&pInfoVector_);
1897  setRefCoreStreamer(true);
1898  }
1899  for(auto const& info : infoVector_) {
1900  EntryDescriptionMap::const_iterator iter = entryDescriptionMap_.find(info.entryDescriptionID());
1901  assert(iter != entryDescriptionMap_.end());
1902  Parentage parentage(iter->second.parents());
1903  if(daqProvenanceHelper_) {
1904  ProductProvenance entry(daqProvenanceHelper_->mapBranchID(info.branchID()),
1905  daqProvenanceHelper_->mapParentageID(parentage.id()));
1906  provRetriever.insertIntoSet(entry);
1907  } else {
1908  ProductProvenance entry(info.branchID(), parentage.id());
1909  provRetriever.insertIntoSet(entry);
1910  }
1911 
1912  }
1913  }
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:1876
TBranch * branchEntryInfoBranch() const
Definition: RootTree.h:143
EntryNumber const & entryNumberForIndex(unsigned int index) const
Definition: RootTree.cc:92
SharedResourcesAcquirer resourceAcquirer_
Definition: RootFile.cc:1878
std::vector< EventEntryInfo > * pInfoVector_
Definition: RootFile.cc:1875
ParentageID const & mapParentageID(ParentageID const &phid) const
std::vector< EventEntryInfo > infoVector_
Definition: RootFile.cc:1874
DaqProvenanceHelper const * daqProvenanceHelper_
Definition: RootFile.cc:1877

Member Data Documentation

DaqProvenanceHelper const* edm::OldProvenanceReader::daqProvenanceHelper_
private

Definition at line 1877 of file RootFile.cc.

Referenced by readProvenance().

EntryDescriptionMap const& edm::OldProvenanceReader::entryDescriptionMap_
private

Definition at line 1876 of file RootFile.cc.

Referenced by readProvenance().

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

Definition at line 1874 of file RootFile.cc.

Referenced by readProvenance().

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

Definition at line 1875 of file RootFile.cc.

Referenced by readProvenance().

SharedResourcesAcquirer edm::OldProvenanceReader::resourceAcquirer_
mutableprivate

Definition at line 1878 of file RootFile.cc.

Referenced by readProvenance().

RootTree* edm::OldProvenanceReader::rootTree_
private

Definition at line 1873 of file RootFile.cc.

Referenced by readProvenance().