ATLAS Offline Software
Loading...
Searching...
No Matches
Trigger
TrigT1
TrigT1TGC
src
TGCConnectionPPToSB.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
TrigT1TGC/TGCConnectionPPToSB.h
"
6
7
namespace
LVL1TGCTrigger
{
8
9
TGCConnectionPPToSB::~TGCConnectionPPToSB
()
10
{
11
for
(
int
i=0; i <
N_PP_PORTS
; i++) {
12
for
(
int
j=0; j<
TGCSector::NumberOfPatchPanelType
; j+=1){
13
if
(
m_SBIdToPP
[i][j]!=0)
delete
[]
m_SBIdToPP
[i][j];
14
m_SBIdToPP
[i][j]=0;
15
}
16
}
17
}
18
19
TGCConnectionPPToSB::TGCConnectionPPToSB
()
20
{
21
setNumberOfType
(
TGCSector::NumberOfPatchPanelType
);
22
for
(
int
i=0; i <
N_PP_PORTS
; i+=1)
23
for
(
int
j=0; j <
TGCSector::NumberOfPatchPanelType
; j+=1)
24
m_SBIdToPP
[i][j]=0;
25
}
26
27
TGCConnectionPPToSB::TGCConnectionPPToSB
(
const
TGCConnectionPPToSB
& right) :
28
TGCBoardConnection
(right)
29
{
30
for
(
int
i=0; i <
N_PP_PORTS
; i+=1) {
31
for
(
int
j=0; j<
TGCSector::NumberOfPatchPanelType
; j+=1){
32
if
(
m_SBIdToPP
[i][j]!=0)
delete
[]
m_SBIdToPP
[i][j];
33
m_SBIdToPP
[i][j] =
new
int
[
m_id
.at(j).size()];
34
for
(
unsigned
int
k=0; k <
m_id
.at(j).
size
(); k++)
35
m_SBIdToPP
[i][j][k] = right.
m_SBIdToPP
[i][j][k];
36
}
37
}
38
}
39
40
TGCConnectionPPToSB
&
TGCConnectionPPToSB::operator=
(
const
TGCConnectionPPToSB
& right)
41
{
42
if
(
this
!=&right){
43
int
j;
44
for
(
int
i=0; i <
N_PP_PORTS
; i++) {
45
for
( j=0; j<
TGCSector::NumberOfPatchPanelType
; j+=1){
46
if
(
m_SBIdToPP
[i][j]!=0)
delete
[]
m_SBIdToPP
[i][j];
47
m_SBIdToPP
[i][j] =
new
int
[
m_id
.at(j).size()];
48
for
(
unsigned
int
k=0; k <
m_id
.at(j).
size
(); k++)
49
m_SBIdToPP
[i][j][k] = right.
m_SBIdToPP
[i][j][k];
50
}
51
}
52
}
53
return
*
this
;
54
}
55
56
}
// end of namespace
size
size_t size() const
Number of registered mappings.
TGCConnectionPPToSB.h
LVL1TGCTrigger::TGCBoardConnection::TGCBoardConnection
TGCBoardConnection()
Definition
TGCBoardConnection.cxx:9
LVL1TGCTrigger::TGCBoardConnection::m_id
std::vector< std::vector< int > > m_id
Definition
TGCBoardConnection.h:30
LVL1TGCTrigger::TGCBoardConnection::setNumberOfType
void setNumberOfType(int ntype)
Definition
TGCBoardConnection.cxx:20
LVL1TGCTrigger::TGCConnectionPPToSB::TGCConnectionPPToSB
TGCConnectionPPToSB()
Definition
TGCConnectionPPToSB.cxx:19
LVL1TGCTrigger::TGCConnectionPPToSB::operator=
TGCConnectionPPToSB & operator=(const TGCConnectionPPToSB &right)
Definition
TGCConnectionPPToSB.cxx:40
LVL1TGCTrigger::TGCConnectionPPToSB::~TGCConnectionPPToSB
~TGCConnectionPPToSB()
Definition
TGCConnectionPPToSB.cxx:9
LVL1TGCTrigger::TGCConnectionPPToSB::N_PP_PORTS
static constexpr int N_PP_PORTS
Definition
TGCConnectionPPToSB.h:29
LVL1TGCTrigger::TGCConnectionPPToSB::m_SBIdToPP
int * m_SBIdToPP[N_PP_PORTS][TGCSector::NumberOfPatchPanelType]
Definition
TGCConnectionPPToSB.h:30
LVL1TGCTrigger::TGCSector::NumberOfPatchPanelType
@ NumberOfPatchPanelType
Definition
TGCSector.h:36
LVL1TGCTrigger
Definition
LVL1TGCTrigger.cxx:48
Generated on
for ATLAS Offline Software by
1.16.1