ATLAS Offline Software
Event
ByteStreamCnvSvcLegacy
src
offline_EventStorage
v5_EventStorageRecords.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
//
6
// functions to convert records to strings
7
// for debugging
8
//
9
#include <sstream>
10
11
#include "
ByteStreamCnvSvcLegacy/offline_EventStorage/v5_EventStorageRecords.h
"
12
13
std::string
offline_EventStorage_v5::string_record
(
void
*ri,
const
void
*
pi
) {
14
15
std::ostringstream
s
;
16
17
uint32_t
*record =
reinterpret_cast<
uint32_t
*
>
(ri);
18
const
uint32_t
*
pattern
=
reinterpret_cast<
const
uint32_t
*
>
(
pi
);
19
int
size
=
pattern
[1];
20
21
for
(
int
i
=0;
i
<
size
;
i
++) {
22
if
(
pattern
[
i
] != 0) {
23
s
<< std::hex <<
pattern
[
i
] << std::dec <<
" "
;
24
}
else
{
25
s
<< record[
i
] <<
" "
;
26
}
27
}
28
29
std::string rs =
s
.str();
30
return
rs;
31
}
32
33
std::string
offline_EventStorage_v5::string_record
(
const
offline_EventStorage_v5::file_name_strings
& nst) {
34
35
std::ostringstream
s
;
36
37
s
<< std::hex <<
offline_EventStorage_v5::file_name_strings_marker
<< std::dec;
38
39
s
<<
" "
<< nst.
appName
.size();
40
s
<<
" "
<< nst.
appName
;
41
42
char
ns
= nst.
appName
.size() % 4;
43
if
(
ns
)
s
.write(
"____"
,4-
ns
);
44
45
s
<<
" "
<< nst.
fileNameCore
.size();
46
s
<<
" "
<< nst.
fileNameCore
;
47
48
ns
= nst.
fileNameCore
.size() % 4;
49
if
(
ns
)
s
.write(
"____"
,4-
ns
);
50
51
std::string rs =
s
.str();
52
return
rs;
53
54
}
55
56
void
offline_EventStorage_v5::reset_record
(
void
*ri,
const
void
*
pi
) {
57
58
uint32_t
*record =
reinterpret_cast<
uint32_t
*
>
(ri);
59
const
uint32_t
*
pattern
=
reinterpret_cast<
const
uint32_t
*
>
(
pi
);
60
int
size
=
pattern
[1];
61
62
for
(
int
i
=0;
i
<
size
;
i
++) record[
i
] =
pattern
[
i
];
63
}
mergePhysValFiles.pattern
pattern
Definition:
DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:26
offline_EventStorage_v5::file_name_strings::fileNameCore
std::string fileNameCore
Definition:
v5_EventStorageRecords.h:57
python.SystemOfUnits.s
int s
Definition:
SystemOfUnits.py:131
xAOD::uint32_t
setEventNumber uint32_t
Definition:
EventInfo_v1.cxx:127
v5_EventStorageRecords.h
pi
#define pi
Definition:
TileMuonFitter.cxx:65
python.setupRTTAlg.size
int size
Definition:
setupRTTAlg.py:39
offline_EventStorage_v5::file_name_strings_marker
const uint32_t file_name_strings_marker
Definition:
v5_EventStorageRecords.h:95
offline_EventStorage_v5::file_name_strings
Definition:
v5_EventStorageRecords.h:55
lumiFormat.i
int i
Definition:
lumiFormat.py:92
offline_EventStorage_v5::file_name_strings::appName
std::string appName
Definition:
v5_EventStorageRecords.h:56
python.SystemOfUnits.ns
int ns
Definition:
SystemOfUnits.py:130
offline_EventStorage_v5::reset_record
void reset_record(void *ri, const void *pi)
Definition:
v5_EventStorageRecords.cxx:56
offline_EventStorage_v5::string_record
std::string string_record(void *ri, const void *pi)
Definition:
v5_EventStorageRecords.cxx:13
Generated on Thu Jul 4 2024 21:32:21 for ATLAS Offline Software by
1.8.18