From 76147c6d8b4c0a0a2400ca0abdbf54c39851587c Mon Sep 17 00:00:00 2001 From: "se.gorbunov" <se.gorbunov@gsi.de> Date: Fri, 4 Aug 2023 21:01:33 +0000 Subject: [PATCH] ca: delete obsolete interface, warning fixes --- core/qa/CbmQaTask.cxx | 2 +- core/qa/CbmQaTask.h | 3 +-- reco/L1/CbmL1.h | 10 +++++----- reco/L1/CbmL1ReadEvent.cxx | 6 ++---- reco/L1/qa/CbmCaInputQaMuch.cxx | 5 +---- reco/L1/qa/CbmCaInputQaSts.cxx | 2 +- reco/L1/qa/CbmCaInputQaTof.cxx | 4 +--- reco/L1/qa/CbmCaInputQaTrd.cxx | 4 +--- reco/L1/qa/CbmCaOutputQa.cxx | 2 +- 9 files changed, 14 insertions(+), 24 deletions(-) diff --git a/core/qa/CbmQaTask.cxx b/core/qa/CbmQaTask.cxx index 4d086e3544..ecc17172a5 100644 --- a/core/qa/CbmQaTask.cxx +++ b/core/qa/CbmQaTask.cxx @@ -25,7 +25,7 @@ ClassImp(CbmQaTask); // --------------------------------------------------------------------------------------------------------------------- // -CbmQaTask::CbmQaTask(const char* name, const char* prefix, int verbose, bool isMCUsed) +CbmQaTask::CbmQaTask(const char* name, int verbose, bool isMCUsed) : FairTask(name, verbose) , CbmQaIO(name) , fbUseMC(isMCUsed) diff --git a/core/qa/CbmQaTask.h b/core/qa/CbmQaTask.h index 494b2c3007..cfd3ea35cc 100644 --- a/core/qa/CbmQaTask.h +++ b/core/qa/CbmQaTask.h @@ -42,10 +42,9 @@ class CbmQaTask : public FairTask, public CbmQaIO { public: /// Constructor from parameters /// \param name Name of the task - /// \param prefix Unique prefix for writeable root objects /// \param verbose Verbose level /// \param isMCUsed Flag: true - MC information is used, false - only reconstructed data QA is processed - CbmQaTask(const char* name, const char* prefix, int verbose, bool isMCUsed); + CbmQaTask(const char* name, int verbose, bool isMCUsed); /// Default constructor CbmQaTask() = delete; // TODO: Let's see, what can happen, if one deletes default constructor diff --git a/reco/L1/CbmL1.h b/reco/L1/CbmL1.h index bf19109831..37d698306b 100644 --- a/reco/L1/CbmL1.h +++ b/reco/L1/CbmL1.h @@ -297,35 +297,35 @@ public: /// Obsolete setters to be removed /// Sets material budget file name for MVD - void SetMvdMaterialBudgetFileName(const TString& fileName) + void SetMvdMaterialBudgetFileName(const TString&) { LOG(warning) << "CbmL1::SetMvdMaterialBudgetFileName() is obsolete and will be deleted soon, don't call it\n" << " ! The material budget files are not used anymore !"; } /// Sets material budget file name for STS - void SetStsMaterialBudgetFileName(const TString& fileName) + void SetStsMaterialBudgetFileName(const TString&) { LOG(warning) << "CbmL1::SetStsMaterialBudgetFileName() is obsolete and will be deleted soon, don't call it\n" << " ! The material budget files are not used anymore !"; } /// Sets material budget file name for MuCh - void SetMuchMaterialBudgetFileName(const TString& fileName) + void SetMuchMaterialBudgetFileName(const TString&) { LOG(warning) << "CbmL1::SetMuchMaterialBudgetFileName() is obsolete and will be deleted soon, don't call it\n" << " ! The material budget files are not used anymore !"; } /// Sets material budget file name for TRD - void SetTrdMaterialBudgetFileName(const TString& fileName) + void SetTrdMaterialBudgetFileName(const TString&) { LOG(warning) << "CbmL1::SetTrdMaterialBudgetFileName() is obsolete and will be deleted soon, don't call it\n" << " ! The material budget files are not used anymore !"; } /// Sets material budget file name for TOF - void SetTofMaterialBudgetFileName(const TString& fileName) + void SetTofMaterialBudgetFileName(const TString&) { LOG(warning) << "CbmL1::SetTofMaterialBudgetFileName() is obsolete and will be deleted soon, don't call it\n" << " ! The material budget files are not used anymore !"; diff --git a/reco/L1/CbmL1ReadEvent.cxx b/reco/L1/CbmL1ReadEvent.cxx index dbc60d7073..76b504ea1c 100644 --- a/reco/L1/CbmL1ReadEvent.cxx +++ b/reco/L1/CbmL1ReadEvent.cxx @@ -502,13 +502,11 @@ void CbmL1::ReadEvent(CbmEvent* event) // catch the situation when MVD hits are present in data, but there is no corresp. branch in the event // read hits directly from the time slice - bool readFromEvent = (event && (event->GetNofData(ECbmDataType::kMvdHit) >= 0)); - - Int_t nEntries = (readFromEvent ? event->GetNofData(ECbmDataType::kMvdHit) : fpMvdHits->GetEntriesFast()); + Int_t nEntries = (event ? event->GetNofData(ECbmDataType::kMvdHit) : fpMvdHits->GetEntriesFast()); for (int j = 0; j < nEntries; j++) { - Int_t hitIndex = (readFromEvent ? event->GetIndex(ECbmDataType::kMvdHit, j) : j); + Int_t hitIndex = (event ? event->GetIndex(ECbmDataType::kMvdHit, j) : j); TmpHit th; CbmMvdHit* h = L1_DYNAMIC_CAST<CbmMvdHit*>(fpMvdHits->At(hitIndex)); diff --git a/reco/L1/qa/CbmCaInputQaMuch.cxx b/reco/L1/qa/CbmCaInputQaMuch.cxx index 50bbac4394..bef4e3b95c 100644 --- a/reco/L1/qa/CbmCaInputQaMuch.cxx +++ b/reco/L1/qa/CbmCaInputQaMuch.cxx @@ -48,10 +48,7 @@ namespace phys = L1Constants::phys; // from L1Constants.h // --------------------------------------------------------------------------------------------------------------------- // -CbmCaInputQaMuch::CbmCaInputQaMuch(int verbose, bool isMCUsed) - : CbmQaTask("CbmCaInputQaMuch", "camuch", verbose, isMCUsed) -{ -} +CbmCaInputQaMuch::CbmCaInputQaMuch(int verbose, bool isMCUsed) : CbmQaTask("CbmCaInputQaMuch", verbose, isMCUsed) {} // --------------------------------------------------------------------------------------------------------------------- // diff --git a/reco/L1/qa/CbmCaInputQaSts.cxx b/reco/L1/qa/CbmCaInputQaSts.cxx index e0aa7dfea7..8489caf358 100644 --- a/reco/L1/qa/CbmCaInputQaSts.cxx +++ b/reco/L1/qa/CbmCaInputQaSts.cxx @@ -53,7 +53,7 @@ namespace phys = L1Constants::phys; // from L1Constants.h // --------------------------------------------------------------------------------------------------------------------- // -CbmCaInputQaSts::CbmCaInputQaSts(int verbose, bool isMCUsed) : CbmQaTask("CbmCaInputQaSts", "casts", verbose, isMCUsed) +CbmCaInputQaSts::CbmCaInputQaSts(int verbose, bool isMCUsed) : CbmQaTask("CbmCaInputQaSts", verbose, isMCUsed) { // TODO: remove an enlarged threshold when the pulls are fixed SetPullMeanDeviationThrsh(0.1); diff --git a/reco/L1/qa/CbmCaInputQaTof.cxx b/reco/L1/qa/CbmCaInputQaTof.cxx index ca329d6a13..b2af229218 100644 --- a/reco/L1/qa/CbmCaInputQaTof.cxx +++ b/reco/L1/qa/CbmCaInputQaTof.cxx @@ -52,9 +52,7 @@ namespace phys = L1Constants::phys; // from L1Constants.h // --------------------------------------------------------------------------------------------------------------------- // -CbmCaInputQaTof::CbmCaInputQaTof(int verbose, bool isMCUsed) : CbmQaTask("CbmCaInputQaTof", "catof", verbose, isMCUsed) -{ -} +CbmCaInputQaTof::CbmCaInputQaTof(int verbose, bool isMCUsed) : CbmQaTask("CbmCaInputQaTof", verbose, isMCUsed) {} // --------------------------------------------------------------------------------------------------------------------- // diff --git a/reco/L1/qa/CbmCaInputQaTrd.cxx b/reco/L1/qa/CbmCaInputQaTrd.cxx index a5883c47fc..1a77f6d96a 100644 --- a/reco/L1/qa/CbmCaInputQaTrd.cxx +++ b/reco/L1/qa/CbmCaInputQaTrd.cxx @@ -48,9 +48,7 @@ namespace phys = L1Constants::phys; // from L1Constants.h // --------------------------------------------------------------------------------------------------------------------- // -CbmCaInputQaTrd::CbmCaInputQaTrd(int verbose, bool isMCUsed) : CbmQaTask("CbmCaInputQaTrd", "catrd", verbose, isMCUsed) -{ -} +CbmCaInputQaTrd::CbmCaInputQaTrd(int verbose, bool isMCUsed) : CbmQaTask("CbmCaInputQaTrd", verbose, isMCUsed) {} // --------------------------------------------------------------------------------------------------------------------- // diff --git a/reco/L1/qa/CbmCaOutputQa.cxx b/reco/L1/qa/CbmCaOutputQa.cxx index 3a9fc87e54..f052cbae76 100644 --- a/reco/L1/qa/CbmCaOutputQa.cxx +++ b/reco/L1/qa/CbmCaOutputQa.cxx @@ -27,7 +27,7 @@ using cbm::ca::OutputQa; // --------------------------------------------------------------------------------------------------------------------- // -OutputQa::OutputQa(int verbose, bool isMCUsed) : CbmQaTask("CbmCaOutputQa", "caout", verbose, isMCUsed) +OutputQa::OutputQa(int verbose, bool isMCUsed) : CbmQaTask("CbmCaOutputQa", verbose, isMCUsed) { // Create MC module -- GitLab