CMS 3D CMS Logo

IntegerCaloSamples.cc
Go to the documentation of this file.
2 
3 IntegerCaloSamples::IntegerCaloSamples() : id_(), size_(0), presamples_(0) {
4  for (int i = 0; i < MAXSAMPLES; i++)
5  data_[i] = 0;
6 }
7 
8 IntegerCaloSamples::IntegerCaloSamples(const DetId &id, int size) : id_(id), size_(size), presamples_(0) {
9  for (int i = 0; i < MAXSAMPLES; i++)
10  data_[i] = 0;
11 }
12 
14 
15 std::ostream &operator<<(std::ostream &s, const IntegerCaloSamples &samples) {
16  s << "DetId=" << samples.id().rawId();
17  s << ", " << samples.size() << "samples" << std::endl;
18  for (int i = 0; i < samples.size(); i++)
19  s << i << ":" << samples[i] << std::endl;
20  return s;
21 }
size
Write out results.
uint32_t data_[MAXSAMPLES]
void setPresamples(int pre)
set presample information
std::ostream & operator<<(std::ostream &s, const IntegerCaloSamples &samples)
Definition: DetId.h:17
static const int MAXSAMPLES