00001 // Last commit: $Id: SiStripDigiToRaw.h,v 1.17 2008/04/02 08:47:42 bainbrid Exp $ 00002 00003 #ifndef EventFilter_SiStripRawToDigi_SiStripDigiToRaw_H 00004 #define EventFilter_SiStripRawToDigi_SiStripDigiToRaw_H 00005 00006 #include "DataFormats/Common/interface/Handle.h" 00007 #include "DataFormats/Common/interface/DetSetVector.h" 00008 #include "FWCore/Framework/interface/ESHandle.h" 00009 #include "FWCore/Framework/interface/Event.h" 00010 #include "boost/cstdint.hpp" 00011 #include <string> 00012 00013 class SiStripFedCabling; 00014 class FEDRawDataCollection; 00015 class SiStripDigi; 00016 00024 class SiStripDigiToRaw { 00025 00026 public: // ----- public interface ----- 00027 00028 SiStripDigiToRaw( std::string readout_mode, 00029 int16_t appended_bytes, 00030 bool use_fed_key ); 00031 ~SiStripDigiToRaw(); 00032 00033 void createFedBuffers( edm::Event&, 00034 edm::ESHandle<SiStripFedCabling>& cabling, 00035 edm::Handle< edm::DetSetVector<SiStripDigi> >& digis, 00036 std::auto_ptr<FEDRawDataCollection>& buffers ); 00037 00038 inline void fedReadoutMode( std::string mode ) { readoutMode_ = mode; } 00039 inline void nAppendedBytes( uint16_t nbytes ) { nAppendedBytes_ = nbytes; } 00040 00041 private: // ----- private data members ----- 00042 00043 std::string readoutMode_; 00044 uint16_t nAppendedBytes_; 00045 bool useFedKey_; 00046 00047 }; 00048 00049 #endif // EventFilter_SiStripRawToDigi_SiStripDigiToRaw_H 00050