#include <EventFilter/StorageManager/interface/FRDOutputService.h>
Public Member Functions | |
FRDOutputService (boost::shared_ptr< FileRecord >) | |
void | report (std::ostream &os, int indentation) const |
void | writeEvent (const uint8 *const) |
~FRDOutputService () | |
Private Member Functions | |
void | closeFile () |
Private Attributes | |
boost::shared_ptr < FRDEventFileWriter > | writer_ |
Definition at line 11 of file FRDOutputService.h.
FRDOutputService::FRDOutputService | ( | boost::shared_ptr< FileRecord > | file | ) |
Definition at line 16 of file FRDOutputService.cc.
References edm::OutputService::file_, aod_PYTHIA_cfg::fileName, edm::OutputService::getTimeStamp(), and writer_.
00017 { 00018 file_ = file; 00019 00020 string fileName = file_ -> filePath() + file_ -> fileName() + file_ -> fileCounterStr() + ".dat"; 00021 00022 writer_ = shared_ptr<FRDEventFileWriter> (new FRDEventFileWriter(fileName)); 00023 00024 file_ -> firstEntry(getTimeStamp()); 00025 file_ -> insertFileInDatabase(); 00026 }
FRDOutputService::~FRDOutputService | ( | ) |
Definition at line 32 of file FRDOutputService.cc.
References closeFile().
00033 { 00034 //std::cout << "FRDOutputService Destructor called." << std::endl; 00035 closeFile(); 00036 }
void FRDOutputService::closeFile | ( | ) | [private] |
Definition at line 62 of file FRDOutputService.cc.
References edm::OutputService::file_, and writer_.
Referenced by ~FRDOutputService().
00063 { 00064 writer_ -> stop(); 00065 file_ -> moveErrorFileToClosed(); 00066 file_ -> writeToSummaryCatalog(); 00067 file_ -> updateDatabase(); 00068 }
Implements edm::OutputService.
Implements edm::OutputService.
Definition at line 45 of file FRDOutputService.cc.
References edm::OutputService::file_, edm::OutputService::getTimeStamp(), edm::OutputService::lastEntry(), FRDEventMsgView::size(), and writer_.
00046 { 00047 FRDEventMsgView view((void *) bufPtr); 00048 writer_ -> doOutputEvent(view); 00049 file_ -> increaseFileSize(view.size()); 00050 file_ -> lastEntry(getTimeStamp()); 00051 file_ -> increaseEventCount(); 00052 }
boost::shared_ptr<FRDEventFileWriter> edm::FRDOutputService::writer_ [private] |
Definition at line 23 of file FRDOutputService.h.
Referenced by closeFile(), FRDOutputService(), and writeEvent().