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

'CMakeLists.txt' (VxSecVertex-00-04-07)

	* Correct assignment operator in VxJetFitterVertexInfo (Coverity problems 12184,12668)
	* Tagged as VxSecVertex-00-04-07

2015-06-24 Vadim Kostyukhin <Vadim.Kostyukhin@cern.ch>

	* Add minimal distance to material layer in VxSecVKalVertexInfo
	* Tagged as VxSecVertex-00-04-06
parent 885bfd1d
################################################################################
# Package: VxSecVertex
################################################################################
# Declare the package name:
atlas_subdir( VxSecVertex )
# Declare the package's dependencies:
atlas_depends_on_subdirs( PUBLIC
Control/CLIDSvc
Control/DataModel
Control/SGTools
Event/xAOD/xAODBase
Event/xAOD/xAODTracking
PRIVATE
Tracking/TrkEvent/TrkParticleBase
Tracking/TrkEvent/VxJetVertex
Tracking/TrkEvent/VxVertex )
# External dependencies:
find_package( ROOT COMPONENTS Core Tree MathCore Hist RIO pthread )
# Component(s) in the package:
atlas_add_library( VxSecVertex
src/*.cxx
PUBLIC_HEADERS VxSecVertex
PRIVATE_INCLUDE_DIRS ${ROOT_INCLUDE_DIRS}
LINK_LIBRARIES DataModel SGTools xAODBase xAODTracking
PRIVATE_LINK_LIBRARIES ${ROOT_LIBRARIES} TrkParticleBase VxJetVertex VxVertex )
atlas_add_dictionary( VxSecVertexDict
VxSecVertex/VxSecVertexDict.h
VxSecVertex/selection.xml
INCLUDE_DIRS ${ROOT_INCLUDE_DIRS}
LINK_LIBRARIES ${ROOT_LIBRARIES} DataModel SGTools xAODBase xAODTracking TrkParticleBase VxJetVertex VxVertex VxSecVertex )
......@@ -55,7 +55,7 @@ namespace Trk {
virtual VxJetFitterVertexInfo* clone() const;
/* assignment operator */
VxJetFitterVertexInfo operator= (const VxJetFitterVertexInfo &);
VxJetFitterVertexInfo & operator= (const VxJetFitterVertexInfo &);
/* destructor */
virtual ~VxJetFitterVertexInfo();
......
......@@ -77,6 +77,11 @@ namespace Trk {
/* get energy of all tracks in jet */
double energyTrkInJet() const;
/* get minimal distance to any material layer */
double dstToMatLay() const;
/* set minimal distance to any material layer */
void setDstToMatLay(double) const;
/* get n2trackvertices */
int n2trackvertices() const;
......@@ -98,6 +103,7 @@ namespace Trk {
double m_mass;
double m_energyFraction;
double m_energyTrkInJet;
mutable double m_dstToMatLayer;
int m_n2trackvertices;
std::vector<ElementLink<Trk::TrackParticleBaseCollection> > m_badTracksTP;
std::vector<ElementLink<xAOD::IParticleContainer> > m_badTracksIP;
......@@ -116,6 +122,14 @@ namespace Trk {
inline double VxSecVKalVertexInfo::energyTrkInJet() const {
return m_energyTrkInJet;
}
inline double VxSecVKalVertexInfo::dstToMatLay() const {
return m_dstToMatLayer;
}
inline void VxSecVKalVertexInfo::setDstToMatLay(double Value) const {
m_dstToMatLayer=Value;
}
inline int VxSecVKalVertexInfo::n2trackvertices() const {
return m_n2trackvertices;
......
......@@ -59,7 +59,7 @@ namespace Trk {
}
VxJetFitterVertexInfo VxJetFitterVertexInfo::operator= (const VxJetFitterVertexInfo & rhs) {
VxJetFitterVertexInfo & VxJetFitterVertexInfo::operator= (const VxJetFitterVertexInfo & rhs) {
if (this!=&rhs) {
m_verticesJF.clear();
......@@ -80,8 +80,8 @@ namespace Trk {
}
m_twoTrackVerticesInJet=rhs.m_twoTrackVerticesInJet?new Trk::TwoTrackVerticesInJet(*rhs.m_twoTrackVerticesInJet):0;
m_selectedTracksInJet=rhs.m_selectedTracksInJet?new Trk::SelectedTracksInJet(*rhs.m_selectedTracksInJet):0;
m_SVOwnership=true;
}
m_SVOwnership=true;
return *this;
}
......
......@@ -27,6 +27,7 @@ namespace Trk {
m_mass(0.),
m_energyFraction(0.),
m_energyTrkInJet(0.),
m_dstToMatLayer(1000.),
m_n2trackvertices(0){}
VxSecVKalVertexInfo::VxSecVKalVertexInfo(const std::vector<xAOD::Vertex*> & vertices,
......@@ -36,6 +37,7 @@ namespace Trk {
m_mass(mass),
m_energyFraction(energyFraction),
m_energyTrkInJet(energyTrkInJet),
m_dstToMatLayer(1000.),
m_n2trackvertices(n2trackvertices)
{
std::vector<const Trk::TrackParticleBase*>::const_iterator badTracksBegin=badTracks.begin();
......@@ -57,6 +59,7 @@ namespace Trk {
m_mass(mass),
m_energyFraction(energyFraction),
m_energyTrkInJet(energyTrkInJet),
m_dstToMatLayer(1000.),
m_n2trackvertices(n2trackvertices)
{
std::vector<const xAOD::IParticle*>::const_iterator badTracksBegin=badTracks.begin();
......@@ -77,6 +80,7 @@ namespace Trk {
m_mass(rhs.m_mass),
m_energyFraction(rhs.m_energyFraction),
m_energyTrkInJet(rhs.m_energyTrkInJet),
m_dstToMatLayer(rhs.m_dstToMatLayer),
m_n2trackvertices(rhs.m_n2trackvertices),
m_badTracksTP(rhs.m_badTracksTP),
m_badTracksIP(rhs.m_badTracksIP)
......@@ -89,6 +93,7 @@ namespace Trk {
m_mass=rhs.m_mass;
m_energyFraction=rhs.m_energyFraction;
m_energyTrkInJet=rhs.m_energyTrkInJet;
m_dstToMatLayer=rhs.m_dstToMatLayer,
m_n2trackvertices=rhs.m_n2trackvertices;
m_badTracksTP=rhs.m_badTracksTP;
m_badTracksIP=rhs.m_badTracksIP;
......
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