PandaRoot
PndGFRecoHitFactoryCreator.h
Go to the documentation of this file.
1 //****************************************************************************
2 //* This file is part of PandaRoot. *
3 //* *
4 //* PandaRoot is distributed under the terms of the *
5 //* GNU General Public License (GPL) version 3, *
6 //* copied verbatim in the file "LICENSE". *
7 //* *
8 //* Copyright (C) 2006 - 2024 FAIR GmbH and copyright holders of PandaRoot *
9 //* The copyright holders are listed in the file "COPYRIGHTHOLDERS". *
10 //* The authors are listed in the file "AUTHORS". *
11 //****************************************************************************
12 
21 #pragma once
22 
23 #include <MeasurementProducer.h>
24 #include <MeasurementFactory.h>
25 #include <AbsMeasurement.h>
26 
28  public:
31 
32  void AddBranch(TString branchName) { fBranches[branchName] = nullptr; }
33 
34  Bool_t Init();
35 
36  genfit::AbsMeasurementProducer<genfit::AbsMeasurement> *CreateProducer(TString branchName, TClonesArray *tcArray);
38 
39  protected:
40  void FillRecoHitFactory();
41  void SetDefaultBranches();
42  void InitBranches();
43 
44  private:
45  genfit::MeasurementFactory<genfit::AbsMeasurement> *fTheRecoHitFactory = nullptr;
46  TClonesArray *fTubeArray = nullptr;
47  TClonesArray *fFtsTubeArray = nullptr;
48  std::map<TString, TClonesArray *> fBranches; //< branchName, matching TClonesArray;
49 };
void AddBranch(TString branchName)
virtual ~PndGFRecoHitFactoryCreator()
genfit::MeasurementFactory< genfit::AbsMeasurement > * GetFactory()
genfit::AbsMeasurementProducer< genfit::AbsMeasurement > * CreateProducer(TString branchName, TClonesArray *tcArray)
Helper class to connect Panda hits with genfit2 measurements via the genfit MeasurementFactory.