CMS 3D CMS Logo

HcalDbASCIIIO.h
Go to the documentation of this file.
1 //
2 // F.Ratnikov (UMd), Jul. 19, 2005
3 //
4 #ifndef HcalDbASCIIIO_h
5 #define HcalDbASCIIIO_h
6 
7 #include <iostream>
8 
13 
54 namespace HcalDbASCIIIO {
55  //alternate function for creating certain objects
56  template <class T>
57  std::unique_ptr<T> createObject (std::istream& fInput){
58  assert(0); //no general case, relies on specializations defined in cc file
59  return std::make_unique<T>();
60  }
61 
62  bool getObject (std::istream& fInput, HcalPedestals* fObject);
63  bool dumpObject (std::ostream& fOutput, const HcalPedestals& fObject);
64  bool getObject (std::istream& fInput, HcalPedestalWidths* fObject);
65  bool dumpObject (std::ostream& fOutput, const HcalPedestalWidths& fObject);
66  bool getObject (std::istream& fInput, HcalGains* fObject);
67  bool dumpObject (std::ostream& fOutput, const HcalGains& fObject);
68  bool getObject (std::istream& fInput, HcalGainWidths* fObject);
69  bool dumpObject (std::ostream& fOutput, const HcalGainWidths& fObject);
70  bool getObject (std::istream& fInput, HcalQIEData* fObject);
71  bool dumpObject (std::ostream& fOutput, const HcalQIEData& fObject);
72  bool getObject (std::istream& fInput, HcalCalibrationQIEData* fObject);
73  bool dumpObject (std::ostream& fOutput, const HcalCalibrationQIEData& fObject);
74  bool getObject (std::istream& fInput, HcalQIETypes* fObject);
75  bool dumpObject (std::ostream& fOutput, const HcalQIETypes& fObject);
76  template<> std::unique_ptr<HcalElectronicsMap> createObject<HcalElectronicsMap>(std::istream& fInput);
77  bool dumpObject (std::ostream& fOutput, const HcalElectronicsMap& fObject);
78  bool getObject (std::istream& fInput, HcalChannelQuality* fObject);
79  bool dumpObject (std::ostream& fOutput, const HcalChannelQuality& fObject);
80  bool getObject (std::istream& fInput, HcalRespCorrs* fObject);
81  bool dumpObject (std::ostream& fOutput, const HcalRespCorrs& fObject);
82  bool getObject (std::istream& fInput, HcalLUTCorrs* fObject);
83  bool dumpObject (std::ostream& fOutput, const HcalLUTCorrs& fObject);
84  bool getObject (std::istream& fInput, HcalPFCorrs* fObject);
85  bool dumpObject (std::ostream& fOutput, const HcalPFCorrs& fObject);
86  bool getObject (std::istream& fInput, HcalTimeCorrs* fObject);
87  bool dumpObject (std::ostream& fOutput, const HcalTimeCorrs& fObject);
88  bool getObject (std::istream& fInput, HcalZSThresholds* fObject);
89  bool dumpObject (std::ostream& fOutput, const HcalZSThresholds& fObject);
90  bool getObject (std::istream& fInput, HcalL1TriggerObjects* fObject);
91  bool dumpObject (std::ostream& fOutput, const HcalL1TriggerObjects& fObject);
92  template<> std::unique_ptr<HcalFrontEndMap> createObject<HcalFrontEndMap>(std::istream& fInput);
93  bool dumpObject (std::ostream& fOutput, const HcalFrontEndMap& fObject);
94 
95  bool getObject (std::istream& fInput, HcalValidationCorrs* fObject);
96  bool dumpObject (std::ostream& fOutput, const HcalValidationCorrs& fObject);
97  bool getObject (std::istream& fInput, HcalLutMetadata* fObject);
98  bool dumpObject (std::ostream& fOutput, const HcalLutMetadata& fObject);
99  bool getObject (std::istream& fInput, HcalDcsValues* fObject);
100  bool dumpObject (std::ostream& fOutput, const HcalDcsValues& fObject);
101  template <> std::unique_ptr<HcalDcsMap> createObject<HcalDcsMap>(std::istream& fInput);
102  bool dumpObject (std::ostream& fOutput, const HcalDcsMap& fObject);
103 
104  bool getObject (std::istream& fInput, HcalRecoParams* fObject);
105  bool dumpObject (std::ostream& fOutput, const HcalRecoParams& fObject);
106  bool getObject (std::istream& fInput, HcalLongRecoParams* fObject);
107  bool dumpObject (std::ostream& fOutput, const HcalLongRecoParams& fObject);
108 
109  bool getObject (std::istream& fInput, HcalZDCLowGainFractions* fObject);
110  bool dumpObject (std::ostream& fOutput, const HcalZDCLowGainFractions& fObject);
111 
112  bool getObject (std::istream& fInput, HcalTimingParams* fObject);
113  bool dumpObject (std::ostream& fOutput, const HcalTimingParams& fObject);
114 
115  bool getObject (std::istream& fInput, HcalMCParams* fObject);
116  bool dumpObject (std::ostream& fOutput, const HcalMCParams& fObject);
117 
118  // Getting/Dumping Hcal Flag information
119  bool getObject (std::istream& fInput, HcalFlagHFDigiTimeParams* fObject);
120  bool dumpObject (std::ostream& fOutput, const HcalFlagHFDigiTimeParams& fObject);
121 
122  bool getObject (std::istream& fInput, HcalSiPMParameters* fObject);
123  bool dumpObject (std::ostream& fOutput, const HcalSiPMParameters& fObject);
124  template<> std::unique_ptr<HcalSiPMCharacteristics> createObject<HcalSiPMCharacteristics>(std::istream& fInput);
125  bool dumpObject (std::ostream& fOutput, const HcalSiPMCharacteristics& fObject);
126 
127  bool getObject (std::istream& fInput, HcalTPParameters* fObject);
128  bool dumpObject (std::ostream& fOutput, const HcalTPParameters& fObject);
129  bool getObject (std::istream& fInput, HcalTPChannelParameters* fObject);
130  bool dumpObject (std::ostream& fOutput, const HcalTPChannelParameters& fObject);
131 
132  bool dumpObject (std::ostream& fOutput, const HcalCalibrationsSet& fObject);
133  bool dumpObject (std::ostream& fOutput, const HcalCalibrationWidthsSet& fObject);
134 
135  DetId getId (const std::vector <std::string> & items);
136  void dumpId (std::ostream& fOutput, DetId id);
137  void dumpIdShort (std::ostream& fOutput, DetId id);
138 }
139 #endif
void dumpIdShort(std::ostream &fOutput, DetId id)
std::unique_ptr< HcalFrontEndMap > createObject< HcalFrontEndMap >(std::istream &fInput)
void dumpId(std::ostream &fOutput, DetId id)
std::unique_ptr< HcalSiPMCharacteristics > createObject< HcalSiPMCharacteristics >(std::istream &fInput)
Definition: DetId.h:18
bool getObject(std::istream &fInput, HcalPedestals *fObject)
DetId getId(const std::vector< std::string > &items)
bool dumpObject(std::ostream &fOutput, const HcalPedestals &fObject)
std::unique_ptr< T > createObject(std::istream &fInput)
Definition: HcalDbASCIIIO.h:57
std::unique_ptr< HcalDcsMap > createObject< HcalDcsMap >(std::istream &fInput)
std::unique_ptr< HcalElectronicsMap > createObject< HcalElectronicsMap >(std::istream &fInput)