Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-03-17 10:44:09

0001 #ifndef ApvAnalysis_ApvFactoryService_H
0002 #define ApvAnalysis_ApvFactoryService_H
0003 
0004 #define DATABASE  //@@ necessary?
0005 
0006 #include "FWCore/Utilities/interface/Exception.h"
0007 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0008 #include "FWCore/MessageLogger/interface/MessageLogger.h"
0009 #include "FWCore/ServiceRegistry/interface/ActivityRegistry.h"
0010 
0011 #include "CondFormats/SiStripObjects/interface/SiStripPedestals.h"
0012 #include "CalibTracker/SiStripAPVAnalysis/interface/ApvAnalysisFactory.h"
0013 
0014 #include "FWCore/Framework/interface/Event.h"
0015 #include "FWCore/Framework/interface/EventSetup.h"
0016 #include "FWCore/Framework/interface/ESHandle.h"
0017 #include "FWCore/Framework/interface/Frameworkfwd.h"
0018 
0019 #include <iostream>
0020 #include <fstream>
0021 #include <sstream>
0022 #include <ostream>
0023 #include <vector>
0024 #include <string>
0025 #include <map>
0026 
0027 /** 
0028    \class ApvFactoryService
0029    \brief An interface class to set the parameter in ApvAnalysisFactory  
0030 */
0031 
0032 class ApvFactoryService {
0033 public:
0034   // -------------------- Constructors, destructors --------------------
0035 
0036   /** Constructor when using the "service" mode, which takes as an
0037       argument a ParameterSet (containing the database connection
0038       parameters). */
0039   ApvFactoryService(const edm::ParameterSet&, edm::ActivityRegistry&);
0040 
0041   /** Default destructor. */
0042   ~ApvFactoryService();
0043 
0044   int getEventInitNumber();
0045 
0046   ApvAnalysisFactory* const getApvFactory() const;
0047 
0048   // -------------------- Structs and enums --------------------
0049 
0050   void postProcessEvent(const edm::Event& ie, const edm::EventSetup& ies);
0051 
0052   /** Class that holds addresses that uniquely identify a hardware
0053       component within the control system. */
0054 
0055 private:
0056   // -------------------- Miscellaneous private methods --------------------
0057 
0058   /** Instance of struct that holds all DB connection parameters. */
0059   ApvAnalysisFactory* apvFactory_;
0060 
0061   bool gotPed;
0062 };
0063 
0064 #endif  // ApvFactoryService_H