Public Types | Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
art::Results Class Referencefinal

#include "/cvmfs/nova.opensciencegrid.org/externals/art/v2_13_00/source/art/Framework/Principal/Results.h"

Inheritance diagram for art::Results:
art::DataViewImpl

Public Types

using Base = DataViewImpl
 
template<typename T >
using HandleT = Handle< T >
 

Public Member Functions

 Results (Principal const &p, ModuleDescription const &md, cet::exempt_ptr< Consumer > consumer)
 
template<typename PROD >
art::ProductID put (std::unique_ptr< PROD > &&product)
 
template<typename PROD >
art::ProductID put (std::unique_ptr< PROD > &&product, std::string const &productInstanceName)
 
EDProductGetter const * productGetter (ProductID const pid) const
 
void commit (ResultsPrincipal &)
 

Private Types

using RetrievedProductIDs = std::vector< ProductID >
 
using RetrievedProductSet = std::set< ProductID >
 
using TypeLabelMap = std::map< TypeLabel, PMValue >
 
using GroupQueryResultVec = std::vector< GroupQueryResult >
 

Private Member Functions

size_t size () const
 
template<typename PROD >
bool get (SelectorBase const &, Handle< PROD > &result) const
 
template<typename PROD >
bool get (ProductID const pid, Handle< PROD > &result) const
 
template<typename PROD >
bool getByLabel (std::string const &label, std::string const &productInstanceName, Handle< PROD > &result) const
 
template<typename PROD >
bool getByLabel (std::string const &label, std::string const &productInstanceName, std::string const &processName, Handle< PROD > &result) const
 
template<typename PROD >
PROD const & getByLabel (InputTag const &tag) const
 same as above, but using the InputTag class More...
 
template<typename PROD >
bool getByLabel (InputTag const &tag, Handle< PROD > &result) const
 
template<typename PROD >
PROD const * getPointerByLabel (InputTag const &tag) const
 
template<typename PROD >
bool getByToken (ProductToken< PROD > const &token, Handle< PROD > &result) const
 
template<typename PROD >
ValidHandle< PROD > getValidHandle (InputTag const &tag) const
 
template<typename PROD >
ValidHandle< PROD > getValidHandle (ProductToken< PROD > const &token) const
 
template<typename PROD >
art::ValidHandle< PROD > getValidHandle (InputTag const &tag) const
 
template<typename PROD >
art::ValidHandle< PROD > getValidHandle (ProductToken< PROD > const &token) const
 
template<typename PROD >
void getMany (SelectorBase const &, std::vector< Handle< PROD >> &results) const
 
template<typename PROD >
void getManyByType (std::vector< Handle< PROD >> &results) const
 
template<typename ELEMENT >
std::size_t getView (std::string const &moduleLabel, std::string const &productInstanceName, std::vector< ELEMENT const * > &result) const
 
template<typename ELEMENT >
std::size_t getView (InputTag const &tag, std::vector< ELEMENT const * > &result) const
 
template<typename ELEMENT >
std::size_t getView (ViewToken< ELEMENT > const &token, std::vector< ELEMENT const * > &result) const
 
template<typename ELEMENT >
bool getView (std::string const &moduleLabel, std::string const &instanceName, View< ELEMENT > &result) const
 
template<typename ELEMENT >
bool getView (InputTag const &tag, View< ELEMENT > &result) const
 
template<typename ELEMENT >
bool getView (ViewToken< ELEMENT > const &tag, View< ELEMENT > &result) const
 
template<typename PROD >
bool removeCachedProduct (Handle< PROD > &h) const
 
ProcessHistory const & processHistory () const
 
void recordAsParent (Provenance const &prov) const
 
TypeLabelMapputProducts ()
 
TypeLabelMap const & putProducts () const
 
RetrievedProductSet const & retrievedProducts () const
 
RetrievedProductIDs retrievedProductIDs () const
 
void checkPutProducts (bool checkProducts, std::set< TypeLabel > const &expectedProducts, TypeLabelMap const &putProducts)
 
BranchDescription const & getProductDescription (TypeID const &type, std::string const &productInstanceName) const
 
template<typename ELEMENT >
art::DataViewImpl::GroupQueryResultVec getView_ (std::string const &moduleLabel, std::string const &productInstanceName, std::string const &processName) const
 

Private Attributes

Principal const & principal_
 

Detailed Description

Definition at line 28 of file Results.h.

Member Typedef Documentation

Definition at line 34 of file Results.h.

using art::DataViewImpl::GroupQueryResultVec = std::vector<GroupQueryResult>
protectedinherited

Definition at line 214 of file DataViewImpl.h.

template<typename T >
using art::Results::HandleT = Handle<T>

Definition at line 70 of file Results.h.

using art::DataViewImpl::RetrievedProductIDs = std::vector<ProductID>
inherited

Definition at line 175 of file DataViewImpl.h.

Definition at line 176 of file DataViewImpl.h.

using art::DataViewImpl::TypeLabelMap = std::map<TypeLabel, PMValue>
inherited

Definition at line 177 of file DataViewImpl.h.

Constructor & Destructor Documentation

art::Results::Results ( Principal const &  p,
ModuleDescription const &  md,
cet::exempt_ptr< Consumer consumer 
)
explicit

Member Function Documentation

void art::DataViewImpl::checkPutProducts ( bool  checkProducts,
std::set< TypeLabel > const &  expectedProducts,
TypeLabelMap const &  putProducts 
)
protectedinherited
void art::Results::commit ( ResultsPrincipal )
template<typename PROD >
bool art::DataViewImpl::get ( SelectorBase const &  sel,
Handle< PROD > &  result 
) const
inlineinherited

Definition at line 307 of file DataViewImpl.h.

References art::Handle< T >::clear(), art::convert_handle(), art::Handle< T >::failedToGet(), art::DataViewImpl::get_(), art::Handle< T >::provenance(), art::DataViewImpl::recordAsParent(), art::DataViewImpl::recordParents_, and art::GroupQueryResult::succeeded().

Referenced by art::Run::endTime(), art::SubRun::endTime(), art::detail::ProcessAndEventSelector::loadTriggerResults(), and art::Event::put().

308 {
309  result.clear(); // Is this the correct thing to do if an exception is thrown?
310  // We do *not* track whether consumes was called for a SelectorBase.
311  GroupQueryResult bh = get_(WrappedTypeID::make<PROD>(), sel);
312  convert_handle(bh, result);
313  bool const ok{bh.succeeded() && !result.failedToGet()};
314  if (recordParents_ && ok) {
315  recordAsParent(*result.provenance());
316  }
317  return ok;
318 }
void recordAsParent(Provenance const &prov) const
GroupQueryResult get_(WrappedTypeID const &wrapped, SelectorBase const &) const
void convert_handle(GroupQueryResult const &, Handle< T > &)
Definition: Handle.h:248
bool const recordParents_
Definition: DataViewImpl.h:286
template<typename PROD >
bool art::DataViewImpl::get ( ProductID const  pid,
Handle< PROD > &  result 
) const
inherited

Definition at line 322 of file DataViewImpl.h.

References art::Handle< T >::clear(), art::convert_handle(), art::Handle< T >::failedToGet(), art::DataViewImpl::getByProductID_(), art::Handle< T >::provenance(), art::DataViewImpl::recordAsParent(), art::DataViewImpl::recordParents_, and art::GroupQueryResult::succeeded().

323 {
324  result.clear(); // Is this the correct thing to do if an exception is thrown?
325  // We do *not* track whether consumes was called for a ProductID.
326  GroupQueryResult bh = getByProductID_(pid);
327  convert_handle(bh, result);
328  bool const ok{bh.succeeded() && !result.failedToGet()};
329  if (recordParents_ && ok) {
330  recordAsParent(*result.provenance());
331  }
332  return ok;
333 }
void recordAsParent(Provenance const &prov) const
void convert_handle(GroupQueryResult const &, Handle< T > &)
Definition: Handle.h:248
GroupQueryResult getByProductID_(ProductID const pid) const
bool const recordParents_
Definition: DataViewImpl.h:286
template<typename PROD >
bool art::DataViewImpl::getByLabel ( std::string const &  label,
std::string const &  productInstanceName,
Handle< PROD > &  result 
) const
inlineinherited

Definition at line 344 of file DataViewImpl.h.

References label, and fillBadChanDBTables::result.

Referenced by om::TestTMapFile::analyze(), novaddt::NovaDDTTrigger::analyze(), highe::HighEnergyAna::analyze(), tut::TutAnalyzer::analyze(), calib::ADCShapeFitAna::analyze(), spilltime::analyze(), novaddt::MilliBlockChecking::analyze(), comi::ChanOcc::analyze(), qeef::QeFinderVal::analyze(), tbana::RawFileDumper::analyze(), novaddt::Evaluation::analyze(), validation::ValidateChannelInfo::analyze(), cheat::TestTrackIds::analyze(), rsim::RecordNoiseSpectrumFile::analyze(), novaddt::SingletonRejectionAna::analyze(), ddt::DDTEva::analyze(), calhit::CalHitAna::analyze(), validation::ValidateDAQ2RawDigit::analyze(), ve::VertexEva::analyze(), novaddt::TriCellTriggerAna::analyze(), calib::ThresholdAna::analyze(), cheat::CheckBackTracking::analyze(), chaninfo::CosmicEff::analyze(), remid::ReMIdValidate::analyze(), cheat::RecoCheckAna::analyze(), air::AirTree::analyze(), jmshower::RecoJMShowerAna::analyze(), calib::ParticleCorrections::analyze(), comi::CosmicMetrics::analyze(), febstat::FEBShutoff::analyze(), air::AirShower::analyze(), mcdatadaq::MockDataDAQAna::analyze(), novaddt::ClusterAna::analyze(), ddt::SMMADC::analyze(), align::AlignInspect::analyze(), dq::DAQHeaderSummaryAna::analyze(), mcchk::CloseInTime::analyze(), mmc::Validation::analyze(), tut::RecoValidationTutorial::analyze(), novaddt::DAQHeaderAna::analyze(), calib::TestParticleCorrections::analyze(), mcchk::DetAna::analyze(), G4MismatchAna::analyze(), dprf::ChannelPlots::analyze(), remid::ReMIdTrain::analyze(), zcl::SMMTriggerAna::analyze(), tut::reco2016::RecoObjectsTutorial::analyze(), tut::yn2017::AnalysisModule::analyze(), mcchk::ShowerAnaCheck::analyze(), beamlinereco::BeamlineRecoDump::analyze(), slicer::S4DParamCalc::analyze(), beamlinereco::ToFSingleCounterAnalysis::analyze(), BeamlineAna::analyze(), air::CosmicTrackRate::analyze(), tut::yn2017::DebugThis::analyze(), mcchk::MonopoleAna::analyze(), dprf::TrackPlots::analyze(), numue::NumuEAna::analyze(), align::Alignment::analyze(), testbeam::BeamlineRecoValidation::analyze(), febstat::EventFEBStatus::analyze(), tbana::DSToFAna::analyze(), mcchk::RockAna::analyze(), murem::MuonRemoveAna::analyze(), novaddt::SNAna::analyze(), align::SplitTracks::analyze(), sn::SNSlicerAna::analyze(), sn::SupernovaAna::analyze(), beamlinereco::ToFRecoAnalysis::analyze(), novatb::TOFTimingResolution::analyze(), mcchk::NeutrinoAna::analyze(), mono::DataCheckMonopole::analyze(), pa::ClusterEva::analyze(), pa::HitEva::analyze(), calib::AssessCalib::analyze(), slicer::IdenticalSlicerAna::analyze(), testbeam::TestBeamCommissioning::analyze(), beamlinerecoana::WCTrackRecoAnalysis::analyze(), vf::TrackEva::analyze(), comi::DataCheck::analyze(), calib::EnergyStandardCandles::analyze(), calib::HitEfficiency::analyze(), tbana::BeamStructureAna::analyze(), validation::NoiseClusterAnalysis::analyze(), meta::Metadata::analyze(), zcl::MMCheater::analyze(), novaddt::HorizontalMuonAna::analyze(), remid::ReMIdDedx::analyze(), nnbar::SigVsBkgSimCompare::analyze(), chaninfo::BadChanValidate::analyze(), comi::NumiFilteringAna::analyze(), zcl::FmmTriggerAna::analyze(), mcchk::LeptonAna::analyze(), novaddt::Calibration::analyze(), comi::Leana::analyze(), tbana::BeamlineTriggerAna::analyze(), ddt::DataSliceEva::analyze(), tbem::TBRecoAna::analyze(), ddt::SlicerEva::analyze(), calib::PEResponse::analyze(), novatb::TOFTriggerAna::analyze(), novatb::TriggerRateAna::analyze(), zcl::FmmTrackerValidation::analyze(), zcl::FmmTrackerAna::analyze(), trk::KalmanTrackAna::analyze(), showere::ShowerEnergyAna::analyze(), beamlinereco::EventWaveformDump::analyze(), trigmon::LongReadoutAnalyzer::analyze(), novaddt::SendTriggerSignal::analyze(), cvn::CVNEventDump::analyze(), hough::HoughValidate::analyze(), cvn::CVNCosmicEventDump::analyze(), earms::ElasticArmsValidate::analyze(), bpfit::BreakPointAna::analyze(), cvn::CVNEventProngDump::analyze(), calib::StopperThreshold::analyze(), Mono::Mono::analyze(), novaddt::UpMuAna::analyze(), mono::SlowMonopoleAna::analyze(), mcchk::DetSimAna::analyze(), slicer::SlicerAna::analyze(), rockmuon::NDRockMuon::analyze(), ncid::NCNNKerasVal::analyze(), remid::ReMIdDedxRock::analyze(), comi::NearlineAna::analyze(), ncpi0::TwoProngBDTAna::analyze(), remid::ReMIdDedxFD::analyze(), remid::ReMIdDedxStudies::analyze(), zcl::FastMMStudy::analyze(), mono::Monopole::analyze(), fuzz::FuzzyKValidate::analyze(), nnbar::ShowerMuonCoincidence::analyze(), testbeam::BeamlineEventDisplay::analyze(), tbana::DetectorRateShutOff::analyze(), beamlinereco::ToFAnalysisMini::analyze(), LightLevels::analyze(), calib::CosmicTrends::analyze(), CerenkovResponse::analyze(), air::AirKalmanAna::analyze(), ncs::Xbeam::analyze(), ncs::GenieTruth::analyze(), ncs::Xeff::analyze(), calib::CalibAna::analyze(), moonshadowana::MoonShadowAna::analyze(), ncs::ROCKMRE::analyze(), ddt::SuperDDTEva::analyze(), slid::LIDTraining::analyze(), beamlinesim::CombinedBeamlineDetectorAna::analyze(), moonshadowana::MoonShadowAnaHough::analyze(), ncs::NCAna::analyze(), upmuana::UpMuRecoAna::analyze(), upmuana::UpMuAnalysis::analyze(), nnbar::RecoAnalysis::analyze(), beamlinereco::ToFPositionRecoAnalysis::analyze(), sn::SNMichelAnalyzer::analyze(), htk::HoughTrack::analyze(), novatb::BeamTuning::analyze(), trk::CosmicTrackAna::analyze(), red::EWCosmics::analyze(), comi::FEBFlash::analyze(), murem::MRCCAna::analyze(), lem::UnTranspose::beginRun(), lem::MakeMatches::beginRun(), lem::MakePID::beginRun(), calib::DriftCorrection::beginRun(), caf::CAFMaker::beginRun(), mcchk::POTAna::beginSubRun(), jmshower::RecoJMShowerAna::beginSubRun(), skim::RandomEventFilter::beginSubRun(), validation::NoiseClusterAnalysis::beginSubRun(), comi::NumiFilteringAna::beginSubRun(), air::AirKalmanAna::beginSubRun(), caf::CAFMaker::beginSubRun(), trk::CosmicTrackAna::beginSubRun(), sn::SNMichelAnalyzer::ClusterAroundTrackEnds(), evd::PlotView::Draw(), calib::SumRunsCalib::endRun(), calib::AbsCalib::endRun(), calib::BetheBlochFit::endRun(), calib::AttenFit::endRun(), calib::SumSubrunsCalib::endSubRun(), rsim::RecordNoiseSpectrumFile::endSubRun(), MergeGenCollections::MergeGenCollections::endSubRun(), comi::Cana::endSubRun(), lem::MakeLibrary::endSubRun(), ifdb::IFDBSpillInfo::endSubRun(), calib::PEResponse::endSubRun(), calib::AttenFit::endSubRun(), slicer::SlicerAna::endSubRun(), calib::DCMTimingOffset::endSubRun(), ifdb::MIN::endSubRun(), bpfit::BreakPointProtonAna::endSubRun(), ncs::Xbeam::endSubRun(), ncs::Xeff::endSubRun(), ncs::ROCKMRE::endSubRun(), ncs::NCAna::endSubRun(), caf::CAFMaker::endSubRun(), art::Run::endTime(), art::SubRun::endTime(), filter::Filter::FillDigitVariables(), LSTME::FillLSTME::fillEnergies(), filter::Filter::FillG4GenVariables(), caf::FillMRCCParentInfo(), skim::CosmicBeamComparison::FillNueHistograms(), SliceLID::FillSliceLID::fillSliceLIDPreds(), filter::Filter::FillSliceVariables(), filter::Filter::FillTrackVariables(), murem::MuonRemove::FillTruthInfo(), filter::Filter::FillTruthVariables(), evgen::CRVFilter::filter(), lem::ApplyFilter::filter(), lem::BackgroundEnricher::filter(), novaddt::HighSortByTDC::filter(), novaddt::SortByTDC::filter(), novaddt::SortByPlane::filter(), novaddt::SortByDCM::filter(), novaddt::Clusterer::filter(), comi::CanaFilter::filter(), novaddt::TDSlice::filter(), novaddt::RemoveNoise::filter(), highe::HighEnergyFilt::filter(), novaddt::SpaceSlice::filter(), calib::ThroughgoingSelection::filter(), evgen::OccupiedSpillFilter::filter(), novaddt::DCMSlice::filter(), novaddt::HighADCFilter::filter(), novaddt::TimeDCMSlice::filter(), calib::RockMuonStopperSelection::filter(), calib::StopperSelection::filter(), air::AirFilter::filter(), novaddt::TimeSlice::filter(), novaddt::HighETrigger::filter(), beamlinereco::GoodBeamlineEventFilter::filter(), util::RemoveTBSpills::filter(), novaddt::DDTStreamer::filter(), util::RemoveBeamSpills::filter(), novaddt::TriCellTrigger::filter(), novaddt::DBSlicer::filter(), novaddt::DDTDemo::filter(), mono::HighEnergySliceRemoval::filter(), novaddt::ActivityTrigger::filter(), novaddt::NuESelect::filter(), jmshower::RecoJMShowerFilter::filter(), filter::FLSFilter::filter(), snutil::DDSNEWSfilter::filter(), util::RemoveBeamSpillsPrecise::filter(), beamlinereco::DigitizerSaturationFilter::filter(), novaddt::FEBOverflowTrigger::filter(), beamlinereco::ToFFilter::filter(), DataCheck::HardwareStatusCheck::filter(), novaddt::MoonShadow::filter(), calib::StopperFilter::filter(), EliminateBeamSpills::filter(), novaddt::ActivityTriggerAna::filter(), novaddt::SlowMonopoleTrigger::filter(), mono::EventSelector::filter(), comi::NumiFiltering::filter(), novaddt::FastMMTrigger::filter(), mono::MonopoleCluster::filter(), novaddt::NNFastMMTrigger::filter(), calib::TimingCalFilter::filter(), novaddt::HoughTracker::filter(), filter::TruthContain::filter(), novaddt::SlowMMTrigger::filter(), mono::SlowMonopoleFilt::filter(), novaddt::HorizontalMuonTrigger::filter(), chaninfo::FindSwappedChannels::filter(), util::RunEventFilter::filter(), calib::MuondEdx::filter(), calib::DetRespDrift::filter(), showere::ShowerEnergyFilterMC::filter(), util::TimeFilter::filter(), mono::MonopoleTrack::filter(), novaddt::UpMuTrigger::filter(), calib::MuonTrackHits::filter(), novaddt::MichelETrigger::filter(), calib::MuondEdxAna::filter(), calib::EnergyStandardCandles::FindStoppingMuons(), evd::SliceNavigator::GetBounds(), evd::SliceNavigator::GetBox(), art::DataViewImpl::getByLabel(), caf::CAFMaker::GetByLabelIfExists(), caf::CAFMaker::GetByLabelStrict(), art::DataViewImpl::getByToken(), evd::SimulationDrawer::GetFLSHits(), SliceLID::FillSliceLID::getIsRHC(), LSTME::FillLSTME::getIsRHC(), art::DataViewImpl::getPointerByLabel(), evd::SliceNavigator::GetProducts(), evd::SliceNavigator::GetProductsImplFull(), evd::SliceNavigator::GetProductsImplPart(), evd::RawDataDrawer::GetRawDigits(), getrawtrigger(), novaddt::SupernovaTrigger::GetTime(), novaddt::MoonShadow::GetTime(), art::DataViewImpl::getValidHandle(), remid::RecoMuon::Init(), skim::EvaluatorNumu::Initialize(), skim::EvaluatorNue::Initialize(), rb::IsFiltered(), regcvntf::RegCVNTF::IsRHC(), nuonecvntf::NuonECVNTF::IsRHC(), cvneventtf::CVNEventTF::IsRHC(), cvnprongtf::CVNProngTF::IsRHC(), cosrej::MakeNueCosRej::IsRHC(), comi::Cana::LoadMCInfo(), evtsum::EventSummary::MakeOutput(), evg::MCTruthToDk2NuHackItr::MCTruthToDk2NuHackItr(), earms::ElasticArmsHS::MCVertex(), novaddt::UpMuAna::populateFLSmap(), evd::SliceNavigator::postProcessEvent(), photrans::FiberBrightness::preBeginRun(), nova::dbi::RunHistoryService::preBeginRun(), nova::dbi::RunHistoryService::preBeginSubrun(), jmshower::RecoJMShower::PreSel(), util::RewriteSpillData::produce(), cvntf::CVNTF::produce(), novaddt::SortByView::produce(), presel::LEMPresel::produce(), lem::LEMAssociator::produce(), slicer::MMSlicer::produce(), trk::TrkAssn::produce(), vf::VertexFinder::produce(), util::TruthExpand::produce(), slicer::Slicer::produce(), qeef::QeFinder::produce(), photrans::PhotonSystRewriter::produce(), hough::HoughT::produce(), tf::TimingFit::produce(), cheat::ClusterCheater::produce(), noe::noe::produce(), cheat::TrueEnergy::produce(), cheat::ProngCheater::produce(), filter::TruthFilter::produce(), hv::HoughVertex::produce(), tut::TutProducer::produce(), cheat::ShowerCheater::produce(), recodemo::RecoDemo::produce(), MergeCalCollections::MergeCalCollections::produce(), cheat::TrackCheater::produce(), trk::KalmanTrack::produce(), MergeTBDaqCollections::MergeTBDaqCollections::produce(), slicer::Slicer4D::produce(), demo::DemoModule::produce(), nuesand::FillNueSandbox::produce(), lem::UnTranspose::produce(), NovaDDTHitProducer::produce(), nnbar::ShowerProducer::produce(), beamlinereco::TimeOfFlightReco::produce(), slicer::TruthSlicer::produce(), wsnumu::WSNumu::produce(), calib::ResizeDetector::produce(), numue::TrackOverlapECalc::produce(), trk::KalmanTrackMerge::produce(), lem::LEMSummarizer::produce(), MergeG4Collections::MergeG4Collections::produce(), MergeDaqCollections::MergeDaqCollections::produce(), presel::RockPresel::produce(), MergeCollections::MergeCollections::produce(), regcvntf::RegCVNTF::produce(), nussand::FillNusSandbox::produce(), slid::Recluster::produce(), novaddt::TrackFit::produce(), trackinfo::TrackInfo::produce(), presel::CosmicVeto::produce(), hough::MultiHoughT::produce(), numusand::FillSandbox::produce(), presel::CosmicCVNVeto::produce(), presel::NuePresel::produce(), lem::Preselection::produce(), jmshower::JMTrackMerge::produce(), nuonecvntf::NuonECVNTF::produce(), calib::FiberCalibration::produce(), slid::SliceLIDBuilder::produce(), lem::AlignLibToVtx::produce(), tut::yn2020::FancyScience::produce(), zcl::SPCluster::produce(), g4n::TruthSlim::produce(), MergeGenCollections::MergeGenCollections::produce(), lem::MakeMatches::produce(), cosrej::CosRej::produce(), cvnprongtf::CVNProngTF::produce(), beamlinereco::CkovCounterReco::produce(), calib::PCHitTransposer::produce(), daq2raw::DAQHit2Raw::produce(), cvneventtf::CVNEventTF::produce(), trk::CosmicTrack::produce(), cvnneutronprongtf::CVNNeutronProngTF::produce(), beamlinereco::ToFCalibration::produce(), numue::NumuEnergy::produce(), dq::DAQHeaderSummary::produce(), lem::FindMatchesTranspose::produce(), muonid::MuonIDProd::produce(), airshower::AirSlicer::produce(), dt::ViewMerger::produce(), lem::MakeLibrary::produce(), wcvtx::WCVertex::produce(), calib::TimingCalibration::produce(), beamlinereco::LEHitReco::produce(), comi::Cana::produce(), dt::DiscreteTracker::produce(), zcl::SMMCluster::produce(), beamlinereco::CFDHitReco::produce(), photrans::PhotonTransport::produce(), beamlinereco::WCTrackReco::produce(), calib::PCHitsList::produce(), lem::FindLEMMatches::produce(), ifdb::IFDBSpillInfo::produce(), jmshower::JMClusterMerge::produce(), sn::SNSlicer::produce(), zcl::FMMTracker::produce(), sn::SupernovaMCCluster::produce(), vdt::VertexDT::produce(), ifdb::TBSpillInfo::produce(), ncpi0::MakeNCPi0BkgRej::produce(), cvn::CVNMapper::produce(), zcl::FmmTriggerEvd::produce(), calib::DriftResponseCalc::produce(), lem::MakePID::produce(), slid::LIDBuilder::produce(), lem::LEM::produce(), murem::MRE::produce(), jmshower::NueSel::produce(), crvtx::CosmicRayVertex::produce(), lem::LEMWorkerOutput::produce(), rvp::RecVarPID::produce(), dqsf::DQSpillFlags::produce(), dif::DiFShowerFinder::produce(), xnue::XnuePID::produce(), slid::SPIDBuilder::produce(), jmshower::NueSelLID::produce(), cheat::MCCheater::produce(), g4n::G4Gen::produce(), ncid::MakeNCCosRej::produce(), xsrec::MakeXSecCCPi0Inc::produce(), remid::RecoMuon::produce(), sn::SNBackgroundRejection::produce(), g4rwgt::MakeG4WeightTable::produce(), lem::LEMClient::produce(), cvn::CVNAddTrainingData::produce(), murem::MergeDigits::produce(), upmuana::UpMuProb::produce(), ifdb::MIN::produce(), rsim::ReadoutSim::produce(), ncid::NCNNKeras::produce(), photrans::ImprovedTransport::produce(), murem::MuonRemove::produce(), murem::FindMREParent::produce(), beamlinesim::BeamlineSimInput::produce(), murem::FindParent::produce(), murem::MergeTruth::produce(), jmshower::RecoJMShower::produce(), slicemergeviews::SliceMergeViews::produce(), gibuu::GiBUURegen::produce(), tdslicer::TDSlicer::produce(), me::MEFinder::produce(), art::Event::put(), calib::SumAttenuationProfiles::readResults(), cmf::ContourFromLibrary::readResults(), calib::AttenuationFit::readResults(), fnex::ContourMaker::readSingleResults(), fnex::StarPlot::readSingleResults(), fnex::ReadFitResults::readSingleResults(), fnex::ContourMaker::readVectorResults(), fnex::ReadFitResults::readVectorResults(), cheat::BackTracker::Rebuild(), jmshower::RecoJMShower::RecoShowers(), skim::NumuCCpiSkimmer::Skim(), skim::NumuSkimmer::Skim(), skim::NueSkimmer::Skim(), evd::SliceNavigator::SlicesToNavigate(), dq::DAQHeaderSummary::UnpackRawDaqData(), and om::OnMonProd::UnpackRawDaqData().

347 {
348  return getByLabel<PROD>(label, productInstanceName, {}, result);
349 }
const char * label
template<typename PROD >
bool art::DataViewImpl::getByLabel ( std::string const &  label,
std::string const &  productInstanceName,
std::string const &  processName,
Handle< PROD > &  result 
) const
inlineinherited

Definition at line 353 of file DataViewImpl.h.

References art::DataViewImpl::branchType_, art::Handle< T >::clear(), art::DataViewImpl::consumer_, art::convert_handle(), art::Handle< T >::failedToGet(), art::DataViewImpl::getByLabel_(), label, art::ProductInfo::Product, art::Handle< T >::provenance(), art::DataViewImpl::recordAsParent(), art::DataViewImpl::recordParents_, and art::GroupQueryResult::succeeded().

357 {
358  result.clear(); // Is this the correct thing to do if an exception is thrown?
359  auto const wrapped = WrappedTypeID::make<PROD>();
360  ProductInfo const pinfo{ProductInfo::ConsumableType::Product,
361  wrapped.product_type,
362  label,
363  productInstanceName,
364  processName};
365  consumer_->validateConsumedProduct(branchType_, pinfo);
366  GroupQueryResult bh =
367  getByLabel_(wrapped, label, productInstanceName, processName);
368  convert_handle(bh, result);
369  bool const ok{bh.succeeded() && !result.failedToGet()};
370  if (recordParents_ && ok) {
371  recordAsParent(*result.provenance());
372  }
373  return ok;
374 }
void recordAsParent(Provenance const &prov) const
BranchType const branchType_
Definition: DataViewImpl.h:283
const char * label
cet::exempt_ptr< Consumer > consumer_
Definition: DataViewImpl.h:291
void convert_handle(GroupQueryResult const &, Handle< T > &)
Definition: Handle.h:248
GroupQueryResult getByLabel_(WrappedTypeID const &wrapped, std::string const &label, std::string const &productInstanceName, std::string const &processName) const
bool const recordParents_
Definition: DataViewImpl.h:286
template<typename PROD >
PROD const & art::DataViewImpl::getByLabel ( InputTag const &  tag) const
inlineinherited

same as above, but using the InputTag class

Definition at line 378 of file DataViewImpl.h.

References art::DataViewImpl::getByLabel(), and make_syst_table_plots::h.

379 {
380  Handle<PROD> h;
381  getByLabel(tag, h);
382  return *h;
383 }
bool getByLabel(std::string const &label, std::string const &productInstanceName, Handle< PROD > &result) const
Definition: DataViewImpl.h:344
template<typename PROD >
bool art::DataViewImpl::getByLabel ( InputTag const &  tag,
Handle< PROD > &  result 
) const
inlineinherited

Definition at line 337 of file DataViewImpl.h.

References art::InputTag::instance(), art::InputTag::label(), art::InputTag::process(), and fillBadChanDBTables::result.

338 {
339  return getByLabel<PROD>(tag.label(), tag.instance(), tag.process(), result);
340 }
template<typename PROD >
bool art::DataViewImpl::getByToken ( ProductToken< PROD > const &  token,
Handle< PROD > &  result 
) const
inlineinherited

Definition at line 387 of file DataViewImpl.h.

References art::DataViewImpl::getByLabel(), art::ProductToken< T >::inputTag_, fillBadChanDBTables::result, and getGoodRuns4SAM::tag.

Referenced by bpfit::BPFdEdxHistoMaker::analyze(), bpfit::BPFEnergyAna::analyze(), bpfit::BPFTmvaTrainer::analyze(), bpf::BPFCVNAna::analyze(), bpfit::BreakPointProtonAna::analyze(), bpfit::BPFTmvaTrainer::endSubRun(), gibuu::GiBUURegen::endSubRun(), art::Run::endTime(), art::SubRun::endTime(), util::CopyCellHits::filter(), util::NonEmptyCluster::filter(), evgen::OccupiedSpillFilter::filter(), evgen::GENIEFilter::filter(), util::HasStandardRecord::filter(), calhit::HasCellHits::filter(), bsf::BremShowerFilter::filter(), bpfit::DimuonFitter::FindSlices(), bpfit::BreakPoint::FindSlices(), cosmic::CosmicExposureInfo::produce(), cvntf::CVNCosmicTFFilt::produce(), cvntf::CVNCosmicTF::produce(), cvn::CVNCosmicMapper::produce(), cosrej::CosRej::produce(), earms::ElasticArmsHS::produce(), ndreco::NDReco::produce(), cvn::CVNMapper::produce(), rwgt::MakeGENIEReweightTable::produce(), cvntf::CVNProngEvaluatorTF::produce(), calhit::RemoveBadChannels::produce(), cvn::RegCVNMapper::produce(), calhit::CalHit::produce(), bpfit::BPFEnergyEstimator::produce(), bpfit::BPFEnergyEstimatorOnly::produce(), bpfit::BPFPIdMaker::produce(), cosrej::MakeNueCosRej::produce(), fuzz::FuzzyKVertex::produce(), nerd::NERDProng::produce(), gibuu::GiBUURegen::produce(), and art::Event::put().

389 {
390  auto const& tag = token.inputTag_;
391  return getByLabel(tag.label(), tag.instance(), tag.process(), result);
392 }
bool getByLabel(std::string const &label, std::string const &productInstanceName, Handle< PROD > &result) const
Definition: DataViewImpl.h:344
::xsd::cxx::tree::token< char, normalized_string > token
Definition: Database.h:156
template<typename PROD >
void art::DataViewImpl::getMany ( SelectorBase const &  sel,
std::vector< Handle< PROD >> &  results 
) const
inlineinherited

Definition at line 421 of file DataViewImpl.h.

References art::DataViewImpl::branchType_, art::DataViewImpl::consumer_, art::convert_handle(), art::DataViewImpl::getMany_(), make_syst_table_plots::h, art::ProductInfo::Many, datagram_client::products, art::DataViewImpl::recordAsParent(), art::DataViewImpl::recordParents_, fillBadChanDBTables::result, and makeDatasetsPage::results.

Referenced by art::Run::endTime(), art::SubRun::endTime(), art::DataViewImpl::getManyByType(), and art::Event::put().

423 {
424  auto const wrapped = WrappedTypeID::make<PROD>();
425  consumer_->validateConsumedProduct(
426  branchType_,
427  ProductInfo{ProductInfo::ConsumableType::Many, wrapped.product_type});
428 
429  std::vector<Handle<PROD>> products;
430  for (auto const& qr : getMany_(wrapped, sel)) {
431  Handle<PROD> result;
432  convert_handle(qr, result);
433  products.push_back(result);
434  }
435  results.swap(products);
436  if (!recordParents_) {
437  return;
438  }
439  for (auto const& h : results) {
440  recordAsParent(*h.provenance());
441  }
442 }
void recordAsParent(Provenance const &prov) const
BranchType const branchType_
Definition: DataViewImpl.h:283
cet::exempt_ptr< Consumer > consumer_
Definition: DataViewImpl.h:291
void convert_handle(GroupQueryResult const &, Handle< T > &)
Definition: Handle.h:248
GroupQueryResultVec getMany_(WrappedTypeID const &wrapped, SelectorBase const &sel) const
bool const recordParents_
Definition: DataViewImpl.h:286
template<typename PROD >
void art::DataViewImpl::getManyByType ( std::vector< Handle< PROD >> &  results) const
inlineinherited
template<typename PROD >
PROD const * art::DataViewImpl::getPointerByLabel ( InputTag const &  tag) const
inlineinherited

Definition at line 396 of file DataViewImpl.h.

References art::DataViewImpl::getByLabel(), and make_syst_table_plots::h.

Referenced by art::Run::endTime(), art::SubRun::endTime(), and art::Event::put().

397 {
398  Handle<PROD> h;
399  getByLabel(tag, h);
400  return &(*h);
401 }
bool getByLabel(std::string const &label, std::string const &productInstanceName, Handle< PROD > &result) const
Definition: DataViewImpl.h:344
BranchDescription const& art::DataViewImpl::getProductDescription ( TypeID const &  type,
std::string const &  productInstanceName 
) const
protectedinherited
template<typename PROD >
ValidHandle<PROD> art::DataViewImpl::getValidHandle ( InputTag const &  tag) const
inherited
template<typename PROD >
ValidHandle<PROD> art::DataViewImpl::getValidHandle ( ProductToken< PROD > const &  token) const
inherited
template<typename PROD >
art::ValidHandle<PROD> art::DataViewImpl::getValidHandle ( InputTag const &  tag) const
inlineinherited

Definition at line 405 of file DataViewImpl.h.

References art::DataViewImpl::getByLabel(), make_syst_table_plots::h, and art::ValidHandle< T >::provenance().

406 {
407  Handle<PROD> h;
408  getByLabel(tag, h);
409  return ValidHandle<PROD>(&(*h), *h.provenance());
410 }
bool getByLabel(std::string const &label, std::string const &productInstanceName, Handle< PROD > &result) const
Definition: DataViewImpl.h:344
template<typename PROD >
art::ValidHandle<PROD> art::DataViewImpl::getValidHandle ( ProductToken< PROD > const &  token) const
inlineinherited

Definition at line 414 of file DataViewImpl.h.

References art::ProductToken< T >::inputTag_.

415 {
416  return getValidHandle<PROD>(token.inputTag_);
417 }
::xsd::cxx::tree::token< char, normalized_string > token
Definition: Database.h:156
template<typename ELEMENT >
std::size_t art::DataViewImpl::getView ( std::string const &  moduleLabel,
std::string const &  productInstanceName,
std::vector< ELEMENT const * > &  result 
) const
inherited

Definition at line 474 of file DataViewImpl.h.

References art::DataViewImpl::fillView_().

Referenced by art::Run::endTime(), art::SubRun::endTime(), evd::SliceNavigator::GetProductsImplFull(), art::DataViewImpl::getView(), and art::Event::put().

477 {
478  auto bhv = getView_<ELEMENT>(moduleLabel, productInstanceName, {});
479  std::size_t const orig_size = result.size();
480  fillView_(bhv[0], result);
481  return result.size() - orig_size;
482 } // getView<>()
void fillView_(GroupQueryResult &bh, std::vector< ELEMENT const * > &result) const
Definition: DataViewImpl.h:531
template<typename ELEMENT >
std::size_t art::DataViewImpl::getView ( InputTag const &  tag,
std::vector< ELEMENT const * > &  result 
) const
inherited

Definition at line 486 of file DataViewImpl.h.

References art::DataViewImpl::fillView_(), art::InputTag::instance(), art::InputTag::label(), and art::InputTag::process().

488 {
489  auto bhv = getView_<ELEMENT>(tag.label(), tag.instance(), tag.process());
490  std::size_t const orig_size = result.size();
491  fillView_(bhv[0], result);
492  return result.size() - orig_size;
493 } // getView<>()
void fillView_(GroupQueryResult &bh, std::vector< ELEMENT const * > &result) const
Definition: DataViewImpl.h:531
template<typename ELEMENT >
std::size_t art::DataViewImpl::getView ( ViewToken< ELEMENT > const &  token,
std::vector< ELEMENT const * > &  result 
) const
inherited
template<typename ELEMENT >
bool art::DataViewImpl::getView ( std::string const &  moduleLabel,
std::string const &  instanceName,
View< ELEMENT > &  result 
) const
inherited

Definition at line 497 of file DataViewImpl.h.

References art::DataViewImpl::fillView_(), fillBadChanDBTables::result, art::View< T >::set_innards(), and art::View< T >::vals().

500 {
501  auto bhv = getView_<ELEMENT>(moduleLabel, productInstanceName, {});
502  fillView_(bhv[0], result.vals());
503  result.set_innards(bhv[0].result()->productID(),
504  bhv[0].result()->uniqueProduct());
505  return true;
506 }
void fillView_(GroupQueryResult &bh, std::vector< ELEMENT const * > &result) const
Definition: DataViewImpl.h:531
template<typename ELEMENT >
bool art::DataViewImpl::getView ( InputTag const &  tag,
View< ELEMENT > &  result 
) const
inherited

Definition at line 510 of file DataViewImpl.h.

References art::DataViewImpl::fillView_(), art::InputTag::instance(), art::InputTag::label(), art::InputTag::process(), fillBadChanDBTables::result, art::View< T >::set_innards(), and art::View< T >::vals().

511 {
512  auto bhv = getView_<ELEMENT>(tag.label(), tag.instance(), tag.process());
513  fillView_(bhv[0], result.vals());
514  result.set_innards(bhv[0].result()->productID(),
515  bhv[0].result()->uniqueProduct());
516  return true;
517 }
void fillView_(GroupQueryResult &bh, std::vector< ELEMENT const * > &result) const
Definition: DataViewImpl.h:531
template<typename ELEMENT >
bool art::DataViewImpl::getView ( ViewToken< ELEMENT > const &  tag,
View< ELEMENT > &  result 
) const
inherited

Definition at line 521 of file DataViewImpl.h.

References art::DataViewImpl::getView(), and art::ViewToken< Element >::inputTag_.

523 {
524  return getView(token.inputTag_, result);
525 }
std::size_t getView(std::string const &moduleLabel, std::string const &productInstanceName, std::vector< ELEMENT const * > &result) const
Definition: DataViewImpl.h:474
::xsd::cxx::tree::token< char, normalized_string > token
Definition: Database.h:156
template<typename ELEMENT >
art::DataViewImpl::GroupQueryResultVec art::DataViewImpl::getView_ ( std::string const &  moduleLabel,
std::string const &  productInstanceName,
std::string const &  processName 
) const
inherited

Definition at line 453 of file DataViewImpl.h.

References art::DataViewImpl::branchType_, art::DataViewImpl::consumer_, art::DataViewImpl::ensureUniqueProduct_(), art::DataViewImpl::getMatchingSequenceByLabel_(), art::DataViewImpl::removeNonViewableMatches_(), and art::ProductInfo::ViewElement.

456 {
457  TypeID const typeID{typeid(ELEMENT)};
458  ProductInfo const pinfo{ProductInfo::ConsumableType::ViewElement,
459  typeID,
460  moduleLabel,
461  productInstanceName,
462  processName};
463  consumer_->validateConsumedProduct(branchType_, pinfo);
464  auto bhv =
465  getMatchingSequenceByLabel_(moduleLabel, productInstanceName, processName);
466  removeNonViewableMatches_(typeID, bhv);
468  bhv.size(), typeID, moduleLabel, productInstanceName, processName);
469  return bhv;
470 } // getView_<>()
GroupQueryResultVec getMatchingSequenceByLabel_(std::string const &label, std::string const &productInstanceName, std::string const &processName) const
void ensureUniqueProduct_(std::size_t nFound, TypeID const &typeID, std::string const &moduleLabel, std::string const &productInstanceName, std::string const &processName) const
BranchType const branchType_
Definition: DataViewImpl.h:283
cet::exempt_ptr< Consumer > consumer_
Definition: DataViewImpl.h:291
void removeNonViewableMatches_(TypeID const &requestedElementType, GroupQueryResultVec &results) const
ProcessHistory const& art::DataViewImpl::processHistory ( ) const
inherited
EDProductGetter const* art::Results::productGetter ( ProductID const  pid) const
template<typename PROD >
art::ProductID art::Results::put ( std::unique_ptr< PROD > &&  product)
template<typename PROD >
art::ProductID art::Results::put ( std::unique_ptr< PROD > &&  product,
std::string const &  productInstanceName 
)

Definition at line 85 of file Results.h.

References art::DataViewImpl::getProductDescription(), art::RangeSet::invalid(), art::errors::NullPointerError, stan::io::product(), art::errors::ProductPutFailure, art::DataViewImpl::putProducts(), and fillBadChanDBTables::result.

87 {
88  TypeID const tid{typeid(PROD)};
89  if (!product) { // Null pointer is illegal.
91  << "Results::put: A null unique_ptr was passed to 'put'.\n"
92  << "The pointer is of type " << tid << ".\n"
93  << "The specified productInstanceName was '" << productInstanceName
94  << "'.\n";
95  }
96 
97  auto const& pd = getProductDescription(tid, productInstanceName);
98  auto wp = std::make_unique<Wrapper<PROD>>(std::move(product));
99 
100  auto result = putProducts().emplace(
101  TypeLabel{
102  tid, productInstanceName, SupportsView<PROD>::value, false /*not used*/},
103  PMValue{std::move(wp), pd, RangeSet::invalid()});
104  if (!result.second) {
106  << "Results::put: Attempt to put multiple products with the\n"
107  << " following description onto the Results.\n"
108  << " Products must be unique per Results.\n"
109  << "=================================\n"
110  << pd << "=================================\n";
111  }
112 
113  return pd.productID();
114 }
static RangeSet invalid()
const XML_Char int const XML_Char * value
Definition: expat.h:331
cet::coded_exception< errors::ErrorCodes, ExceptionDetail::translate > Exception
Definition: Exception.h:66
T product(std::vector< T > dims)
TypeLabelMap & putProducts()
Definition: DataViewImpl.h:183
BranchDescription const & getProductDescription(TypeID const &type, std::string const &productInstanceName) const
TypeLabelMap& art::DataViewImpl::putProducts ( )
inlineprotectedinherited

Definition at line 183 of file DataViewImpl.h.

References art::DataViewImpl::putProducts_.

Referenced by put(), art::Event::put(), art::Run::put_(), art::SubRun::put_(), and art::DataViewImpl::retrievedProducts().

184  {
185  return putProducts_;
186  }
TypeLabelMap putProducts_
Definition: DataViewImpl.h:266
TypeLabelMap const& art::DataViewImpl::putProducts ( ) const
inlineprotectedinherited

Definition at line 188 of file DataViewImpl.h.

References art::DataViewImpl::putProducts_.

189  {
190  return putProducts_;
191  }
TypeLabelMap putProducts_
Definition: DataViewImpl.h:266
void art::DataViewImpl::recordAsParent ( Provenance const &  prov) const
protectedinherited
template<typename PROD >
bool art::DataViewImpl::removeCachedProduct ( Handle< PROD > &  h) const
inherited
RetrievedProductIDs art::DataViewImpl::retrievedProductIDs ( ) const
protectedinherited
RetrievedProductSet const& art::DataViewImpl::retrievedProducts ( ) const
inlineprotectedinherited
size_t art::DataViewImpl::size ( ) const
inherited

Member Data Documentation

Principal const& art::Results::principal_
private

Definition at line 73 of file Results.h.


The documentation for this class was generated from the following file: