CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
SiStripPI::Monitor2D Class Reference

#include <SiStripPayloadInspectorHelper.h>

Public Member Functions

void Fill (int apv, int det, double vx, double vy)
 
void flush ()
 
TH2F & hist ()
 
 Monitor2D (OpMode mode, const char *name, const char *title, int nbinsx, double xmin, double xmax, int nbinsy, double ymin, double ymax)
 
 Monitor2D ()
 
 ~Monitor2D ()
 

Private Attributes

Entry entryx_
 
Entry entryy_
 
OpMode mode_
 
TH2F obj_
 
int prev_apv_ =0
 
int prev_det_ =0
 

Detailed Description

Definition at line 120 of file SiStripPayloadInspectorHelper.h.

Constructor & Destructor Documentation

SiStripPI::Monitor2D::Monitor2D ( OpMode  mode,
const char *  name,
const char *  title,
int  nbinsx,
double  xmin,
double  xmax,
int  nbinsy,
double  ymin,
double  ymax 
)
inline
SiStripPI::Monitor2D::Monitor2D ( )
inline
SiStripPI::Monitor2D::~Monitor2D ( )
inline

Definition at line 134 of file SiStripPayloadInspectorHelper.h.

134 {}

Member Function Documentation

void SiStripPI::Monitor2D::Fill ( int  apv,
int  det,
double  vx,
double  vy 
)
inline

Definition at line 136 of file SiStripPayloadInspectorHelper.h.

References SiStripPI::APV_BASED, SiStripPI::MODULE_BASED, and SiStripPI::STRIP_BASED.

136  {
137  switch(mode_) {
138  case (OpMode::APV_BASED):
139  if(!((apv == prev_apv_ && det == prev_det_) || prev_apv_ == 0)){
140  flush();
141  }
142  prev_apv_ = apv;
143  prev_det_ = det;
144  break;
145  case (OpMode::MODULE_BASED):
146  if(!(det == prev_det_ || prev_det_ == 0)){
147  flush();
148  }
149  prev_det_ = det;
150  break;
151  case (OpMode::STRIP_BASED):
152  flush();
153  break;
154  }
155  entryx_.add(vx);
156  entryy_.add(vy);
157  }
void SiStripPI::Monitor2D::flush ( )
inline
TH2F& SiStripPI::Monitor2D::hist ( )
inline

Definition at line 165 of file SiStripPayloadInspectorHelper.h.

165  {
166  flush();
167  return obj_;
168  }

Member Data Documentation

Entry SiStripPI::Monitor2D::entryx_
private

Definition at line 171 of file SiStripPayloadInspectorHelper.h.

Entry SiStripPI::Monitor2D::entryy_
private

Definition at line 171 of file SiStripPayloadInspectorHelper.h.

OpMode SiStripPI::Monitor2D::mode_
private

Definition at line 172 of file SiStripPayloadInspectorHelper.h.

TH2F SiStripPI::Monitor2D::obj_
private

Definition at line 173 of file SiStripPayloadInspectorHelper.h.

int SiStripPI::Monitor2D::prev_apv_ =0
private

Definition at line 170 of file SiStripPayloadInspectorHelper.h.

int SiStripPI::Monitor2D::prev_det_ =0
private

Definition at line 170 of file SiStripPayloadInspectorHelper.h.