]>
Commit | Line | Data |
---|---|---|
7f48d376 | 1 | #ifndef ALIJETPARTICLESREADERKINEGOODTPC_H |
2 | #define ALIJETPARTICLESREADERKINEGOODTPC_H | |
3 | ||
4 | /* $Id$ */ | |
5 | ||
6 | //_______________________________________________________________________ | |
7 | ///////////////////////////////////////////////////////////////////////// | |
8 | // | |
9 | // class AliJetParticlesReaderKineGoodTPC | |
10 | // | |
53f1300c | 11 | // Reader for Good TPC tracks (generated by macro in TPC) |
7f48d376 | 12 | // |
13 | // loizides@ikf.uni-frankfurt.de | |
14 | // | |
15 | ///////////////////////////////////////////////////////////////////////// | |
16 | ||
17 | #include <Riostream.h> | |
18 | #include <TString.h> | |
19 | #include "AliJetParticlesReader.h" | |
20 | ||
21 | class AliJetParticlesReaderKineGoodTPC: public AliJetParticlesReader | |
22 | { | |
23 | public: | |
24 | AliJetParticlesReaderKineGoodTPC(); | |
25 | AliJetParticlesReaderKineGoodTPC(TString&); | |
26 | AliJetParticlesReaderKineGoodTPC(TObjArray*, const Char_t *filename="good_tracks_tpc"); | |
27 | virtual ~AliJetParticlesReaderKineGoodTPC(); | |
28 | ||
29 | void Rewind(); | |
30 | ||
31 | protected: | |
32 | ||
33 | Int_t ReadNext(); | |
34 | Int_t OpenFile(Int_t n); | |
35 | Bool_t IsAcceptedParticle(Float_t pt, Float_t phi, Float_t eta) const; | |
36 | ||
37 | TString fFileName; //file name | |
38 | ifstream* fInput; //!pointer to file | |
39 | ||
40 | ClassDef(AliJetParticlesReaderKineGoodTPC,1) | |
41 | }; | |
42 | ||
43 | inline Bool_t AliJetParticlesReaderKineGoodTPC::IsAcceptedParticle(Float_t pt, Float_t phi, Float_t eta) const | |
44 | { | |
45 | if((pt<fPtMin)||(pt>fPtMax)) return kFALSE; | |
46 | if((eta<fEtaMin)||(eta>fEtaMax)) return kFALSE; | |
47 | if((phi<fPhiMin)||(phi>fPhiMax)) return kFALSE; | |
48 | ||
49 | return kTRUE; | |
50 | } | |
51 | #endif |