ATLAS Offline Software
SCT_ForwardPolarPosition.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // SCT_ForwardPolarPosition.cxx
7 // Implementation file for class SCT_ForwardPolarPosition
9 // (c) ATLAS Detector software
11 // Version 1.0a 1/6/2001 Class creator tool
13 
15 #include <sstream>
16 
17 namespace InDetDD {
18 
19 // Implicit constructor:
21  m_r(0),
22  m_theta(0)
23 {}
24 
25 // Copy constructor:
27 
28 = default;
29 
30 // Constructor with parameters:
32  m_r(r),
33  m_theta(theta)
34 {
35  //check if parameters are consistent
36  if (m_r<0) m_r=0;
37 }
38 
39 // Assignment operator:
41 {
42  if (this!=&polar) {
43  m_r=polar.m_r;
44  m_theta=polar.m_theta;
45  } else {}
46  return *this;
47 }
48 
49 //Comparison operator
51 {
52  return (m_r==polar.m_r && m_theta==polar.m_theta);
53 }
54 
55 //Print method:
57 {
58  std::string result{"r = "};
59  result += std::to_string(m_r) + " theta = " + std::to_string(m_theta);
60  return result;
61 }
62 
63 } // namespace InDetDD
beamspotman.r
def r
Definition: beamspotman.py:676
InDetDD::SCT_ForwardPolarPosition::m_r
double m_r
Definition: SCT_ForwardPolarPosition.h:66
get_generator_info.result
result
Definition: get_generator_info.py:21
theta
Scalar theta() const
theta method
Definition: AmgMatrixBasePlugin.h:71
InDetDD::SCT_ForwardPolarPosition
Definition: SCT_ForwardPolarPosition.h:25
InDetDD::SCT_ForwardPolarPosition::SCT_ForwardPolarPosition
SCT_ForwardPolarPosition()
Definition: SCT_ForwardPolarPosition.cxx:20
InDetDD::SCT_ForwardPolarPosition::operator==
virtual bool operator==(const SCT_ForwardPolarPosition &polar) const
Definition: SCT_ForwardPolarPosition.cxx:50
InDetDD::SCT_ForwardPolarPosition::operator=
SCT_ForwardPolarPosition & operator=(const SCT_ForwardPolarPosition &polar)
Definition: SCT_ForwardPolarPosition.cxx:40
ActsTrk::to_string
std::string to_string(const DetectorType &type)
Definition: GeometryDefs.h:34
InDetDD::SCT_ForwardPolarPosition::print
virtual std::string print() const
Definition: SCT_ForwardPolarPosition.cxx:56
InDetDD
Message Stream Member.
Definition: FakeTrackBuilder.h:8
SCT_ForwardPolarPosition.h
InDetDD::SCT_ForwardPolarPosition::m_theta
double m_theta
Definition: SCT_ForwardPolarPosition.h:67