CbmRoot
Loading...
Searching...
No Matches
KfMeasurementTime.cxx
Go to the documentation of this file.
1/* Copyright (C) 2022 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Sergey Gorbunov, Sergei Zharko [committer] */
4
7
8#include "KfMeasurementTime.h"
9
10#include <iomanip>
11#include <sstream> // for stringstream
12
14{
15 //----------------------------------------------------------------------------------------------------------------------
16 //
17 template<typename DataT>
18 std::string MeasurementTime<DataT>::ToString(int indentLevel) const
19 {
20 std::stringstream aStream{};
21 // TODO: possibly it is better to place the indentChar into ca::Parameters (S.Zharko)
22 constexpr char indentChar = '\t';
23 std::string indent(indentLevel, indentChar);
24 aStream << indent << "t: " << std::setw(12) << std::setfill(' ') << T() << '\n';
25 aStream << indent << "dt2: " << std::setw(12) << std::setfill(' ') << Dt2() << '\n';
26 aStream << indent << "ndfT: " << std::setw(12) << std::setfill(' ') << NdfT() << '\n';
27 return aStream.str();
28 }
29
32
33 template class MeasurementTime<fvec>;
34 template class MeasurementTime<float>;
35 template class MeasurementTime<double>;
36
37} // namespace cbm::algo::kf
The class describes a time measurement.
std::string ToString(int indentLevel=0) const