The Gaudi Framework
master (181af51f)
Loading...
Searching...
No Matches
MyTrack.cpp
Go to the documentation of this file.
1
/***********************************************************************************\
2
* (c) Copyright 1998-2024 CERN for the benefit of the LHCb and ATLAS collaborations *
3
* *
4
* This software is distributed under the terms of the Apache version 2 licence, *
5
* copied verbatim in the file "LICENSE". *
6
* *
7
* In applying this licence, CERN does not waive the privileges and immunities *
8
* granted to it by virtue of its status as an Intergovernmental Organization *
9
* or submit itself to any jurisdiction. *
10
\***********************************************************************************/
11
#include <
GaudiTestSuite/MyTrack.h
>
12
13
using namespace
Gaudi::TestSuite
;
14
15
namespace
{
16
struct
InstanceCount {
17
long
count;
18
InstanceCount() : count( 0 ) {}
19
~InstanceCount() {
20
if
( count ) std::cout <<
"Number of MyTrack instances:"
<< count << std::endl;
21
}
22
};
23
}
// namespace
24
static
InstanceCount s_instances;
25
27
MyTrack::MyTrack
() :
m_px
( 0.0 ),
m_py
( 0.0 ),
m_pz
( 0.0 ) {
28
// m_event(this);
29
// m_originVertex(this);
30
// m_decayVertices(this);
31
s_instances.count++;
32
}
33
35
MyTrack::MyTrack
(
float
x,
float
y,
float
z ) :
m_px
( x ),
m_py
( y ),
m_pz
( z ) {
36
// m_event(this);
37
// m_originVertex(this);
38
// m_decayVertices(this);
39
s_instances.count++;
40
}
41
42
MyTrack::MyTrack
(
const
MyTrack
& t ) :
KeyedObject
<int>( t.
key
() ),
m_px
( t.
m_px
),
m_py
( t.
m_py
),
m_pz
( t.
m_pz
) {
43
s_instances.count++;
44
}
45
47
MyTrack::~MyTrack
() { s_instances.count--; }
MyTrack.h
Gaudi::TestSuite::MyTrack::m_px
float m_px
The track momentum.
Definition
MyTrack.h:66
Gaudi::TestSuite::MyTrack::m_pz
float m_pz
Definition
MyTrack.h:66
Gaudi::TestSuite::MyTrack::MyTrack
MyTrack()
Standard constructor.
Definition
MyTrack.cpp:27
Gaudi::TestSuite::MyTrack::m_py
float m_py
Definition
MyTrack.h:66
Gaudi::TestSuite::MyTrack::~MyTrack
~MyTrack() override
Standard Destructor.
Definition
MyTrack.cpp:47
KeyedObject< int >::KeyedObject
KeyedObject()=default
KeyedObject< int >::key
const key_type & key() const
Definition
KeyedObject.h:76
Gaudi::TestSuite
Definition
ConditionAccessorHolder.h:21
GaudiTestSuite
src
Lib
MyTrack.cpp
Generated on Wed Oct 8 2025 09:53:38 for The Gaudi Framework by
1.13.1