ATLAS Offline Software
Loading...
Searching...
No Matches
makeRepeatedConditions.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
8
9#include <memory>
10
12
13 ConditionPtrs conditions;
14
15 auto el_condition = std::unique_ptr<ICondition>(nullptr);
16 el_condition.reset(new EtaConditionAbs(eta.first, eta.second));
17
18 auto rep_condition = std::unique_ptr<IRepeatedCondition>(nullptr);
19
20 std::size_t multiplicity{1u};
21 int clique{0};
22 rep_condition.reset(new RepeatedCondition(std::move(el_condition),
23 multiplicity,
24 clique));
25
26 conditions.push_back(std::move(rep_condition));
27
28 return conditions;
29}
30
31
33
34 ConditionPtrs conditions;
35
36 for (const auto& ep : etas){
37 auto el_condition = std::unique_ptr<ICondition>(nullptr);
38 el_condition.reset(new EtaConditionAbs(ep.first, ep.second));
39
40 auto rep_condition = std::unique_ptr<IRepeatedCondition>(nullptr);
41
42 std::size_t multiplicity{1u};
43 int clique{0};
44 rep_condition.reset(new RepeatedCondition(std::move(el_condition),
45 multiplicity,
46 clique));
47
48 conditions.push_back(std::move(rep_condition));
49 }
50
51 return conditions;
52}
Scalar eta() const
pseudorapidity method
std::vector< ConditionPtr > ConditionPtrs
ConditionPtrs makeRepeatedConditions(const EtaPair &eta)
std::pair< double, double > EtaPair
std::vector< EtaPair > EtaPairs