CMS 3D CMS Logo

Public Member Functions | Private Attributes

SiStripDetVOffReader Class Reference

#include <SiStripDetVOffReader.h>

Inheritance diagram for SiStripDetVOffReader:
edm::EDAnalyzer

List of all members.

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &)
 SiStripDetVOffReader (const edm::ParameterSet &)
 ~SiStripDetVOffReader ()

Private Attributes

std::vector< uint32_t > detids
bool printdebug_

Detailed Description

Definition at line 26 of file SiStripDetVOffReader.h.


Constructor & Destructor Documentation

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

Definition at line 10 of file SiStripDetVOffReader.cc.

                                                                          :
  printdebug_(iConfig.getUntrackedParameter<bool>("printDebug",true)){}
SiStripDetVOffReader::~SiStripDetVOffReader ( )

Definition at line 14 of file SiStripDetVOffReader.cc.

{}

Member Function Documentation

void SiStripDetVOffReader::analyze ( const edm::Event e,
const edm::EventSetup iSetup 
) [virtual]

Implements edm::EDAnalyzer.

Definition at line 17 of file SiStripDetVOffReader.cc.

References cond::rpcobgas::detid, edm::EventSetup::get(), errorMatrix2Lands_multiChannel::id, and printdebug_.

                                                                                 {

  edm::ESHandle<SiStripDetVOff> SiStripDetVOff_;
  iSetup.get<SiStripDetVOffRcd>().get(SiStripDetVOff_);
  edm::LogInfo("SiStripDetVOffReader") << "[SiStripDetVOffReader::analyze] End Reading SiStripDetVOff" << std::endl;
  

  // put here a vector of DetIds to compare 
  // Here we just take the vector with all modules that have HV OFF
  
  // replace this code, with Your own detids
  std::vector <uint32_t> detid;
  SiStripDetVOff_->getDetIds(detid);
  //


  if (printdebug_){
    for (uint32_t  id=0;id<=detid.size();id++)
      {
        bool hvflag=SiStripDetVOff_->IsModuleHVOff(detid[id]);
        bool lvflag=SiStripDetVOff_->IsModuleLVOff(detid[id]);
        bool vflag =SiStripDetVOff_->IsModuleVOff(detid[id]);
        if(hvflag==true) {
          edm::LogInfo("SiStripDetVOffReader") << "detid: " << detid[id] << " HV\t OFF\n";
        }
        else {
          edm::LogInfo("SiStripDetVOffReader") << "detid: " << detid[id] << " HV\t ON\n";
        }
        if(lvflag==true) {
          edm::LogInfo("SiStripDetVOffReader") << "detid: " << detid[id] << " LV\t OFF\n";
        }
        else {
          edm::LogInfo("SiStripDetVOffReader") << "detid: " << detid[id] << " LV\t ON\n";
        }
        if(vflag==true) {
          edm::LogInfo("SiStripDetVOffReader") << "detid: " << detid[id] << " V\t OFF\n";
        }
        else {
          edm::LogInfo("SiStripDetVOffReader") << "detid: " << detid[id] << " V\t ON\n";
        }
      } 
  }

}

Member Data Documentation

std::vector<uint32_t> SiStripDetVOffReader::detids [private]

Definition at line 36 of file SiStripDetVOffReader.h.

Definition at line 35 of file SiStripDetVOffReader.h.

Referenced by analyze().