CMS 3D CMS Logo

DTFakeT0ESProducer Class Reference

#include <CalibMuon/DTCalibration/plugins/DTFakeT0ESProducer.h>

Inheritance diagram for DTFakeT0ESProducer:

edm::ESProducer edm::EventSetupRecordIntervalFinder edm::ESProxyFactoryProducer edm::eventsetup::DataProxyProvider

List of all members.

Public Member Functions

 DTFakeT0ESProducer (const edm::ParameterSet &pset)
DTT0produce (const DTT0Rcd &iRecord)
virtual ~DTFakeT0ESProducer ()

Private Member Functions

void parseDDD (const DTT0Rcd &iRecord)
void setIntervalFor (const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &oValidity)

Private Attributes

double t0Mean
double t0Sigma
std::map< DTLayerId, std::pair
< unsigned int, unsigned int > > 
theLayerIdWiresMap


Detailed Description

Definition at line 34 of file DTFakeT0ESProducer.h.


Constructor & Destructor Documentation

DTFakeT0ESProducer::DTFakeT0ESProducer ( const edm::ParameterSet pset  ) 

Definition at line 30 of file DTFakeT0ESProducer.cc.

References edm::ParameterSet::getParameter(), produce(), edm::ESProducer::setWhatProduced(), t0Mean, and t0Sigma.

00031 {
00032   //framework
00033   setWhatProduced(this,&DTFakeT0ESProducer::produce);
00034   //  setWhatProduced(this,dependsOn(& DTGeometryESModule::parseDDD()));
00035   findingRecord<DTT0Rcd>();
00036   
00037   //read constant value for t0 from cfg
00038   t0Mean = pset.getParameter<double>("t0Mean");
00039   t0Sigma = pset.getParameter<double>("t0Sigma");
00040 }

DTFakeT0ESProducer::~DTFakeT0ESProducer (  )  [virtual]

Definition at line 43 of file DTFakeT0ESProducer.cc.

00043                                        {
00044 }


Member Function Documentation

void DTFakeT0ESProducer::parseDDD ( const DTT0Rcd iRecord  )  [private]

Definition at line 68 of file DTFakeT0ESProducer.cc.

References edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::getRecord(), indexGen::parser, and theLayerIdWiresMap.

Referenced by produce().

00068                                                        {
00069 
00070   edm::ESHandle<DDCompactView> cpv;
00071   edm::ESHandle<MuonDDDConstants> mdc;
00072 
00073   iRecord.getRecord<IdealGeometryRecord>().get(cpv);
00074   iRecord.getRecord<MuonNumberingRecord>().get(mdc);
00075 
00076   DTGeometryParserFromDDD parser(&(*cpv), *mdc, theLayerIdWiresMap);
00077 }

DTT0 * DTFakeT0ESProducer::produce ( const DTT0Rcd iRecord  ) 

Definition at line 48 of file DTFakeT0ESProducer.cc.

References DTTimeUnits::counts, first, parseDDD(), edm::second(), DTT0::set(), t0Mean, t0Sigma, and theLayerIdWiresMap.

Referenced by DTFakeT0ESProducer().

00048                                                        {
00049   
00050   parseDDD(iRecord);
00051   DTT0* t0Map = new DTT0();
00052   
00053   //Loop on layerId-nwires map
00054  for(map<DTLayerId, pair <unsigned int,unsigned int> >::const_iterator lIdWire = theLayerIdWiresMap.begin();
00055      lIdWire != theLayerIdWiresMap.end();
00056      lIdWire++){
00057    int firstWire = ((*lIdWire).second).first;
00058    int nWires = ((*lIdWire).second).second;
00059    //Loop on wires of each layer
00060    for(int wire=0; wire < nWires; wire++){
00061      t0Map->set(DTWireId((*lIdWire).first, wire + firstWire), t0Mean, t0Sigma, DTTimeUnits::counts);
00062    }
00063  }
00064 
00065   return t0Map;
00066 }

void DTFakeT0ESProducer::setIntervalFor ( const edm::eventsetup::EventSetupRecordKey ,
const edm::IOVSyncValue ,
edm::ValidityInterval oValidity 
) [private, virtual]

Implements edm::EventSetupRecordIntervalFinder.

Definition at line 79 of file DTFakeT0ESProducer.cc.

References edm::IOVSyncValue::beginOfTime(), and edm::IOVSyncValue::endOfTime().


Member Data Documentation

double DTFakeT0ESProducer::t0Mean [private]

Definition at line 54 of file DTFakeT0ESProducer.h.

Referenced by DTFakeT0ESProducer(), and produce().

double DTFakeT0ESProducer::t0Sigma [private]

Definition at line 55 of file DTFakeT0ESProducer.h.

Referenced by DTFakeT0ESProducer(), and produce().

std::map<DTLayerId,std::pair<unsigned int,unsigned int> > DTFakeT0ESProducer::theLayerIdWiresMap [private]

Definition at line 51 of file DTFakeT0ESProducer.h.

Referenced by parseDDD(), and produce().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:18:52 2009 for CMSSW by  doxygen 1.5.4