ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Trigger
TrigT1
L1Topo
L1TopoAlgorithms
Root
GenericArrayCreator.cxx
Go to the documentation of this file.
1
// Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
2
3
#include "
L1TopoAlgorithms/GenericArrayCreator.h
"
4
#include "
L1TopoEvent/ClusterTOBArray.h
"
5
#include "
L1TopoEvent/JetTOBArray.h
"
6
#include "
L1TopoEvent/ClusterTOB.h
"
7
#include "
L1TopoEvent/JetTOB.h
"
8
#include "
L1TopoEvent/GenericTOB.h
"
9
#include "
L1TopoCommon/Exception.h
"
10
11
#include <typeinfo>
12
13
REGISTER_ALG_TCS
(GenericArrayCreator)
14
15
16
// constructor
17
TCS
::
GenericArrayCreator
::
GenericArrayCreator
(
const
std
::
string
&
name
) :
SortingAlg
(
name
)
18
,
m_jetsize
(
JetTOB
::JS1)
19
{}
20
21
22
TCS::StatusCode
23
TCS::GenericArrayCreator::sort
(
const
InputTOBArray
& input,
TOBArray
& output) {
24
25
// plain copy
26
try
{
27
const
ClusterTOBArray
& in =
dynamic_cast<
const
ClusterTOBArray
&
>
(input);
28
for
(
const
ClusterTOB
* cluster : in) {
29
output.push_back(
GenericTOB
(*cluster) );
30
}
31
}
32
catch
(
const
std::bad_cast& bc) {
33
try
{
34
const
JetTOBArray
& in =
dynamic_cast<
const
JetTOBArray
&
>
(input);
35
for
(
const
JetTOB
*
jet
: in) {
36
output.push_back(
GenericTOB
(*
jet
,
m_jetsize
) );
37
}
38
return
StatusCode::SUCCESS
;
39
}
40
catch
(
const
std::bad_cast& bc) {
41
TCS_EXCEPTION
(
"GenericArrayCreator: neither ClusterArray nor JetArray"
);
42
}
43
}
44
return
StatusCode::SUCCESS
;
45
}
REGISTER_ALG_TCS
#define REGISTER_ALG_TCS(CLASS)
Definition
AlgFactory.h:62
ClusterTOBArray.h
ClusterTOB.h
GenericArrayCreator.h
GenericTOB.h
JetTOBArray.h
JetTOB.h
Exception.h
TCS_EXCEPTION
#define TCS_EXCEPTION(MSG)
Definition
Trigger/TrigT1/L1Topo/L1TopoCommon/L1TopoCommon/Exception.h:15
TCS::ClusterTOBArray
Definition
ClusterTOBArray.h:19
TCS::ClusterTOB
Definition
ClusterTOB.h:13
TCS::ConfigurableAlg::name
const std::string & name() const
Definition
ConfigurableAlg.h:49
TCS::GenericArrayCreator::GenericArrayCreator
GenericArrayCreator(const std::string &name)
Definition
GenericArrayCreator.cxx:17
TCS::GenericArrayCreator::sort
virtual StatusCode sort(const InputTOBArray &input, TOBArray &output)
Definition
GenericArrayCreator.cxx:23
TCS::GenericArrayCreator::m_jetsize
JetTOB::JetSize m_jetsize
Definition
GenericArrayCreator.h:23
TCS::GenericTOB
Definition
GenericTOB.h:35
TCS::InputTOBArray
Definition
InputTOBArray.h:15
TCS::JetTOBArray
Definition
JetTOBArray.h:21
TCS::JetTOB
Definition
JetTOB.h:18
TCS::SortingAlg::SortingAlg
SortingAlg(const std::string &name)
Definition
SortingAlg.h:21
TCS::StatusCode
Definition
Trigger/TrigT1/L1Topo/L1TopoCommon/L1TopoCommon/StatusCode.h:15
TCS::StatusCode::SUCCESS
@ SUCCESS
Definition
Trigger/TrigT1/L1Topo/L1TopoCommon/L1TopoCommon/StatusCode.h:17
TCS::TOBArray
Definition
TOBArray.h:24
const
TCS
Definition
AnomalyDetectionBDT.h:18
jet
Definition
JetCalibTools_PlotJESFactors.cxx:23
std
STL namespace.
Generated on
for ATLAS Offline Software by
1.17.0