artdaq_core  v3_05_07
SimpleMemoryReader.hh
1 #ifndef artdaq_core_Core_SimpleMemoryReader_hh
2 #define artdaq_core_Core_SimpleMemoryReader_hh 1
3 
4 #include <memory>
5 #include "artdaq-core/Core/SharedMemoryEventReceiver.hh"
6 
7 namespace artdaq {
18 int SimpleMemoryReaderApp(int argc, char** argv);
19 
25 {
26 public:
33  explicit SimpleMemoryReader(uint32_t shm_key, uint32_t broadcast_key, std::size_t expectedEventCount = 0);
34 
40  void run();
41 
42 private:
46  std::shared_ptr<SharedMemoryEventReceiver> incoming_events_;
50  std::size_t expectedEventCount_;
51 };
52 } // namespace artdaq
53 
54 #endif /* artdaq_core_Core_SimpleMemoryReader_hh */
void run()
Run until a null pointer is popped off of the RawEventQueue. Throws an excpetion if expectedEventCoun...
SimpleMemoryReader(uint32_t shm_key, uint32_t broadcast_key, std::size_t expectedEventCount=0)
Constructs a SimpleMemoryReader.
SimpleMemoryReader will continue to read RawEvent objects off the queue until it encounters a null po...
int SimpleMemoryReaderApp(int argc, char **argv)
An application which pops items off a RawEventQueue using the SimpleMemoryReader. ...