Project
Loading...
Searching...
No Matches
PrimaryVertexExt.cxx
Go to the documentation of this file.
1
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3
// All rights not expressly granted are reserved.
4
//
5
// This software is distributed under the terms of the GNU General Public
6
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7
//
8
// In applying this license CERN does not waive the privileges and immunities
9
// granted to it by virtue of its status as an Intergovernmental Organization
10
// or submit itself to any jurisdiction.
11
12
#include "
ReconstructionDataFormats/PrimaryVertexExt.h
"
13
#include <fmt/printf.h>
14
#include <iostream>
15
#include "
CommonUtils/StringUtils.h
"
16
17
namespace
o2
18
{
19
namespace
dataformats
20
{
21
22
#ifndef GPUCA_ALIGPUCODE
23
using
GTrackID
=
o2::dataformats::GlobalTrackID
;
24
25
std::string
PrimaryVertexExt::asString
()
const
26
{
27
auto
str
=
o2::utils::Str::concat_string
(
PrimaryVertex::asString
(), fmt::format(
"VtxID={} FT0A/C={}/{} FT0T={}"
,
VtxID
,
FT0A
,
FT0C
,
FT0Time
));
28
for
(
int
i
= 0;
i
<
GTrackID::Source::NSources
;
i
++) {
29
if
(
getNSrc
(
i
) > 0) {
30
str
+= fmt::format(
" {}={}"
,
GTrackID::getSourceName
(
i
),
getNSrc
(
i
));
31
}
32
}
33
return
str
;
34
}
35
36
std::ostream&
operator<<
(std::ostream& os,
const
o2::dataformats::PrimaryVertexExt
&
v
)
37
{
38
// stream itself
39
os <<
v
.asString();
40
return
os;
41
}
42
43
void
PrimaryVertexExt::print
()
const
44
{
45
std::cout << *
this
<< std::endl;
46
}
47
48
#endif
49
50
}
// namespace dataformats
51
}
// namespace o2
StringUtils.h
i
int32_t i
Definition
GPUCommonAlgorithm.h:443
PrimaryVertexExt.h
o2::dataformats::GlobalTrackID
Definition
GlobalTrackID.h:36
o2::dataformats::GlobalTrackID::getSourceName
auto getSourceName() const
Definition
GlobalTrackID.h:100
o2::dataformats::GlobalTrackID::NSources
@ NSources
Definition
GlobalTrackID.h:70
o2::dataformats::PrimaryVertex::asString
std::string asString() const
Definition
PrimaryVertex.cxx:24
v
const GLdouble * v
Definition
glcorearb.h:832
o2::dataformats::operator<<
std::ostream & operator<<(std::ostream &os, const o2::dataformats::MeanVertexObject &o)
Definition
MeanVertexObject.cxx:51
o2
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
Definition
BitstreamReader.h:24
o2::dataformats::PrimaryVertexExt
Definition
PrimaryVertexExt.h:25
o2::dataformats::PrimaryVertexExt::print
void print() const
Definition
PrimaryVertexExt.cxx:43
o2::dataformats::PrimaryVertexExt::FT0Time
double FT0Time
Definition
PrimaryVertexExt.h:30
o2::dataformats::PrimaryVertexExt::FT0C
float FT0C
Definition
PrimaryVertexExt.h:32
o2::dataformats::PrimaryVertexExt::getNSrc
int getNSrc(int i) const
Definition
PrimaryVertexExt.h:35
o2::dataformats::PrimaryVertexExt::VtxID
int VtxID
Definition
PrimaryVertexExt.h:33
o2::dataformats::PrimaryVertexExt::FT0A
float FT0A
Definition
PrimaryVertexExt.h:31
o2::dataformats::PrimaryVertexExt::asString
std::string asString() const
Definition
PrimaryVertexExt.cxx:25
o2::utils::Str::concat_string
static std::string concat_string(Ts const &... ts)
Definition
StringUtils.h:142
str
const std::string str
Definition
test_ransEncodeDecode.cxx:37
DataFormats
Reconstruction
src
PrimaryVertexExt.cxx
Generated on Tue Feb 25 2025 17:02:53 for Project by
1.9.8