diff --git a/Calorimeter/CaloEvent/CaloEvent/CaloCluster.h b/Calorimeter/CaloEvent/CaloEvent/CaloCluster.h index 2ef118499b2173f164e7a3e94130f5cd96d6de4f..12c06dd187d03875317b0fc417f77bbb30acf6e3 100644 --- a/Calorimeter/CaloEvent/CaloEvent/CaloCluster.h +++ b/Calorimeter/CaloEvent/CaloEvent/CaloCluster.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ //Dear emacs, this is -*-c++-*- @@ -588,18 +588,12 @@ class ATLAS_NOT_THREAD_SAFE CaloCluster : public CaloCompositeKineBase, protected: - /*! \brief Sets signal state */ - virtual bool setSignalState(signalstate_t s) const; /*! \brief Sets signal state */ virtual bool setSignalState(signalstate_t s); - /*! \brief reset the signal state */ - virtual void resetSignalState() const; /*! \brief reset the signal state */ virtual void resetSignalState(); - /*! \brief Sets default signal state */ - bool setDefaultSignalState(signalstate_t s) const; /*! \brief Sets default signal state */ bool setDefaultSignalState(signalstate_t s); @@ -795,12 +789,6 @@ inline CaloCluster::signalstate_t CaloCluster::signalState() const inline CaloCluster::signalstate_t CaloCluster::defaultSignalState() const { return m_defSigState; } -inline bool CaloCluster::setDefaultSignalState(signalstate_t s) const -{ - m_defSigState = s; - return this->setSignalState(s); -} - inline bool CaloCluster::setDefaultSignalState(signalstate_t s) { m_defSigState = s; diff --git a/Calorimeter/CaloEvent/src/CaloCluster.cxx b/Calorimeter/CaloEvent/src/CaloCluster.cxx index 61fd30fe3499e8b97c70d213d0cf20a75001f4f8..1e49a6419caa56450c3e9db0ef2e79482c89fb06 100644 --- a/Calorimeter/CaloEvent/src/CaloCluster.cxx +++ b/Calorimeter/CaloEvent/src/CaloCluster.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ /******************************************************************** @@ -1343,19 +1343,6 @@ void CaloCluster::setCalEta(double eta) { P4EEtaPhiM::setEta(eta); } void CaloCluster::setCalPhi(double phi) { P4EEtaPhiM::setPhi(phi); } void CaloCluster::setCalM(double m) { P4EEtaPhiM::setM(m); } -bool CaloCluster::setSignalState(signalstate_t s) const -{ - if ( !this->hasSignalState(s) ) return false; - - m_signalState = s; - - return - s == statename_t::CALIBRATED ? this->setStateCal() : - s == statename_t::ALTCALIBRATED ? this->setStateAlt() : - s == statename_t::UNCALIBRATED ? this->setStateRaw() : - false; -} - bool CaloCluster::setSignalState(signalstate_t s) { if ( !this->hasSignalState(s) ) return false; @@ -1381,11 +1368,6 @@ bool CaloCluster::isAtSignalState(signalstate_t s) const return s == m_signalState; } -void CaloCluster::resetSignalState() const -{ - this->setSignalState(m_defSigState); -} - void CaloCluster::resetSignalState() { this->setSignalState(m_defSigState); @@ -1538,11 +1520,22 @@ unsigned int CaloCluster::getClusterPhiSize() const{ CLHEP::HepLorentzVector CaloCluster::hlv(CaloCluster::signalstate_t s) const { if(hasSignalState(s)){ - signalstate_t bak = signalState(); - setSignalState(s); - CLHEP::HepLorentzVector v = hlv(); - setSignalState(bak); - return v; + switch (s) { + case statename_t::CALIBRATED: { + P4EEtaPhiM tmp = *this; + return tmp.hlv(); + } + case statename_t::UNCALIBRATED: { + P4EEtaPhiM tmp (m_rawE, m_rawEta, m_rawPhi, m_rawM); + return tmp.hlv(); + } + case statename_t::ALTCALIBRATED: { + P4EEtaPhiM tmp (m_altE, m_altEta, m_altPhi, m_altM); + return tmp.hlv(); + } + default: + break; + } } return this->hlv(); } diff --git a/Event/EventKernel/CMakeLists.txt b/Event/EventKernel/CMakeLists.txt index 2bc2596e3f757db94c58accec144050406af8bb0..255b8f274a3f5b580ad529390ae682de29bbe62d 100644 --- a/Event/EventKernel/CMakeLists.txt +++ b/Event/EventKernel/CMakeLists.txt @@ -15,6 +15,7 @@ endif() # Declare the package's dependencies: atlas_depends_on_subdirs( PUBLIC + Control/CxxUtils Control/AthLinks Control/Navigation Control/AthenaKernel diff --git a/Event/EventKernel/EventKernel/ISignalState.h b/Event/EventKernel/EventKernel/ISignalState.h index 179eda3ca03482cb4ad7c193f4fcb24bb3b7823a..c7dbbfdd594d9bb660fcd49246a8d51a9f838f92 100755 --- a/Event/EventKernel/EventKernel/ISignalState.h +++ b/Event/EventKernel/EventKernel/ISignalState.h @@ -1,7 +1,7 @@ ///////////////////////// -*- C++ -*- ///////////////////////////// /* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ #ifndef EVENTKERNEL_ISIGNALSTATE_H @@ -36,8 +36,7 @@ struct P4SignalState { }; class SignalStateHelper; -template <class COLL> -class SignalStateCollHelper; +class SignalStateConstHelper; class ISignalState { @@ -61,15 +60,14 @@ public: protected: /** set the current signal state */ - virtual bool setSignalState(P4SignalState::State s) const = 0; + virtual bool setSignalState(P4SignalState::State s) = 0; /** reset the signal state */ - virtual void resetSignalState() const = 0; + virtual void resetSignalState() = 0; /** make friends! */ friend class SignalStateHelper; - template <class COLL> - friend class SignalStateCollHelper; + friend class SignalStateConstHelper; }; #endif diff --git a/Event/EventKernel/EventKernel/SignalStateHelper.h b/Event/EventKernel/EventKernel/SignalStateHelper.h index 6cfcd02e8451d7be31681411172fbc8ea30577d0..7b667476731eb21059e7c1717e2ad0d662bd0556 100755 --- a/Event/EventKernel/EventKernel/SignalStateHelper.h +++ b/Event/EventKernel/EventKernel/SignalStateHelper.h @@ -8,9 +8,10 @@ #define EVENTKERNEL_SIGNALSTATEHELPER_H #include "EventKernel/ISignalState.h" +#include "CxxUtils/checker_macros.h" /** - @class SignalStateHelper // SignalStateCollHelper + @class SignalStateHelper Simple helper class which allows "safe" signal state switching. As soon as the helper goes out of scope, the wrapped object @@ -28,9 +29,9 @@ public: SignalStateHelper(); /** Constructor with initialization */ - SignalStateHelper(const ISignalState* theObject); + SignalStateHelper(ISignalState* theObject); SignalStateHelper(P4SignalState::State s); - SignalStateHelper(const ISignalState* theObject, P4SignalState::State s); + SignalStateHelper(ISignalState* theObject, P4SignalState::State s); /** Destructor */ ~SignalStateHelper(); @@ -42,7 +43,7 @@ public: bool resetSignalState() ; /** Change the object controlled, this releases previous object and resets its SigState */ - bool controlObject(const ISignalState* theObject); + bool controlObject(ISignalState* theObject); /** Release controled object (this resets its signal state) */ bool releaseObject(); @@ -54,180 +55,59 @@ protected: P4SignalState::State m_currentState; /** Pointer to the owned object */ - const ISignalState* m_object; + ISignalState* m_object; }; -// COLL must be a collection of ISignalState objects with an iterator -template <class COLL> -class SignalStateCollHelper final +/** + @class SignalStateConstHelper + + Simple helper class which allows "safe" signal state switching. + As soon as the helper goes out of scope, the wrapped object + is returned to its original SignalState. + + @author Pierre-Antoine Delsart <delsart AT in2p3.fr> + @author Pier-Olivier DeViveiros <viveiros AT physics.utoronto.ca> + */ + +class ATLAS_NOT_THREAD_SAFE SignalStateConstHelper final { public: - - /** typedefs to make declarations simpler */ - typedef COLL coll_t; - typedef typename coll_t::const_iterator iterator_t; /** Empty Constructor */ - SignalStateCollHelper(); + SignalStateConstHelper(); /** Constructor with initialization */ - SignalStateCollHelper(const coll_t* theCollection); - SignalStateCollHelper(P4SignalState::State s); - SignalStateCollHelper(const coll_t* theCollection, P4SignalState::State s); - + SignalStateConstHelper(const ISignalState* theObject); + SignalStateConstHelper(P4SignalState::State s); + SignalStateConstHelper(const ISignalState* theObject, P4SignalState::State s); + /** Destructor */ - ~SignalStateCollHelper(); - + ~SignalStateConstHelper(); + /** Change the signal state for future operations */ - bool setSignalState(P4SignalState::State s); + bool setSignalState(P4SignalState::State s) ; /** Reset the Signal State of the controlled object and use it for future operations */ - bool resetSignalState(); - - /** Change the collection controlled, this releases previous object and resets its SigState */ - bool controlCollection(const coll_t* theCollection); + bool resetSignalState() ; + /** Change the object controlled, this releases previous object and resets its SigState */ + bool controlObject(const ISignalState* theObject); + /** Release controled object (this resets its signal state) */ - bool releaseCollection(); - + bool releaseObject(); + protected: - void acquireOriginalState(); - void switchCollection(P4SignalState::State s); - /** Storage of the states */ P4SignalState::State m_originalState; P4SignalState::State m_currentState; - + /** Pointer to the owned object */ - const coll_t* m_collection; -}; + ISignalState* m_object; -//***************************************************************** -// -// SignalStateCollHelper -// -//***************************************************************** - -/** Empty Constructor */ -template <class COLL> -SignalStateCollHelper<COLL>::SignalStateCollHelper(): - m_originalState(P4SignalState::UNKNOWN), - m_currentState(P4SignalState::UNKNOWN), - m_collection(0) -{} - -/** Constructor with initialization */ -template <class COLL> -SignalStateCollHelper<COLL>::SignalStateCollHelper(const COLL* theCollection): - m_currentState(P4SignalState::UNKNOWN), - m_collection(theCollection) -{ - this->acquireOriginalState(); -} - -template <class COLL> -SignalStateCollHelper<COLL>::SignalStateCollHelper(P4SignalState::State s): - m_originalState(s), - m_currentState(s), - m_collection(0) -{ - setSignalState(s); -} - -template <class COLL> -SignalStateCollHelper<COLL>::SignalStateCollHelper(const COLL* theCollection, P4SignalState::State s): - m_currentState(s), - m_collection(theCollection) -{ - if( m_collection != NULL ){ - this->acquireOriginalState(); - if(m_currentState!=P4SignalState::UNKNOWN) - { - this->switchCollection( m_currentState ); - } - } -} - -template <class COLL> -SignalStateCollHelper<COLL>::~SignalStateCollHelper() -{ - releaseCollection(); -} -template <class COLL> -void SignalStateCollHelper<COLL>::acquireOriginalState(){ - iterator_t firstObject = m_collection->begin(); - iterator_t lastObject = m_collection->end(); - if( firstObject != lastObject) - m_originalState = (*firstObject)->signalState(); - else - m_originalState = P4SignalState::CALIBRATED; -} - -template <class COLL> -void SignalStateCollHelper<COLL>::switchCollection(P4SignalState::State s){ - - iterator_t firstObject = m_collection->begin(); - iterator_t lastObject = m_collection->end(); - for( ; firstObject != lastObject; firstObject++ ) - (*firstObject)->setSignalState(s); - -} - - -/** Change the object controlled */ -template <class COLL> -bool SignalStateCollHelper<COLL>::controlCollection(const COLL* theCollection) -{ +}; - m_collection = theCollection; - this->acquireOriginalState(); - - if(m_currentState!=P4SignalState::UNKNOWN) - { - this->switchCollection( m_currentState ); - } - return true; -} - -template <class COLL> -bool SignalStateCollHelper<COLL>::setSignalState(P4SignalState::State s) -{ - m_currentState = s; - // If we do have an object attached, switch its signal state - if(m_collection != 0 && m_currentState!=P4SignalState::UNKNOWN) - { - this->switchCollection( m_currentState ); - return true; - } - return false; -} - -template <class COLL> -bool SignalStateCollHelper<COLL>::releaseCollection() -{ - // If we have an object attached, revert and remove - if(m_collection!=0) - { - this->switchCollection( m_originalState ); - m_collection=0; - return true; - } - return false; -} - -template <class COLL> -bool SignalStateCollHelper<COLL>::resetSignalState() -{ - if(m_collection!=0) - { - m_currentState = m_originalState; - this->switchCollection( m_originalState ); - return true; - } - return false; -} #endif diff --git a/Event/EventKernel/src/SignalStateHelper.cxx b/Event/EventKernel/src/SignalStateHelper.cxx index 0d4bf40390676e8fe4976caf340b57d909d79116..cd255dd4e385094ea4d02d0efc354a17e1f0a6e2 100644 --- a/Event/EventKernel/src/SignalStateHelper.cxx +++ b/Event/EventKernel/src/SignalStateHelper.cxx @@ -1,7 +1,7 @@ ///////////////////////// -*- C++ -*- ///////////////////////////// /* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ // SignalStateHelper.cxx @@ -25,7 +25,7 @@ SignalStateHelper::SignalStateHelper(): {} /** Constructor with initialization */ -SignalStateHelper::SignalStateHelper(const ISignalState* theObject): +SignalStateHelper::SignalStateHelper(ISignalState* theObject): m_originalState(P4SignalState::UNKNOWN), m_currentState(P4SignalState::UNKNOWN), m_object(0) @@ -41,7 +41,7 @@ SignalStateHelper::SignalStateHelper(P4SignalState::State s): setSignalState(s); } -SignalStateHelper::SignalStateHelper(const ISignalState* theObject, P4SignalState::State s): +SignalStateHelper::SignalStateHelper(ISignalState* theObject, P4SignalState::State s): m_originalState(P4SignalState::UNKNOWN), m_currentState(s), m_object(theObject) @@ -58,7 +58,7 @@ SignalStateHelper::~SignalStateHelper() } /** Change the object controlled */ -bool SignalStateHelper::controlObject(const ISignalState* theObject) +bool SignalStateHelper::controlObject(ISignalState* theObject) { releaseObject(); m_originalState = theObject->signalState(); @@ -103,3 +103,96 @@ bool SignalStateHelper::resetSignalState() return false; } +//***************************************************************** +// +// SignalStateConstHelper +// +//***************************************************************** + + +/** Empty Constructor */ +SignalStateConstHelper::SignalStateConstHelper(): + m_originalState(P4SignalState::UNKNOWN), + m_currentState(P4SignalState::UNKNOWN), + m_object(0) +{} + +/** Constructor with initialization */ +SignalStateConstHelper::SignalStateConstHelper(const ISignalState* theObject): + m_originalState(P4SignalState::UNKNOWN), + m_currentState(P4SignalState::UNKNOWN), + m_object(0) +{ + controlObject(theObject); +} + +SignalStateConstHelper::SignalStateConstHelper(P4SignalState::State s): + m_originalState(P4SignalState::UNKNOWN), + m_currentState(s), + m_object(0) +{ + setSignalState(s); +} + +SignalStateConstHelper::SignalStateConstHelper(const ISignalState* theObject, P4SignalState::State s): + m_originalState(P4SignalState::UNKNOWN), + m_currentState(s), + m_object(const_cast<ISignalState*>(theObject)) +{ + if( theObject != NULL ){ + m_originalState = theObject->signalState(); + m_object->setSignalState(m_currentState); + } +} + +SignalStateConstHelper::~SignalStateConstHelper() +{ + releaseObject(); +} + +/** Change the object controlled */ +bool SignalStateConstHelper::controlObject(const ISignalState* theObject) +{ + releaseObject(); + m_originalState = theObject->signalState(); + m_object = const_cast<ISignalState*>(theObject); + if(m_currentState!=P4SignalState::UNKNOWN) + m_object->setSignalState(m_currentState); + return true; +} + +bool SignalStateConstHelper::setSignalState(P4SignalState::State s) +{ + m_currentState = s; + // If we do have an object attached, switch its signal state + if(m_object != 0 && m_currentState!=P4SignalState::UNKNOWN) + { + m_object->setSignalState(m_currentState); + return true; + } + return false; +} + +bool SignalStateConstHelper::releaseObject() +{ + // If we have an object attached, revert and remove + if(m_object!=0) + { + m_object->setSignalState(m_originalState); + m_object=0; + return true; + } + return false; +} + +bool SignalStateConstHelper::resetSignalState() +{ + if(m_object!=0) + { + m_currentState = m_originalState; + m_object->setSignalState(m_originalState); + return true; + } + return false; +} + diff --git a/Event/xAOD/xAODCaloEventCnv/src/CaloClusterCnvTool.cxx b/Event/xAOD/xAODCaloEventCnv/src/CaloClusterCnvTool.cxx index d7cb2883e6f247dfa46e7fd42c0f49e969fcf460..b24ffd04c008b5d281cf96c8ad3a769ff784e5e9 100644 --- a/Event/xAOD/xAODCaloEventCnv/src/CaloClusterCnvTool.cxx +++ b/Event/xAOD/xAODCaloEventCnv/src/CaloClusterCnvTool.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ // $Id: CaloClusterCnvTool.cxx 785752 2016-11-22 15:06:34Z ssnyder $ @@ -119,7 +119,7 @@ namespace xAODMaker { xaod->setTime( aod->getTime() ); { - SignalStateHelper sstate (aod); + SignalStateConstHelper sstate (aod); sstate.setSignalState( P4SignalState::CALIBRATED ); xaod->setCalE( aod->e() ); xaod->setCalEta( aod->eta() ); diff --git a/PhysicsAnalysis/AnalysisCommon/ParticleEvent/ParticleEvent/ParticleSigStateImpl.h b/PhysicsAnalysis/AnalysisCommon/ParticleEvent/ParticleEvent/ParticleSigStateImpl.h index 961c005ca96443a9445f24e2e950001722893d17..bfdbec78d579e95b24811b53087f43131fee8022 100644 --- a/PhysicsAnalysis/AnalysisCommon/ParticleEvent/ParticleEvent/ParticleSigStateImpl.h +++ b/PhysicsAnalysis/AnalysisCommon/ParticleEvent/ParticleEvent/ParticleSigStateImpl.h @@ -1,7 +1,7 @@ ///////////////////////// -*- C++ -*- ///////////////////////////// /* - Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ // ParticleSigStateImpl.h @@ -322,10 +322,10 @@ public: protected: /** @brief set the current signal state */ - virtual bool setSignalState(state_t s) const; + virtual bool setSignalState(state_t s); /** @brief reset the signal state */ - virtual void resetSignalState() const; + virtual void resetSignalState(); /** access the vector of momentum */ std::vector<I4Momentum_t>& momentumVector(){return m_mom;} @@ -355,7 +355,7 @@ public: int m_nStates; /// Current Signal State - mutable state_t m_currentState; + state_t m_currentState; }; @@ -1155,7 +1155,7 @@ inline P4SignalState::State ParticleSigStateImpl<INavigable_t, template< class INavigable_t, class I4Momentum_t, class IParticle_t> inline bool ParticleSigStateImpl<INavigable_t, I4Momentum_t, - IParticle_t>::setSignalState(state_t s) const + IParticle_t>::setSignalState(state_t s) { if(!hasSignalState(s)) { @@ -1189,7 +1189,7 @@ inline bool ParticleSigStateImpl<INavigable_t, template< class INavigable_t, class I4Momentum_t, class IParticle_t> inline void ParticleSigStateImpl<INavigable_t, I4Momentum_t, - IParticle_t>::resetSignalState() const + IParticle_t>::resetSignalState() { m_currentState = state_t(0); } diff --git a/PhysicsAnalysis/D2PDMaker/src/D2PDJetSelector.cxx b/PhysicsAnalysis/D2PDMaker/src/D2PDJetSelector.cxx index 463291fdd918bf0efff7d075f20291e49210a824..554dbb998fb4cdf95c890fc6ef8c60bbb4024293 100644 --- a/PhysicsAnalysis/D2PDMaker/src/D2PDJetSelector.cxx +++ b/PhysicsAnalysis/D2PDMaker/src/D2PDJetSelector.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ //============================================================================ @@ -781,7 +781,7 @@ StatusCode D2PDJetSelector::processObject( const Jet* jet, // Do selections for jets with a different SignalState //---------------------------------------------------------- P4SignalState::State originalSignalState = jet->signalState(); - SignalStateHelper sigstateH( jet, (P4SignalState::State)m_signalState ); + SignalStateConstHelper sigstateH( jet, (P4SignalState::State)m_signalState ); ATH_MSG_DEBUG ( "Setting a new SignalState for this jet! Will apply the selections for the new SignalState!" ); // transverse energy selection @@ -846,7 +846,7 @@ StatusCode D2PDJetSelector::processObject( const Jet* jet, } // Now, revert the jet SignalState to the original one // done automatically when sigstateH go away. - SignalStateHelper sigstateH2( jet, originalSignalState ); + SignalStateConstHelper sigstateH2( jet, originalSignalState ); ATH_MSG_DEBUG ( "Reverting the jet to the original SignalState!" ); if (isPassed) m_nJetsPassed++; } diff --git a/PhysicsAnalysis/D3PDMaker/JetD3PDMaker/src/JetSignalStateFillerTool.cxx b/PhysicsAnalysis/D3PDMaker/JetD3PDMaker/src/JetSignalStateFillerTool.cxx index 312c6a91b2ec64f4c3b969de53ec45e236843856..418653eabd320b3392d0900c29c13ca45c520b90 100644 --- a/PhysicsAnalysis/D3PDMaker/JetD3PDMaker/src/JetSignalStateFillerTool.cxx +++ b/PhysicsAnalysis/D3PDMaker/JetD3PDMaker/src/JetSignalStateFillerTool.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ // $Id$ @@ -104,7 +104,7 @@ StatusCode JetSignalStateFillerTool::book() */ StatusCode JetSignalStateFillerTool::fill (const Jet& p) { - SignalStateHelper t(&p, P4SignalState::State(m_sigstate)); + SignalStateConstHelper t(&p, P4SignalState::State(m_sigstate)); if (m_do_E) *m_E = p.e(); if (m_do_p) *m_p = p.p(); diff --git a/Reconstruction/Jet/JetEvent/JetEvent/Jet.h b/Reconstruction/Jet/JetEvent/JetEvent/Jet.h index e1ddde1aa65be26c889c7a9742fe5cbd11f89c9e..14674b57aa5093d3c171a1c7ed0a10069082babd 100755 --- a/Reconstruction/Jet/JetEvent/JetEvent/Jet.h +++ b/Reconstruction/Jet/JetEvent/JetEvent/Jet.h @@ -1,7 +1,7 @@ // emacs, this is -*- C++ -*- /* - Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ #ifndef JETEVENT_JET_H @@ -580,18 +580,7 @@ public: friend class JetAssociationBase; friend class JetTagInfoBase; - template<class T> friend class SignalStateCollHelper; -private: - /** @brief Set signal state to uncalibrated */ - void setStateRaw() const; - - /** @brief Set signal state to constituent Scale */ - void setStateCScale() const; - - /** @brief Set signal state to calibrated */ - void setStateCal() const; - public: void setRawE(double e); /**< Sets uncalibrated @f$ E @f$ */ void setRawPx(double px); /**< Sets uncalibrated @f$ p_x @f$ */ diff --git a/Reconstruction/Jet/JetEvent/src/Jet.cxx b/Reconstruction/Jet/JetEvent/src/Jet.cxx index f7a1ac56bc248c37e8c58cbdaf3c5b8f166e69e1..28b3bbeb2684db1bc9d971bcebcf64fcf4c3aaff 100755 --- a/Reconstruction/Jet/JetEvent/src/Jet.cxx +++ b/Reconstruction/Jet/JetEvent/src/Jet.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ /////////////////////////////////////////////////////////////////////////////// @@ -962,21 +962,6 @@ double Jet::getCalPx() const { return px(P4SignalState::JETFINAL); } double Jet::getCalPy() const { return py(P4SignalState::JETFINAL); } double Jet::getCalPz() const { return pz(P4SignalState::JETFINAL); } -void Jet::setStateRaw() const -{ - this->setSignalState(P4SignalState::JETEMSCALE); -} - -void Jet::setStateCScale() const -{ - this->setSignalState(P4SignalState::JETCONSTITUENTSCALE); -} - -void Jet::setStateCal() const -{ - this->setSignalState(P4SignalState::JETFINAL); -} - double Jet::ei() const { return this->e(); } double Jet::pxi() const { return this->px(); }