g4tools  5.4.0
Public Member Functions | Protected Attributes | List of all members
tools::histo::data_point Class Reference

Public Member Functions

 data_point (unsigned int a_dim)
 
virtual ~data_point ()
 
 data_point (const data_point &a_from)
 
data_pointoperator= (const data_point &a_from)
 
size_t dimension () const
 
measurementcoordinate (unsigned int a_coord)
 
const measurementcoordinate (unsigned int a_coord) const
 

Protected Attributes

std::vector< measurementm_measurements
 

Detailed Description

Definition at line 75 of file dps.

Constructor & Destructor Documentation

◆ data_point() [1/2]

tools::histo::data_point::data_point ( unsigned int  a_dim)
inline

Definition at line 81 of file dps.

81  :m_measurements(a_dim){
82 #ifdef TOOLS_MEM
83  mem::increment(s_class().c_str());
84 #endif
85  }

◆ ~data_point()

virtual tools::histo::data_point::~data_point ( )
inlinevirtual

Definition at line 86 of file dps.

86  {
87 #ifdef TOOLS_MEM
88  mem::decrement(s_class().c_str());
89 #endif
90  }

◆ data_point() [2/2]

tools::histo::data_point::data_point ( const data_point a_from)
inline

Definition at line 92 of file dps.

93  :m_measurements(a_from.m_measurements)
94  {
95 #ifdef TOOLS_MEM
96  mem::increment(s_class().c_str());
97 #endif
98  }

Member Function Documentation

◆ coordinate() [1/2]

measurement& tools::histo::data_point::coordinate ( unsigned int  a_coord)
inline

Definition at line 106 of file dps.

106  {
107  //WARNING : no check done on a_coord vs m_dim.
108  return m_measurements[a_coord];
109  }

◆ coordinate() [2/2]

const measurement& tools::histo::data_point::coordinate ( unsigned int  a_coord) const
inline

Definition at line 110 of file dps.

110  {
111  //WARNING : no check done on a_coord vs m_dim.
112  return m_measurements[a_coord];
113  }

◆ dimension()

size_t tools::histo::data_point::dimension ( ) const
inline

Definition at line 105 of file dps.

105 {return m_measurements.size();}

◆ operator=()

data_point& tools::histo::data_point::operator= ( const data_point a_from)
inline

Definition at line 99 of file dps.

99  {
100  if(&a_from==this) return *this;
101  m_measurements = a_from.m_measurements;
102  return *this;
103  }

Member Data Documentation

◆ m_measurements

std::vector<measurement> tools::histo::data_point::m_measurements
protected

Definition at line 115 of file dps.


The documentation for this class was generated from the following file:
tools::histo::data_point::m_measurements
std::vector< measurement > m_measurements
Definition: dps:115