PandaRoot
PndBranchBurstBuilder.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 
26 #pragma once
27 
28 #include "TClonesArray.h"
29 #include "FairTask.h"
30 #include <vector>
31 
32 class PndBranchBurstBuilder : public FairTask {
33  public:
37  virtual ~PndBranchBurstBuilder();
38 
40  virtual InitStatus Init();
41 
42 
44  virtual void Exec(Option_t *opt);
45 
46  virtual TClonesArray *GetBurstData(size_t inBranchNum) = 0;
47 
49  void SetOutputPrefix(TString prefix) { fOutputPrefix = prefix; };
50 
52  void AddInputBranch(TString branchName) { fInBranchNames.push_back(branchName); };
53 
55  void SetPersistence(Bool_t val) { fPersistence = val; };
56 
57  protected:
58  std::vector<TString> fInBranchNames;
59  std::vector<TClonesArray *> fInArrays;
60  std::vector<TClonesArray *> fOutArrays;
61 
62  TString fOutputPrefix;
63  Bool_t fPersistence;
64 
66 };
67 
std::vector< TString > fInBranchNames
virtual ~PndBranchBurstBuilder()
virtual InitStatus Init()
ClassDef(PndBranchBurstBuilder, 0)
void SetPersistence(Bool_t val)
Set Persistance to kTRUE if you want to store the combined Events. otherwise they are just buffered f...
virtual void Exec(Option_t *opt)
void SetOutputPrefix(TString prefix)
Set OutputBranchName prefix. Default one is "Burst".
virtual TClonesArray * GetBurstData(size_t inBranchNum)=0
void AddInputBranch(TString branchName)
Set and add the branches for which you want to combine events.
Basic Class for building bursts of events in the simulation.
std::vector< TClonesArray * > fInArrays
std::vector< TClonesArray * > fOutArrays