CbmRoot
Loading...
Searching...
No Matches
CaTimesliceHeader.h
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
#pragma once
11
12
#include <string>
13
14
namespace
cbm::algo::ca
15
{
18
class
TimesliceHeader
{
19
public
:
21
float
&
End
() {
return
fEnd
; }
22
float
End
()
const
{
return
fEnd
; }
23
25
float
&
Start
() {
return
fStart
; }
26
float
Start
()
const
{
return
fStart
; }
27
29
std::string
ToString
()
const
;
30
32
float
ConvToTau
(
float
time)
const
{
return
(time -
fStart
) / (
fEnd
-
fStart
); }
33
35
float
ConvToNs
(
float
tau)
const
{
return
fStart
+ tau * (
fEnd
-
fStart
); }
36
37
private
:
38
float
fStart
;
39
float
fEnd
;
40
};
41
}
// namespace cbm::algo::ca
cbm::algo::ca::TimesliceHeader
Structure for keeping the current information on the timeslice.
Definition
CaTimesliceHeader.h:18
cbm::algo::ca::TimesliceHeader::ConvToTau
float ConvToTau(float time) const
Converts time from ns to tau.
Definition
CaTimesliceHeader.h:32
cbm::algo::ca::TimesliceHeader::End
float & End()
Accesses the end of timeslice [ns].
Definition
CaTimesliceHeader.h:21
cbm::algo::ca::TimesliceHeader::Start
float & Start()
Accesses the start of timeslice [ns].
Definition
CaTimesliceHeader.h:25
cbm::algo::ca::TimesliceHeader::fStart
float fStart
Start of timeslice.
Definition
CaTimesliceHeader.h:38
cbm::algo::ca::TimesliceHeader::End
float End() const
Definition
CaTimesliceHeader.h:22
cbm::algo::ca::TimesliceHeader::ConvToNs
float ConvToNs(float tau) const
Converts time from tau to ns.
Definition
CaTimesliceHeader.h:35
cbm::algo::ca::TimesliceHeader::fEnd
float fEnd
End of timeslice.
Definition
CaTimesliceHeader.h:39
cbm::algo::ca::TimesliceHeader::Start
float Start() const
Definition
CaTimesliceHeader.h:26
cbm::algo::ca::TimesliceHeader::ToString
std::string ToString() const
String representation of the contents.
Definition
CaTimesliceHeader.cxx:18
cbm::algo::ca
TODO: SZh 8.11.2022: add selection of parameterisation.
Definition
CaBranch.h:14
algo
ca
core
data
CaTimesliceHeader.h
Generated on Mon Feb 3 2025 23:03:44 for CbmRoot by
1.12.0