Classes | Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
arttest::SeekToEventClient Class Reference

#include <SeekToEventClient.h>

Classes

struct  Config
 

Public Types

using Parameters = art::ServiceTable< Config >
 

Public Member Functions

 SeekToEventClient (Parameters const &, art::ActivityRegistry &)
 

Private Member Functions

void postBeginJobWorkers (art::InputSource *input_source, std::vector< art::Worker * > const &)
 
void preProcessEvent (art::Event const &, art::ScheduleContext)
 
void postProcessEvent (art::Event const &, art::ScheduleContext)
 

Private Attributes

std::vector< art::EventIDnextEventsToProcess_
 
cet::exempt_ptr< art::RootInputinput_ {nullptr}
 

Detailed Description

Definition at line 30 of file SeekToEventClient.h.

Member Typedef Documentation

Definition at line 42 of file SeekToEventClient.h.

Constructor & Destructor Documentation

arttest::SeekToEventClient::SeekToEventClient ( Parameters const &  config,
art::ActivityRegistry r 
)

Definition at line 12 of file SeekToEventClient_service.cc.

14  : nextEventsToProcess_{config().nextEventsToProcess()}
15 {
19 }
void postBeginJobWorkers(art::InputSource *input_source, std::vector< art::Worker * > const &)
void postProcessEvent(art::Event const &, art::ScheduleContext)
GlobalSignal< detail::SignalResponseType::LIFO, void(InputSource *, std::vector< Worker * > const &)> sPostBeginJobWorkers
GlobalSignal< detail::SignalResponseType::LIFO, void(Event const &, ScheduleContext)> sPostProcessEvent
std::vector< art::EventID > nextEventsToProcess_
void preProcessEvent(art::Event const &, art::ScheduleContext)

Member Function Documentation

void arttest::SeekToEventClient::postBeginJobWorkers ( art::InputSource input_source,
std::vector< art::Worker * > const &   
)
private

Definition at line 22 of file SeekToEventClient_service.cc.

25 {
26  if (nextEventsToProcess_.empty())
27  return;
28 
29  input_ = dynamic_cast<art::RootInput*>(input_source);
30  if (!input_)
32  << "The SeekToEventClient service can be used only with\n"
33  << "the RootInput source.\n";
34 }
cet::exempt_ptr< art::RootInput > input_
cet::coded_exception< errors::ErrorCodes, ExceptionDetail::translate > Exception
Definition: Exception.h:66
std::vector< art::EventID > nextEventsToProcess_
void arttest::SeekToEventClient::postProcessEvent ( art::Event const &  ,
art::ScheduleContext   
)
private

Definition at line 47 of file SeekToEventClient_service.cc.

49 {
50  if (nextEventsToProcess_.empty())
51  return;
52  input_->seekToEvent(nextEventsToProcess_[0]);
54 }
cet::exempt_ptr< art::RootInput > input_
std::vector< art::EventID > nextEventsToProcess_
void arttest::SeekToEventClient::preProcessEvent ( art::Event const &  e,
art::ScheduleContext   
)
private

Definition at line 37 of file SeekToEventClient_service.cc.

39 {
40  // Check to make sure SubRuns and Runs are appropriately filled.
41  // Exception will be thrown if not. Discard return value.
42  e.getSubRun();
43  e.getRun();
44 }
const double e

Member Data Documentation

cet::exempt_ptr<art::RootInput> arttest::SeekToEventClient::input_ {nullptr}
private

Definition at line 52 of file SeekToEventClient.h.

std::vector<art::EventID> arttest::SeekToEventClient::nextEventsToProcess_
private

Definition at line 51 of file SeekToEventClient.h.


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