CMS 3D CMS Logo

StreamerFileWriter.cc
Go to the documentation of this file.
3 
4 namespace edm {
6  : stream_writer_(new StreamerOutputFile(ps.getUntrackedParameter<std::string>("fileName"))) {}
7 
9  : stream_writer_(new StreamerOutputFile(fileName)) {}
10 
12 
14  //Let us turn it into a View
15  InitMsgView view(init_message.startAddress());
16  doOutputHeader(view);
17  }
18 
19  void StreamerFileWriter::doOutputHeader(InitMsgView const& init_message) {
20  //Write the Init Message to Streamer file
21  stream_writer_->write(init_message);
22  }
23 
25  //Write the Event Message to Streamer file
26  stream_writer_->write(msg);
27  }
28 
30  EventMsgView eview(msg.startAddress());
31  doOutputEvent(eview);
32  }
33 
35  desc.setComment("Writes events into a streamer output file.");
36  desc.addUntracked<std::string>("fileName", "teststreamfile.dat")->setComment("Name of output file.");
37  }
38 } //namespace edm
uint8 * startAddress() const
StreamerFileWriter(edm::ParameterSet const &ps)
void doOutputHeader(InitMsgBuilder const &init_message)
edm::propagate_const< std::unique_ptr< StreamerOutputFile > > stream_writer_
tuple msg
Definition: mps_check.py:285
HLT enums.
static void fillDescription(ParameterSetDescription &desc)
void doOutputEvent(EventMsgBuilder const &msg)