CMS 3D CMS Logo

List of all members | Public Member Functions | Private Types | Private Attributes
MaterialAccountingTrack Class Reference

#include <MaterialAccountingTrack.h>

Public Member Functions

const std::vector< MaterialAccountingDetector > & detectors () const
 
std::vector< MaterialAccountingDetector > & detectors ()
 
void enterDetector (const GlobalPoint &position, double cosTheta)
 
void leaveDetector (double cosTheta)
 
 MaterialAccountingTrack (void)
 
void reset (void)
 
void step (const MaterialAccountingStep &step)
 
const std::vector< MaterialAccountingStep > & steps () const
 
std::vector< MaterialAccountingStep > & steps ()
 
const MaterialAccountingStepsummary () const
 

Private Types

enum  { kSteps = 600, kDetectors = 30 }
 

Private Attributes

MaterialAccountingDetector m_detector
 
std::vector< MaterialAccountingDetectorm_detectors
 
std::vector< MaterialAccountingStepm_steps
 
MaterialAccountingStep m_total
 

Detailed Description

Definition at line 10 of file MaterialAccountingTrack.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
kSteps 
kDetectors 

Definition at line 13 of file MaterialAccountingTrack.h.

Constructor & Destructor Documentation

◆ MaterialAccountingTrack()

MaterialAccountingTrack::MaterialAccountingTrack ( void  )
inline

Definition at line 16 of file MaterialAccountingTrack.h.

References kDetectors, kSteps, m_detectors, and m_steps.

16  : m_total(), m_detector(), m_steps(), m_detectors() {
17  m_steps.reserve(kSteps);
18  m_detectors.reserve(kDetectors);
19  }
std::vector< MaterialAccountingDetector > m_detectors
std::vector< MaterialAccountingStep > m_steps
MaterialAccountingStep m_total
MaterialAccountingDetector m_detector

Member Function Documentation

◆ detectors() [1/2]

const std::vector<MaterialAccountingDetector>& MaterialAccountingTrack::detectors ( ) const
inline

Definition at line 41 of file MaterialAccountingTrack.h.

References m_detectors.

41 { return m_detectors; }
std::vector< MaterialAccountingDetector > m_detectors

◆ detectors() [2/2]

std::vector<MaterialAccountingDetector>& MaterialAccountingTrack::detectors ( )
inline

Definition at line 43 of file MaterialAccountingTrack.h.

References m_detectors.

43 { return m_detectors; }
std::vector< MaterialAccountingDetector > m_detectors

◆ enterDetector()

void MaterialAccountingTrack::enterDetector ( const GlobalPoint position,
double  cosTheta 
)

◆ leaveDetector()

void MaterialAccountingTrack::leaveDetector ( double  cosTheta)

◆ reset()

void MaterialAccountingTrack::reset ( void  )
inline

◆ step()

void MaterialAccountingTrack::step ( const MaterialAccountingStep step)
inline

Definition at line 31 of file MaterialAccountingTrack.h.

References m_steps, and m_total.

31  {
32  m_total += step;
33  m_steps.push_back(step);
34  }
std::vector< MaterialAccountingStep > m_steps
MaterialAccountingStep m_total
void step(const MaterialAccountingStep &step)
step
Definition: StallMonitor.cc:98

◆ steps() [1/2]

const std::vector<MaterialAccountingStep>& MaterialAccountingTrack::steps ( ) const
inline

Definition at line 45 of file MaterialAccountingTrack.h.

References m_steps.

45 { return m_steps; }
std::vector< MaterialAccountingStep > m_steps

◆ steps() [2/2]

std::vector<MaterialAccountingStep>& MaterialAccountingTrack::steps ( )
inline

Definition at line 47 of file MaterialAccountingTrack.h.

References m_steps.

47 { return m_steps; }
std::vector< MaterialAccountingStep > m_steps

◆ summary()

const MaterialAccountingStep& MaterialAccountingTrack::summary ( ) const
inline

Definition at line 39 of file MaterialAccountingTrack.h.

References m_total.

39 { return m_total; }
MaterialAccountingStep m_total

Member Data Documentation

◆ m_detector

MaterialAccountingDetector MaterialAccountingTrack::m_detector
private

Definition at line 51 of file MaterialAccountingTrack.h.

Referenced by enterDetector(), leaveDetector(), and reset().

◆ m_detectors

std::vector<MaterialAccountingDetector> MaterialAccountingTrack::m_detectors
private

Definition at line 53 of file MaterialAccountingTrack.h.

Referenced by detectors(), leaveDetector(), MaterialAccountingTrack(), and reset().

◆ m_steps

std::vector<MaterialAccountingStep> MaterialAccountingTrack::m_steps
private

Definition at line 52 of file MaterialAccountingTrack.h.

Referenced by MaterialAccountingTrack(), reset(), step(), and steps().

◆ m_total

MaterialAccountingStep MaterialAccountingTrack::m_total
private

Definition at line 50 of file MaterialAccountingTrack.h.

Referenced by enterDetector(), leaveDetector(), reset(), step(), and summary().