CMS 3D CMS Logo

Public Member Functions | Private Attributes

CSCDigiToRawModule Class Reference

#include <CSCDigiToRawModule.h>

Inheritance diagram for CSCDigiToRawModule:
edm::EDProducer edm::ProducerBase edm::ProductRegistryHelper

List of all members.

Public Member Functions

 CSCDigiToRawModule (const edm::ParameterSet &pset)
 Constructor.
virtual void produce (edm::Event &, const edm::EventSetup &)
virtual ~CSCDigiToRawModule ()
 Destructor.

Private Attributes

CSCDigiToRawpacker
edm::InputTag theALCTDigiTag
edm::InputTag theCLCTDigiTag
edm::InputTag theComparatorDigiTag
edm::InputTag theCorrelatedLCTDigiTag
edm::InputTag thePreTriggerTag
edm::InputTag theStripDigiTag
edm::InputTag theWireDigiTag

Detailed Description

Date:
2010/07/19 19:54:13
Revision:
1.9
Author:
A. Tumanov - Rice

Definition at line 16 of file CSCDigiToRawModule.h.


Constructor & Destructor Documentation

CSCDigiToRawModule::CSCDigiToRawModule ( const edm::ParameterSet pset)

Constructor.

Definition at line 29 of file CSCDigiToRawModule.cc.

                                                                  : 
  packer(new CSCDigiToRaw(pset)),
  theStripDigiTag(pset.getParameter<edm::InputTag>("stripDigiTag")),
  theWireDigiTag(pset.getParameter<edm::InputTag>("wireDigiTag")),
  theComparatorDigiTag(pset.getParameter<edm::InputTag>("comparatorDigiTag")),
  theALCTDigiTag(pset.getParameter<edm::InputTag>("alctDigiTag")),
  theCLCTDigiTag(pset.getParameter<edm::InputTag>("clctDigiTag")),
  thePreTriggerTag(pset.getParameter<edm::InputTag>("preTriggerTag")),
  theCorrelatedLCTDigiTag(pset.getParameter<edm::InputTag>("correlatedLCTDigiTag"))
{
  //theStrip = pset.getUntrackedParameter<string>("DigiCreator", "cscunpacker");
  produces<FEDRawDataCollection>("CSCRawData"); 
}
CSCDigiToRawModule::~CSCDigiToRawModule ( ) [virtual]

Destructor.

Definition at line 44 of file CSCDigiToRawModule.cc.

References packer.

                                       {
  delete packer;
}

Member Function Documentation

void CSCDigiToRawModule::produce ( edm::Event e,
const edm::EventSetup c 
) [virtual]

reverse mapping for packer

Implements edm::EDProducer.

Definition at line 49 of file CSCDigiToRawModule.cc.

References CSCDigiToRaw::createFedBuffers(), edm::EventSetup::get(), edm::Event::getByLabel(), packer, edm::ESHandle< T >::product(), edm::Event::put(), theALCTDigiTag, theCLCTDigiTag, theComparatorDigiTag, theCorrelatedLCTDigiTag, thePreTriggerTag, theStripDigiTag, and theWireDigiTag.

                                                              {
  edm::ESHandle<CSCChamberMap> hcham;
  c.get<CSCChamberMapRcd>().get(hcham); 
  const CSCChamberMap* theMapping = hcham.product();


  auto_ptr<FEDRawDataCollection> fed_buffers(new FEDRawDataCollection);
  // Take digis from the event
  Handle<CSCStripDigiCollection> stripDigis;
  e.getByLabel(theStripDigiTag, stripDigis);
  Handle<CSCWireDigiCollection> wireDigis;
  e.getByLabel(theWireDigiTag, wireDigis);
  Handle<CSCComparatorDigiCollection> comparatorDigis;
  e.getByLabel(theComparatorDigiTag, comparatorDigis);
  Handle<CSCALCTDigiCollection> alctDigis;
  e.getByLabel(theALCTDigiTag, alctDigis);
  Handle<CSCCLCTDigiCollection> clctDigis;
  e.getByLabel(theCLCTDigiTag, clctDigis);
  Handle<CSCCLCTPreTriggerCollection> preTriggers;
  e.getByLabel(thePreTriggerTag, preTriggers);
  Handle<CSCCorrelatedLCTDigiCollection> correlatedLCTDigis;
  e.getByLabel(theCorrelatedLCTDigiTag, correlatedLCTDigis);



  // Create the packed data
  packer->createFedBuffers(*stripDigis, *wireDigis, *comparatorDigis, 
                           *alctDigis, *clctDigis, *preTriggers, *correlatedLCTDigis,
                           *(fed_buffers.get()), theMapping, e);
  
  // put the raw data to the event
  e.put(fed_buffers, "CSCRawData");
}

Member Data Documentation

Definition at line 28 of file CSCDigiToRawModule.h.

Referenced by produce(), and ~CSCDigiToRawModule().

Definition at line 32 of file CSCDigiToRawModule.h.

Referenced by produce().

Definition at line 33 of file CSCDigiToRawModule.h.

Referenced by produce().

Definition at line 31 of file CSCDigiToRawModule.h.

Referenced by produce().

Definition at line 35 of file CSCDigiToRawModule.h.

Referenced by produce().

Definition at line 34 of file CSCDigiToRawModule.h.

Referenced by produce().

Definition at line 29 of file CSCDigiToRawModule.h.

Referenced by produce().

Definition at line 30 of file CSCDigiToRawModule.h.

Referenced by produce().