Skip to content

Commit ab09940

Browse files
authored
[Common] Uppercase for struct definitions (#16504)
1 parent 66bbbe9 commit ab09940

4 files changed

Lines changed: 73 additions & 80 deletions

File tree

Common/TableProducer/eventSelectionService.cxx

Lines changed: 16 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,10 @@
99
// granted to it by virtue of its status as an Intergovernmental Organization
1010
// or submit itself to any jurisdiction.
1111

12-
/// \file eventSelectionTester.cxx
12+
/// \file eventSelectionService.cxx
1313
/// \brief unified, self-configuring event selection task
1414
/// \author ALICE
1515

16-
//===============================================================
17-
//
18-
// Unified, self-configuring event selection task
19-
//
20-
//===============================================================
21-
2216
#include "Common/Core/MetadataHelper.h"
2317
#include "Common/DataModel/EventSelection.h"
2418
#include "Common/Tools/EventSelectionModule.h"
@@ -50,14 +44,14 @@ using BCsWithRun3Matchings = soa::Join<aod::BCs, aod::Run3MatchedToBCSparse>;
5044
using FullTracks = soa::Join<aod::Tracks, aod::TracksExtra>;
5145
using FullTracksIU = soa::Join<aod::TracksIU, aod::TracksExtra>;
5246

53-
struct eventselectionRun2 {
54-
o2::common::timestamp::timestampConfigurables timestampConfigurables;
47+
struct EventselectionRun2 { // o2-linter: disable=name/workflow-file (exception due to metadata-driven topology)
48+
o2::common::timestamp::TimestampConfigurables timestampConfigurables;
5549
o2::common::timestamp::TimestampModule timestampMod;
5650

57-
o2::common::eventselection::bcselConfigurables bcselOpts;
51+
o2::common::eventselection::BcselConfigurables bcselOpts;
5852
o2::common::eventselection::BcSelectionModule bcselmodule;
5953

60-
o2::common::eventselection::evselConfigurables evselOpts;
54+
o2::common::eventselection::EvselConfigurables evselOpts;
6155
o2::common::eventselection::EventSelectionModule evselmodule;
6256

6357
Produces<aod::Timestamps> timestampTable; /// Table with SOR timestamps produced by the task
@@ -75,7 +69,7 @@ struct eventselectionRun2 {
7569

7670
// buffering intermediate results for passing
7771
std::vector<uint64_t> timestamps;
78-
std::vector<o2::common::eventselection::bcselEntry> bcselsbuffer;
72+
std::vector<o2::common::eventselection::BcselEntry> bcselsbuffer;
7973

8074
// auxiliary
8175
Partition<FullTracks> tracklets = (aod::track::trackType == static_cast<uint8_t>(o2::aod::track::TrackTypeEnum::Run2Tracklet));
@@ -109,17 +103,17 @@ struct eventselectionRun2 {
109103
}
110104
};
111105

112-
struct eventselectionRun3 {
113-
o2::common::timestamp::timestampConfigurables timestampConfigurables;
106+
struct EventselectionRun3 { // o2-linter: disable=name/workflow-file (exception due to metadata-driven topology)
107+
o2::common::timestamp::TimestampConfigurables timestampConfigurables;
114108
o2::common::timestamp::TimestampModule timestampMod;
115109

116-
o2::common::eventselection::bcselConfigurables bcselOpts;
110+
o2::common::eventselection::BcselConfigurables bcselOpts;
117111
o2::common::eventselection::BcSelectionModule bcselmodule;
118112

119-
o2::common::eventselection::evselConfigurables evselOpts;
113+
o2::common::eventselection::EvselConfigurables evselOpts;
120114
o2::common::eventselection::EventSelectionModule evselmodule;
121115

122-
o2::common::eventselection::lumiConfigurables lumiOpts;
116+
o2::common::eventselection::LumiConfigurables lumiOpts;
123117
o2::common::eventselection::LumiModule lumimodule;
124118

125119
Produces<aod::Timestamps> timestampTable; /// Table with SOR timestamps produced by the task
@@ -138,7 +132,7 @@ struct eventselectionRun3 {
138132
// the best: have readable cursors
139133
// this: a stopgap solution to avoid spawning yet another device
140134
std::vector<uint64_t> timestamps;
141-
std::vector<o2::common::eventselection::bcselEntry> bcselsbuffer;
135+
std::vector<o2::common::eventselection::BcselEntry> bcselsbuffer;
142136

143137
// auxiliary
144138
Partition<FullTracksIU> pvTracks = ((aod::track::flags & static_cast<uint32_t>(o2::aod::track::PVContributor)) == static_cast<uint32_t>(o2::aod::track::PVContributor));
@@ -173,7 +167,7 @@ struct eventselectionRun3 {
173167
}
174168
};
175169

176-
WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
170+
WorkflowSpec defineDataProcessing(ConfigContext const& cfgc) // o2-linter: disable=o2-workflow-options (metadata-driven topology selection)
177171
{
178172
// Parse the metadata for later too
179173
metadataInfo.initMetadata(cfgc);
@@ -191,18 +185,18 @@ WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
191185
LOGF(warn, "Metadata info missing or incomplete. Make sure --aod-file is provided at the end of the last workflow and that the AO2D has metadata stored.");
192186
LOGF(warn, "Initializing with Run 3 data as default. Please note you will not be able to change settings manually.");
193187
LOGF(warn, "You should instead make sure the metadata is read in correctly.");
194-
return WorkflowSpec{adaptAnalysisTask<eventselectionRun3>(cfgc)};
188+
return WorkflowSpec{adaptAnalysisTask<EventselectionRun3>(cfgc)};
195189
} else {
196190
LOGF(info, "Metadata successfully read in. Is this Run 3? %i - will self-configure.", isRun3);
197191
if (isRun3) {
198-
return WorkflowSpec{adaptAnalysisTask<eventselectionRun3>(cfgc)};
192+
return WorkflowSpec{adaptAnalysisTask<EventselectionRun3>(cfgc)};
199193
} else {
200194
LOGF(warn, "******************************************************************");
201195
LOGF(warn, " Event selection service self-configuring for Run 2.");
202196
LOGF(warn, " WARNING: THIS HAS NOT BEEN VALIDATED YET, USE WITH CAUTION");
203197
LOGF(warn, " If this fails, please use event-selection-service-run2 instead.");
204198
LOGF(warn, "******************************************************************");
205-
return WorkflowSpec{adaptAnalysisTask<eventselectionRun2>(cfgc)};
199+
return WorkflowSpec{adaptAnalysisTask<EventselectionRun2>(cfgc)};
206200
}
207201
}
208202
throw std::runtime_error("Unsupported run type / problem when configuring event selection!");

Common/TableProducer/eventSelectionServiceRun2.cxx

Lines changed: 15 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,10 @@
99
// granted to it by virtue of its status as an Intergovernmental Organization
1010
// or submit itself to any jurisdiction.
1111

12-
/// \file eventSelectionTester.cxx
13-
/// \brief unified, self-configuring event selection task
12+
/// \file eventSelectionServiceRun2.cxx
13+
/// \brief event selection task for Run 2
1414
/// \author ALICE
1515

16-
//===============================================================
17-
//
18-
// Unified, self-configuring event selection task
19-
//
20-
//===============================================================
21-
2216
#include "Common/Core/MetadataHelper.h"
2317
#include "Common/DataModel/EventSelection.h"
2418
#include "Common/Tools/EventSelectionModule.h"
@@ -49,17 +43,17 @@ using BCsWithRun3Matchings = soa::Join<aod::BCs, aod::Run3MatchedToBCSparse>;
4943
using FullTracks = soa::Join<aod::Tracks, aod::TracksExtra>;
5044
using FullTracksIU = soa::Join<aod::TracksIU, aod::TracksExtra>;
5145

52-
struct eventselectionRun2 {
53-
o2::common::timestamp::timestampConfigurables timestampConfigurables;
46+
struct EventselectionRun2 { // o2-linter: disable=name/workflow-file (exception due to metadata-driven topology)
47+
o2::common::timestamp::TimestampConfigurables timestampConfigurables;
5448
o2::common::timestamp::TimestampModule timestampMod;
5549

56-
o2::common::eventselection::bcselConfigurables bcselOpts;
50+
o2::common::eventselection::BcselConfigurables bcselOpts;
5751
o2::common::eventselection::BcSelectionModule bcselmodule;
5852

59-
o2::common::eventselection::evselConfigurables evselOpts;
53+
o2::common::eventselection::EvselConfigurables evselOpts;
6054
o2::common::eventselection::EventSelectionModule evselmodule;
6155

62-
Produces<aod::Timestamps> timestampTable; /// Table with SOR timestamps produced by the task
56+
Produces<aod::Timestamps> timestampTable; // Table with SOR timestamps produced by the task
6357
Produces<aod::BcSels> bcsel;
6458
Produces<aod::EvSels> evsel;
6559

@@ -74,7 +68,7 @@ struct eventselectionRun2 {
7468

7569
// buffering intermediate results for passing
7670
std::vector<uint64_t> timestamps;
77-
std::vector<o2::common::eventselection::bcselEntry> bcselsbuffer;
71+
std::vector<o2::common::eventselection::BcselEntry> bcselsbuffer;
7872

7973
// auxiliary
8074
Partition<FullTracks> tracklets = (aod::track::trackType == static_cast<uint8_t>(o2::aod::track::TrackTypeEnum::Run2Tracklet));
@@ -108,17 +102,17 @@ struct eventselectionRun2 {
108102
}
109103
};
110104

111-
struct eventselectionRun3 {
112-
o2::common::timestamp::timestampConfigurables timestampConfigurables;
105+
struct EventselectionRun3 { // o2-linter: disable=name/workflow-file (exception due to metadata-driven topology)
106+
o2::common::timestamp::TimestampConfigurables timestampConfigurables;
113107
o2::common::timestamp::TimestampModule timestampMod;
114108

115-
o2::common::eventselection::bcselConfigurables bcselOpts;
109+
o2::common::eventselection::BcselConfigurables bcselOpts;
116110
o2::common::eventselection::BcSelectionModule bcselmodule;
117111

118-
o2::common::eventselection::evselConfigurables evselOpts;
112+
o2::common::eventselection::EvselConfigurables evselOpts;
119113
o2::common::eventselection::EventSelectionModule evselmodule;
120114

121-
o2::common::eventselection::lumiConfigurables lumiOpts;
115+
o2::common::eventselection::LumiConfigurables lumiOpts;
122116
o2::common::eventselection::LumiModule lumimodule;
123117

124118
Produces<aod::Timestamps> timestampTable; /// Table with SOR timestamps produced by the task
@@ -137,7 +131,7 @@ struct eventselectionRun3 {
137131
// the best: have readable cursors
138132
// this: a stopgap solution to avoid spawning yet another device
139133
std::vector<uint64_t> timestamps;
140-
std::vector<o2::common::eventselection::bcselEntry> bcselsbuffer;
134+
std::vector<o2::common::eventselection::BcselEntry> bcselsbuffer;
141135

142136
// auxiliary
143137
Partition<FullTracksIU> pvTracks = ((aod::track::flags & static_cast<uint32_t>(o2::aod::track::PVContributor)) == static_cast<uint32_t>(o2::aod::track::PVContributor));
@@ -181,5 +175,5 @@ WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
181175
LOGF(info, "To be improved once metadata enabling in defineDataProcessing is worked out.");
182176

183177
// force Run 2 mode
184-
return WorkflowSpec{adaptAnalysisTask<eventselectionRun2>(cfgc)};
178+
return WorkflowSpec{adaptAnalysisTask<EventselectionRun2>(cfgc)};
185179
}

0 commit comments

Comments
 (0)