1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
16 // Container for TRD PID Response Objects stored in the OADB
18 #ifndef ALITRDPIDRESPONSEOBJECT_H
19 #define ALITRDPIDRESPONSEOBJECT_H
25 #ifndef AliTRDPIDRESPONSE_H
26 #include "AliTRDPIDResponse.h"
30 class AliTRDPIDParams;
31 class AliTRDPIDReference;
32 class AliTRDPIDResponse;
34 class AliTRDPIDResponseObject : public TNamed{
36 enum ETRDPIDResponseObjectStatus {
40 AliTRDPIDResponseObject();
41 AliTRDPIDResponseObject(const char *name);
42 AliTRDPIDResponseObject(const AliTRDPIDResponseObject &ref);
43 AliTRDPIDResponseObject &operator=(const AliTRDPIDResponseObject &ref);
44 virtual ~AliTRDPIDResponseObject();
46 virtual void Print(Option_t *opt) const;
48 void SetPIDParams(AliTRDPIDParams *params,AliTRDPIDResponse::ETRDPIDMethod method=AliTRDPIDResponse::kLQ1D);
49 void SetPIDReference(AliTRDPIDReference *params,AliTRDPIDResponse::ETRDPIDMethod method=AliTRDPIDResponse::kLQ1D);
52 TObject *GetLowerReference(AliPID::EParticleType spec, Float_t p, Float_t &pLower,AliTRDPIDResponse::ETRDPIDMethod method=AliTRDPIDResponse::kLQ1D) const;
53 TObject *GetUpperReference(AliPID::EParticleType spec, Float_t p, Float_t &pUpper,AliTRDPIDResponse::ETRDPIDMethod method=AliTRDPIDResponse::kLQ1D) const;
55 Int_t GetNumberOfMomentumBins(AliTRDPIDResponse::ETRDPIDMethod method=AliTRDPIDResponse::kLQ1D) const;
57 // Derive threshold params
58 Bool_t GetThresholdParameters(Int_t ntracklets, Double_t efficiency, Double_t *params,Double_t centrality = -1,AliTRDPIDResponse::ETRDPIDMethod method=AliTRDPIDResponse::kLQ1D) const;
61 Int_t GetNSlicesQ0() const{return fNSlicesQ0;}
62 void SetNSlicesQ0(Int_t nsl){fNSlicesQ0=nsl;}
66 AliTRDPIDParams *fPIDParams[AliTRDPIDResponse::kNMethod]; // Contains Thresholds
67 AliTRDPIDReference *fPIDReference[AliTRDPIDResponse::kNMethod]; // Contains References
68 Int_t fNSlicesQ0; // Number of Slices for Q0
70 ClassDef(AliTRDPIDResponseObject, 1);