Commit f9220238 authored by Atlas-Software Librarian's avatar Atlas-Software Librarian Committed by Graeme Stewart
Browse files

'CMakeLists.txt' (MuidEvent-00-14-01)

	* addressing coverity defects 12281-2
	* tag MuidEvent-00-14-01
parent 92c8c0e0
################################################################################
# Package: MuidEvent
################################################################################
# Declare the package name:
atlas_subdir( MuidEvent )
# Declare the package's dependencies:
atlas_depends_on_subdirs( PUBLIC
Control/CLIDSvc
Control/DataModel
Control/SGTools
Tracking/TrkEvent/TrkParameters
PRIVATE
Reconstruction/Particle
Tracking/TrkDetDescr/TrkSurfaces
Tracking/TrkEvent/TrkTrack
Tracking/TrkEvent/VxVertex )
# External dependencies:
find_package( CLHEP )
# Component(s) in the package:
atlas_add_library( MuidEvent
src/CaloLayer.cxx
src/CaloMeas.cxx
src/IndetMatchCandidate.cxx
src/MuidTrack.cxx
src/MuonMatch.cxx
PUBLIC_HEADERS MuidEvent
PRIVATE_INCLUDE_DIRS ${CLHEP_INCLUDE_DIRS}
PRIVATE_DEFINITIONS ${CLHEP_DEFINITIONS}
LINK_LIBRARIES DataModel SGTools TrkParameters
PRIVATE_LINK_LIBRARIES ${CLHEP_LIBRARIES} Particle TrkSurfaces TrkTrack VxVertex )
......@@ -17,6 +17,7 @@ namespace Rec
public:
CaloMeas (void);
CaloMeas (const CaloMeas& caloMeas);
CaloMeas& operator=(const CaloMeas& caloMeas);
double Tile_EnergyMeasured(void) const;
void Tile_EnergyMeasured(double value);
......
......@@ -87,6 +87,9 @@ public:
// "copy" constructor with steal of combined track
MuonMatch (MuonMatch&);
// "assign" operator with steal of combined track
MuonMatch& operator=(MuonMatch&);
// destructor
virtual ~MuonMatch();
......
......@@ -38,6 +38,24 @@ namespace Rec
m_LArEM_SamplingFraction (caloMeas.m_LArEM_SamplingFraction)
{}
CaloMeas&
CaloMeas::operator=(const CaloMeas& caloMeas)
{
if (this!=&caloMeas) {
m_Tile_EnergyMeasured =caloMeas.m_Tile_EnergyMeasured;
m_Tile_Isolation =caloMeas.m_Tile_Isolation;
m_Tile_SamplingFraction =caloMeas.m_Tile_SamplingFraction;
m_LArHEC_EnergyMeasured =caloMeas.m_LArHEC_EnergyMeasured;
m_LArHEC_Isolation =caloMeas.m_LArHEC_Isolation;
m_LArHEC_SamplingFraction =caloMeas.m_LArHEC_SamplingFraction;
m_LArEM_EnergyMeasured =caloMeas.m_LArEM_EnergyMeasured;
m_LArEM_FirstCompartmentEnergy =caloMeas.m_LArEM_FirstCompartmentEnergy;
m_LArEM_Isolation =caloMeas.m_LArEM_Isolation;
m_LArEM_SamplingFraction =caloMeas.m_LArEM_SamplingFraction;
}
return *this;
}
void
CaloMeas:: Tile_EnergyMeasured(double value)
{ m_Tile_EnergyMeasured = value; }
......
......@@ -120,6 +120,42 @@ MuonMatch::MuonMatch (MuonMatch& match)
if (match.m_extrapolatedRefit) match.m_extrapolatedRefit = 0;
}
// assign and steal operator
MuonMatch& MuonMatch::operator= (MuonMatch& match)
{
if (this!=&match){
m_extrapolatedTrack =match.m_extrapolatedTrack;
m_indetParticle =match.m_indetParticle;
m_indetTrack =match.m_indetTrack;
m_spectrometerParticle =match.m_spectrometerParticle;
m_spectrometerTrack =match.m_spectrometerTrack;
m_vertex =match.m_vertex;
m_bestMatch =match.m_bestMatch;
m_fieldIntegral =match.m_fieldIntegral;
m_innerMatchChi2 =match.m_innerMatchChi2;
m_innerMatchDoF =match.m_innerMatchDoF;
m_innerMatchProb =match.m_innerMatchProb;
m_matchType =match.m_matchType;
m_momentumBalanceSignificance =match.m_momentumBalanceSignificance;
m_outerMatchChi2 =match.m_outerMatchChi2;
m_outerMatchDoF =match.m_outerMatchDoF;
m_outerMatchProb =match.m_outerMatchProb;
m_scatteringAngleSignificance =match.m_scatteringAngleSignificance;
m_looseMatch =match.m_looseMatch;
m_simpleMatch =match.m_simpleMatch;
if(m_combinedTrack) delete m_combinedTrack;
m_combinedTrack =match.m_combinedTrack;
if (match.m_combinedTrack) match.m_combinedTrack = 0;
if(m_extrapolatedRefit) delete m_extrapolatedRefit;
m_extrapolatedRefit =match.m_extrapolatedRefit;
if (match.m_extrapolatedRefit) match.m_extrapolatedRefit = 0;
}
return *this;
}
MuonMatch::~MuonMatch (void)
{
delete m_combinedTrack;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment