CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions
DQMFileSaver.cc File Reference
#include "DQMServices/Components/src/DQMFileSaver.h"
#include "DQMServices/Core/interface/DQMStore.h"
#include "DQMServices/Core/interface/MonitorElement.h"
#include "FWCore/Framework/interface/Event.h"
#include "FWCore/Framework/interface/Run.h"
#include "FWCore/Framework/interface/LuminosityBlock.h"
#include "FWCore/ParameterSet/interface/ParameterSet.h"
#include "FWCore/Version/interface/GetReleaseVersion.h"
#include "FWCore/ServiceRegistry/interface/Service.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "FWCore/MessageLogger/interface/JobReport.h"
#include <sys/stat.h>
#include <sys/types.h>
#include <unistd.h>
#include <iostream>
#include <vector>
#include <string>
#include <TString.h>
#include <TSystem.h>

Go to the source code of this file.

Functions

static void doSaveForOnline (std::list< std::string > &pastSavedFiles, size_t numKeepSavedFiles, DQMStore *store, const std::string &filename, const std::string &directory, const std::string &rxpat, const std::string &rewrite, DQMStore::SaveReferenceTag saveref, int saveRefQMin)
 
static void getAnInt (const edm::ParameterSet &ps, int &value, const std::string &name)
 

Function Documentation

static void doSaveForOnline ( std::list< std::string > &  pastSavedFiles,
size_t  numKeepSavedFiles,
DQMStore store,
const std::string &  filename,
const std::string &  directory,
const std::string &  rxpat,
const std::string &  rewrite,
DQMStore::SaveReferenceTag  saveref,
int  saveRefQMin 
)
static

Definition at line 116 of file DQMFileSaver.cc.

References DQMStore::save().

Referenced by DQMFileSaver::saveForOnline().

125 {
126  store->save(filename, directory , rxpat,
127  rewrite, saveref, saveRefQMin);
128  pastSavedFiles.push_back(filename);
129  if (pastSavedFiles.size() > numKeepSavedFiles)
130  {
131  remove(pastSavedFiles.front().c_str());
132  pastSavedFiles.pop_front();
133  }
134 }
void save(const std::string &filename, const std::string &path="", const std::string &pattern="", const std::string &rewrite="", SaveReferenceTag ref=SaveWithReference, int minStatus=dqm::qstatus::STATUS_OK, const std::string &fileupdate="RECREATE")
Definition: DQMStore.cc:2118
tuple filename
Definition: lut2db_cfg.py:20
static void getAnInt ( const edm::ParameterSet ps,
int &  value,
const std::string &  name 
)
static

Definition at line 23 of file DQMFileSaver.cc.

References edm::hlt::Exception, edm::ParameterSet::getUntrackedParameter(), mergeVDriftHistosByStation::name, and relativeConstraints::value.

Referenced by DQMFileSaver::DQMFileSaver().

24 {
26  if (value < 1 && value != -1)
27  throw cms::Exception("DQMFileSaver")
28  << "Invalid '" << name << "' parameter '" << value
29  << "'. Must be -1 or >= 1.";
30 }
T getUntrackedParameter(std::string const &, T const &) const