ATLAS Offline Software
MuonSpectrometer
MuonCnv
MuonEventAthenaPool
MuonEventAthenaPool
CscRawDataStreamer_p0.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef CSCRAWDATA_STREAMER_P0_H
6
#define CSCRAWDATA_STREAMER_P0_H
7
8
#include "
AthenaPoolServices/T_AthenaRootConverter.h
"
9
#include "
CscRawData_p0.h
"
10
#include "
MuonRDO/CscRawData.h
"
11
12
//#include <iostream>
13
14
class
CscRawDataStreamer_p0
15
:
public
T_AthenaRootConverter
<CscRawData, CscRawData_p0 >
16
{
17
public
:
18
CscRawDataStreamer_p0
() {
19
SetClassNameAndChecksum
(
"CscRawData"
, 3995976199U);
20
}
21
22
void
CopyOldToNew
(
const
CscRawData_p0
&old_obj,
CscRawData
&new_obj )
23
{
24
// somewhat inefficient data filling, can be sped up using some tricks
25
if
( old_obj.
getSamples
().size() == 0 ) {
26
//old data in ROOT3
27
const
uint16_t
*ampls = old_obj.
getAmplitudes
();
28
std::vector<uint16_t> amplitudes;
29
for
(
int
i
=0;
i
<4;
i
++ ) {
30
amplitudes.push_back( *ampls++ );
31
}
32
CscRawData
obj
(amplitudes,
33
old_obj.
getAddress
(),
34
old_obj.
identify
(),
35
old_obj.
dpuID
());
36
new_obj =
obj
;
37
//std::cout << "CscRawDataStreamer_p0 ROOT3 " << obj;
38
}
else
{
39
CscRawData
obj
(old_obj.
getSamples
(),
40
old_obj.
getAddress
(),
41
old_obj.
identify
(),
42
old_obj.
dpuID
());
43
new_obj =
obj
;
44
//std::cout << "CscRawDataStreamer_p0 ROOT4 " << obj;
45
}
46
}
47
48
};
49
50
51
52
#endif
CscRawData_p0::getAddress
uint32_t getAddress() const
Definition:
CscRawData_p0.h:29
T_AthenaRootConverter
Definition:
T_AthenaRootConverter.h:65
CscRawData_p0
Definition:
CscRawData_p0.h:19
xAOD::uint16_t
setWord1 uint16_t
Definition:
eFexEMRoI_v1.cxx:93
lumiFormat.i
int i
Definition:
lumiFormat.py:85
CscRawData_p0.h
CscRawDataStreamer_p0::CopyOldToNew
void CopyOldToNew(const CscRawData_p0 &old_obj, CscRawData &new_obj)
The converter function which copies the content of the object from its old shape to the new shape To ...
Definition:
CscRawDataStreamer_p0.h:22
CscRawData_p0::dpuID
uint16_t dpuID() const
Definition:
CscRawData_p0.h:26
CscRawData_p0::getSamples
const std::vector< uint16_t > & getSamples() const
Definition:
CscRawData_p0.h:28
CscRawData.h
CscRawData_p0::identify
uint16_t identify() const
Definition:
CscRawData_p0.h:27
CscRawData
Class to hold the electronic output for a single CSC readout channel: n sampling ADC data + the addre...
Definition:
CscRawData.h:21
T_AthenaRootConverterBase::SetClassNameAndChecksum
void SetClassNameAndChecksum(const std::string &classname, unsigned checksum)
Set the name of the class for which this converter is implemented and the particualar ROOT streamerIn...
Definition:
T_AthenaRootConverter.h:55
CscRawDataStreamer_p0
Definition:
CscRawDataStreamer_p0.h:16
T_AthenaRootConverter.h
Athena ROOT Streaming Converter - template class to be extended by a user prividing a conversion func...
CscRawDataStreamer_p0::CscRawDataStreamer_p0
CscRawDataStreamer_p0()
Definition:
CscRawDataStreamer_p0.h:18
python.PyAthena.obj
obj
Definition:
PyAthena.py:132
CscRawData_p0::getAmplitudes
const uint16_t * getAmplitudes() const
Definition:
CscRawData_p0.h:32
Generated on Tue Dec 24 2024 21:08:54 for ATLAS Offline Software by
1.8.18