CbmRoot
Loading...
Searching...
No Matches
CbmStsTrackingInterface.h
Go to the documentation of this file.
1/* Copyright (C) 2022-2024 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Sergey Gorbunov, Sergei Zharko [committer] */
4
5/***************************************************************************************************
6 * @file CbmStsTrackingInterface.h
7 * @brief Input data and parameters interface from STS subsystem used in L1 tracker (declaration)
8 * @since 27.05.2022
9 * @author S.Zharko <s.zharko@gsi.de>
10 ***************************************************************************************************/
11
12#ifndef CbmStsTrackingInterface_h
13#define CbmStsTrackingInterface_h 1
14
15#include "CbmHit.h"
16#include "CbmStsParSetModule.h"
17#include "CbmStsParSetSensor.h"
19#include "CbmStsSetup.h"
20#include "CbmStsStation.h"
22
23#include "FairTask.h"
24
25#include "TMath.h"
26
27#include <iostream>
28
29
35public:
38
41
44
47
50
53
55 InitStatus Init() override;
56
58 InitStatus ReInit() override;
59
62
64 std::string GetDetectorName() const override { return "STS"; }
65
70 std::tuple<double, double> GetStereoAnglesSensor(int address) const override;
71
75 int GetTrackingStationIndex(const CbmHit* hit) const override { return GetTrackingStationIndex(hit->GetAddress()); }
76
80 int GetTrackingStationIndex(int address) const override { return CbmStsSetup::Instance()->GetStationNumber(address); }
81
85 int GetTrackingStationIndex(const FairMCPoint* point) const override
86 {
87 return GetTrackingStationIndex(point->GetDetectorID());
88 }
89
93 bool IsTimeInfoProvided(int /*stationId*/) const override { return true; }
94
98 // TODO: remove this method
99 [[deprecated]] double GetRadLength(int stationId) const { return GetStsStation(stationId)->GetRadLength(); }
100
104 // TODO: remove this method
105 [[deprecated]] double GetSensorThickness(int stationId) const { return GetStsStation(stationId)->GetSensorD(); }
106
108 void SetParContainers() override;
109
110 private:
114 __attribute__((always_inline)) CbmStsStation* GetStsStation(int stationId) const
115 {
116 return CbmStsSetup::Instance()->GetStation(stationId);
117 }
118
119 inline static CbmStsTrackingInterface* fpInstance{nullptr};
120
124
126};
127
128#endif // CbmStsTrackingInterface
Base abstract class for tracking detector interface to L1 (implementation of Checker)
int32_t GetAddress() const
Definition CbmHit.h:74
Parameters container for CbmStsParModule.
Parameters container for CbmStsParSensorCond.
Parameters container for CbmStsParSensor.
static CbmStsSetup * Instance()
CbmStsStation * GetStation(Int_t stationId) const
Int_t GetStationNumber(Int_t address)
Class representing a station of the StsSystem.
A CbmL1 subtask, which provides necessary methods for CA tracker to access the geometry and dataflow ...
CbmStsTrackingInterface()
Default constructor.
std::string GetDetectorName() const override
Gets name of this subsystem.
CbmStsTrackingInterface & operator=(CbmStsTrackingInterface &&)=delete
Move assignment operator.
int GetTrackingStationIndex(const FairMCPoint *point) const override
Gets a tracking station of a FairMCPoint.
static CbmStsTrackingInterface * Instance()
Gets pointer to the instance of the CbmStsTrackingInterface class.
CbmStsTrackingInterface & operator=(const CbmStsTrackingInterface &)=delete
Copy assignment operator.
InitStatus ReInit() override
FairTask: ReInit method.
double GetSensorThickness(int stationId) const
CbmStsTrackingInterface(const CbmStsTrackingInterface &)=delete
Copy constructor.
int GetTrackingStationIndex(const CbmHit *hit) const override
Gets a tracking station of a CbmHit.
ClassDefOverride(CbmStsTrackingInterface, 0)
double GetRadLength(int stationId) const
CbmStsParSetModule * fStsParSetModule
InitStatus Init() override
FairTask: Init method.
CbmStsParSetSensorCond * fStsParSetSensorCond
int GetTrackingStationIndex(int address) const override
Gets a tracking station by the address of element.
__attribute__((always_inline)) CbmStsStation *GetStsStation(int stationId) const
Gets pointer to the STS station object.
CbmStsTrackingInterface(CbmStsTrackingInterface &&)=delete
Move constructor.
void SetParContainers() override
FairTask: sets parameter containers up.
static CbmStsTrackingInterface * fpInstance
std::tuple< double, double > GetStereoAnglesSensor(int address) const override
Gets stereo angles of the two independent measured coordinates.
bool IsTimeInfoProvided(int) const override
Check if station provides time measurements.
CbmStsParSetSensor * fStsParSetSensor
Abstract class, which should be inherited by every detecting subsystem tracking interface class.