CMS 3D CMS Logo

Public Member Functions | Private Attributes

METFileSaver Class Reference

#include <METFileSaver.h>

Inheritance diagram for METFileSaver:
edm::EDAnalyzer

List of all members.

Public Member Functions

virtual void analyze (const edm::Event &, const edm::EventSetup &)
virtual void beginJob ()
virtual void endJob ()
 METFileSaver (const edm::ParameterSet &)

Private Attributes

DQMStoredbe_
std::map< std::string,
MonitorElement * > 
me
std::string outputFile_

Detailed Description

Definition at line 25 of file METFileSaver.h.


Constructor & Destructor Documentation

METFileSaver::METFileSaver ( const edm::ParameterSet iConfig) [explicit]

Definition at line 29 of file METFileSaver.cc.

References edm::ParameterSet::getUntrackedParameter(), and outputFile_.

{
  outputFile_              = iConfig.getUntrackedParameter<std::string>("OutputFile");
  if (outputFile_.size() > 0)
    edm::LogInfo("OutputInfo") << " MET Task histograms will be saved to '" << outputFile_.c_str() << "'";
  else edm::LogInfo("OutputInfo") << " MET Task histograms will NOT be saved";
  
}

Member Function Documentation

void METFileSaver::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
) [virtual]

Implements edm::EDAnalyzer.

Definition at line 45 of file METFileSaver.cc.

{
}
void METFileSaver::beginJob ( void  ) [virtual]

Reimplemented from edm::EDAnalyzer.

Definition at line 38 of file METFileSaver.cc.

References dbe_, and cmsCodeRules::cppFunctionSkipper::operator.

{
  // get ahold of back-end interface
  dbe_ = edm::Service<DQMStore>().operator->();

}
void METFileSaver::endJob ( void  ) [virtual]

Reimplemented from edm::EDAnalyzer.

Definition at line 49 of file METFileSaver.cc.

References dbe_, outputFile_, and DQMStore::save().

{
  // Store the DAQ Histograms
  if (outputFile_.size() > 0 && dbe_)
  dbe_->save(outputFile_);
}

Member Data Documentation

Definition at line 37 of file METFileSaver.h.

Referenced by beginJob(), and endJob().

std::map<std::string, MonitorElement*> METFileSaver::me [private]

Definition at line 38 of file METFileSaver.h.

std::string METFileSaver::outputFile_ [private]

Definition at line 41 of file METFileSaver.h.

Referenced by endJob(), and METFileSaver().