CbmRoot
Loading...
Searching...
No Matches
KfSetup.cxx
Go to the documentation of this file.
1/* Copyright (C) 2024 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Sergei Zharko [committer] */
4
9
10#include "KfSetup.h"
11
12#include <sstream>
13#include <typeinfo>
14
16
17// ---------------------------------------------------------------------------------------------------------------------
18//
19template<typename T>
20std::string Setup<T>::ToString(int verbosity, int indentLevel) const
21{
22 std::stringstream msg;
23 if (verbosity > 0) {
24 constexpr char indentCh = '\t';
25 std::string indent(indentLevel, indentCh);
26 msg << indent << "\nFloating-point type: " << typeid(T).name();
27 msg << indent << "\nTARGET:\n" << fTarget.ToString(indentLevel + 1, verbosity);
28 msg << indent << "\nMODULE INDEXING SCHEME:\n" << fModuleIndexMap.ToString(indentLevel + 1);
29 msg << indent << "\nMATERIAL LAYERS:\n";
30 for (const auto& layer : fvMaterialLayers) {
31 msg << layer.ToString(indentLevel + 1, verbosity) << '\n';
32 }
33 msg << indent << "\nMAGNETIC FIELD:\n" << fField.ToString(indentLevel + 1, verbosity);
34 }
35 return msg.str();
36}
37
38namespace cbm::algo::kf
39{
40 template class Setup<float>;
41 template class Setup<double>;
42 template class Setup<fvec>;
43} // namespace cbm::algo::kf
Setup representation for the Kalman-filter framework (header)
KF-framework representation of the detector setup.
Definition KfSetup.h:33
std::string ToString(int verbosity=1, int indentLevel=0) const
String representation of the class contents.
Definition KfSetup.cxx:20