CMS 3D CMS Logo

StreamerFileReader.h
Go to the documentation of this file.
1 #ifndef IOPool_Streamer_StreamerFileReader_h
2 #define IOPool_Streamer_StreamerFileReader_h
3 
6 
7 #include <memory>
8 #include <string>
9 #include <vector>
10 
11 class EventMsgView;
12 class InitMsgView;
13 
14 namespace edm {
16  class EventPrincipal;
17  class EventSkipperByID;
18  class FileCatalogItem;
19  struct InputSourceDescription;
20  class ParameterSet;
21  class StreamerInputFile;
23  public:
25  ~StreamerFileReader() override;
26 
27  static void fillDescriptions(ConfigurationDescriptions& descriptions);
28 
29  private:
30  InitMsgView const* getHeader();
31  EventMsgView const* getNextEvent();
32  bool newHeader();
33 
34  Next checkNext() override;
35  void skip(int toSkip) override;
36  void genuineReadFile() override;
37  void genuineCloseFile() override;
38  void reset_() override;
39 
40  std::shared_ptr<EventSkipperByID const> eventSkipperByID() const { return get_underlying_safe(eventSkipperByID_); }
41  std::shared_ptr<EventSkipperByID>& eventSkipperByID() { return get_underlying_safe(eventSkipperByID_); }
42 
43  std::vector<FileCatalogItem> streamerNames_; // names of Streamer files
48  bool isFirstFile_ = true;
49  };
50 } // namespace edm
51 
52 #endif
std::shared_ptr< EventSkipperByID > & eventSkipperByID()
void genuineCloseFile() override
constexpr std::shared_ptr< T > & get_underlying_safe(propagate_const< std::shared_ptr< T >> &iP)
StreamerFileReader(ParameterSet const &pset, InputSourceDescription const &desc)
std::vector< FileCatalogItem > streamerNames_
edm::propagate_const< std::unique_ptr< StreamerInputFile > > streamReader_
void skip(int toSkip) override
InitMsgView const * getHeader()
edm::propagate_const< std::shared_ptr< EventSkipperByID > > eventSkipperByID_
void genuineReadFile() override
EventMsgView const * getNextEvent()
HLT enums.
static void fillDescriptions(ConfigurationDescriptions &descriptions)
std::shared_ptr< EventSkipperByID const > eventSkipperByID() const