EIC Software
Reference for
EIC
simulation and reconstruction software on GitHub
|
A class to access time ordered data in a root branch. More...
#include <EicRoot/blob/master/base/FairTSBufferFunctional.h>
Public Member Functions | |
FairTSBufferFunctional (TString branchName, TTree *sourceTree, BinaryFunctor *stopFunction, BinaryFunctor *startFunction=0) | |
virtual | ~FairTSBufferFunctional () |
TClonesArray * | GetData (Double_t stopParameter) |
TClonesArray * | GetData (Double_t startParameter, Double_t stopParameter) |
Int_t | GetBranchIndex () |
void | SetStartFunction (BinaryFunctor *function) |
void | SetStopFunction (BinaryFunctor *function) |
Bool_t | AllDataProcessed () |
Bool_t | TimeOut () |
Int_t | FindStartIndex (Double_t startParameter) |
Private Member Functions | |
void | ReadInNextFilledEntry () |
Int_t | ReadInPreviousFilledEntry (Int_t startEntry) |
void | ReadInNextEntry () |
void | ReadInEntry (Int_t number) |
void | AbsorbDataBufferArray () |
FairTSBufferFunctional (const FairTSBufferFunctional &) | |
FairTSBufferFunctional & | operator= (const FairTSBufferFunctional &) |
ClassDef (FairTSBufferFunctional, 0) | |
Private Attributes | |
TClonesArray * | fOutputArray |
TClonesArray * | fBufferArray |
TClonesArray * | fInputArray |
BinaryFunctor * | fStartFunction |
BinaryFunctor * | fStopFunction |
TBranch * | fBranch |
Int_t | fBranchIndex |
Int_t | fStartIndex |
Int_t | fVerbose |
A class to access time ordered data in a root branch.
In the constructor of the class one has to give the branch name of the data, the tree the data is stored in and a BinaryFunctor which contains the method how the data should be extracted. Several example functors already exists. To extract the data one has to call GetData with a parameter which fits to the selected functor. GetData returns a TClonesArray which contains the data.
Be careful! The buffer runs through the time ordered data in one time direction only. This means that you cannot request data which is older than the data you have requested before.
Addition: This is not true anymore. GetData(Double_t, Double_t) is able to get also data which is older but this only works if you request a fixed time via StopTime functor. For other functors the behavior is unpredictable.
Created on: Feb 18, 201 Author: stockman
Definition at line 140 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 140 of file FairTSBufferFunctional.h
FairTSBufferFunctional::FairTSBufferFunctional | ( | TString | branchName, |
TTree * | sourceTree, | ||
BinaryFunctor * | stopFunction, | ||
BinaryFunctor * | startFunction = 0 |
||
) |
Definition at line 9 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 9 of file FairTSBufferFunctional.cxx
References fBranch, fBufferArray, fInputArray, fOutputArray, FairRootManager::GetObject(), and FairRootManager::Instance().
|
inlinevirtual |
Definition at line 146 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 146 of file FairTSBufferFunctional.h
|
private |
|
private |
Definition at line 218 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 218 of file FairTSBufferFunctional.cxx
References fBufferArray, fInputArray, and fVerbose.
Referenced by GetData().
Bool_t FairTSBufferFunctional::AllDataProcessed | ( | ) |
Definition at line 252 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 252 of file FairTSBufferFunctional.cxx
References fBranch, fBranchIndex, fBufferArray, and fOutputArray.
|
private |
Int_t FairTSBufferFunctional::FindStartIndex | ( | Double_t | startParameter | ) |
Definition at line 130 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 130 of file FairTSBufferFunctional.cxx
References fBranchIndex, fInputArray, fStartFunction, ReadInEntry(), ReadInNextFilledEntry(), and ReadInPreviousFilledEntry().
Referenced by GetData().
|
inline |
Definition at line 149 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 149 of file FairTSBufferFunctional.h
References fBranchIndex.
Referenced by GetData().
TClonesArray * FairTSBufferFunctional::GetData | ( | Double_t | stopParameter | ) |
Definition at line 32 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 32 of file FairTSBufferFunctional.cxx
References AbsorbDataBufferArray(), fBranch, fBranchIndex, fBufferArray, fInputArray, fOutputArray, fStopFunction, fVerbose, FairTimeStamp::GetTimeStamp(), ReadInNextEntry(), and ReadInNextFilledEntry().
Referenced by GetData().
TClonesArray * FairTSBufferFunctional::GetData | ( | Double_t | startParameter, |
Double_t | stopParameter | ||
) |
Definition at line 116 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 116 of file FairTSBufferFunctional.cxx
References fBranchIndex, fBufferArray, FindStartIndex(), fInputArray, fStartFunction, GetBranchIndex(), GetData(), and ReadInEntry().
|
private |
|
private |
Definition at line 236 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 236 of file FairTSBufferFunctional.cxx
References fBranch, fInputArray, fVerbose, and FairRootManager::Instance().
Referenced by FindStartIndex(), GetData(), ReadInNextEntry(), ReadInNextFilledEntry(), and ReadInPreviousFilledEntry().
|
private |
Definition at line 228 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 228 of file FairTSBufferFunctional.cxx
References fBranch, fBranchIndex, and ReadInEntry().
Referenced by GetData().
|
private |
Definition at line 193 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 193 of file FairTSBufferFunctional.cxx
References fBranch, fBranchIndex, fInputArray, fVerbose, and ReadInEntry().
Referenced by FindStartIndex(), and GetData().
|
private |
Definition at line 206 of file FairTSBufferFunctional.cxx.
View newest version in sPHENIX GitHub at line 206 of file FairTSBufferFunctional.cxx
References fInputArray, and ReadInEntry().
Referenced by FindStartIndex().
|
inline |
Definition at line 150 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 150 of file FairTSBufferFunctional.h
References fStartFunction.
|
inline |
Definition at line 151 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 151 of file FairTSBufferFunctional.h
References fStopFunction.
|
inline |
Definition at line 154 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 154 of file FairTSBufferFunctional.h
References fStartFunction, fStopFunction, and BinaryFunctor::TimeOut().
|
private |
Definition at line 186 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 186 of file FairTSBufferFunctional.h
Referenced by AllDataProcessed(), FairTSBufferFunctional(), GetData(), ReadInEntry(), ReadInNextEntry(), and ReadInNextFilledEntry().
|
private |
Definition at line 187 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 187 of file FairTSBufferFunctional.h
Referenced by AllDataProcessed(), FindStartIndex(), GetBranchIndex(), GetData(), ReadInNextEntry(), and ReadInNextFilledEntry().
|
private |
Definition at line 180 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 180 of file FairTSBufferFunctional.h
Referenced by AbsorbDataBufferArray(), AllDataProcessed(), FairTSBufferFunctional(), and GetData().
|
private |
Definition at line 181 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 181 of file FairTSBufferFunctional.h
Referenced by AbsorbDataBufferArray(), FairTSBufferFunctional(), FindStartIndex(), GetData(), ReadInEntry(), ReadInNextFilledEntry(), and ReadInPreviousFilledEntry().
|
private |
Definition at line 179 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 179 of file FairTSBufferFunctional.h
Referenced by AllDataProcessed(), FairTSBufferFunctional(), and GetData().
|
private |
Definition at line 183 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 183 of file FairTSBufferFunctional.h
Referenced by FindStartIndex(), GetData(), SetStartFunction(), and TimeOut().
|
private |
Definition at line 188 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 188 of file FairTSBufferFunctional.h
|
private |
Definition at line 184 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 184 of file FairTSBufferFunctional.h
Referenced by GetData(), SetStopFunction(), and TimeOut().
|
private |
Definition at line 190 of file FairTSBufferFunctional.h.
View newest version in sPHENIX GitHub at line 190 of file FairTSBufferFunctional.h
Referenced by AbsorbDataBufferArray(), GetData(), ReadInEntry(), and ReadInNextFilledEntry().