23 std::unique_ptr<TTree> metaDataTree{
29 auto productRegistry = std::make_unique<art::ProductRegistry>();
30 auto* productRegistryPtr = productRegistry.get();
31 TBranch* productRegistryBranch = metaDataTree->GetBranch(
32 art::rootNames::metaBranchRootName<art::ProductRegistry>());
33 if (productRegistryBranch ==
nullptr) {
35 art::rootNames::metaBranchRootName<art::ProductRegistry>());
37 metaDataTree->SetBranchAddress(
38 art::rootNames::metaBranchRootName<art::ProductRegistry>(),
44 bool hasBranchIDLists{
false};
45 if (metaDataTree->GetBranch(
46 art::rootNames::metaBranchRootName<art::BranchIDLists>())) {
47 hasBranchIDLists =
true;
49 metaDataTree->SetBranchAddress(
50 art::rootNames::metaBranchRootName<art::BranchIDLists>(),
54 metaDataTree->GetEntry(0);
58 if (hasBranchIDLists) {
60 std::make_unique<art::BranchIDLists>(
std::move(branchIDLists));
61 metaDataTree->SetBranchAddress(
62 art::rootNames::metaBranchRootName<art::BranchIDLists>(),
nullptr);
66 for (
auto const& product : productRegistry->productList_) {
73 art::detail::BranchDescriptionStreamer::fluffRootTransients(
std::vector< BranchIDList > BranchIDLists
std::map< art::ProductID, art::BranchDescription > productIDToDescriptionMap_
BranchType branchType() const noexcept
void throwTreeNotFound(std::string const &treeName)
std::string const & metaDataTreeName()
constexpr bool isValid() const noexcept
void throwBranchNotFound(std::string const &branchName)
std::unique_ptr< art::BranchIDLists > branchIDLists_
cet::exempt_ptr< art::BranchIDLists const > branchIDLists() const
std::set< art::ProductID > allSeenProductIDs_
ProductID productID() const noexcept