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 // Abstract PID base class for Detector PID classes
17 // Supplies detector PID classes with basic informations (i.e. Debug
21 // Markus Fasel <M.Fasel@gsi.de>
24 #include "AliAODpidUtil.h"
25 #include "AliESDpid.h"
26 #include "AliHFEpidBase.h"
27 #include "AliHFEtools.h"
29 ClassImp(AliHFEpidBase)
31 //___________________________________________________________________
32 AliHFEpidBase::AliHFEpidBase():
38 // Default constructor
42 //___________________________________________________________________
43 AliHFEpidBase::AliHFEpidBase(const Char_t *name):
49 // Default constructor
53 //___________________________________________________________________
54 AliHFEpidBase::AliHFEpidBase(const AliHFEpidBase &c):
65 //___________________________________________________________________
66 AliHFEpidBase &AliHFEpidBase::operator=(const AliHFEpidBase &ref){
68 // Assignment operator
77 //___________________________________________________________________
78 void AliHFEpidBase::Copy(TObject &ref) const {
80 // Copy function for assignment operator
82 AliHFEpidBase &target = dynamic_cast<AliHFEpidBase &>(ref);
84 target.fESDpid = fESDpid;
85 target.fAODpid = fAODpid;
90 //___________________________________________________________________
91 AliHFEpidObject &AliHFEpidObject::operator=(const AliHFEpidObject &ref){
93 // Assignment operator
96 fkRecTrack = ref.fkRecTrack;
97 fAnalysisType = ref.fAnalysisType;
98 fAbInitioPID = ref.fAbInitioPID;
99 fCentrality = ref.fCentrality;
104 //___________________________________________________________________
105 void AliHFEpidObject::SetMCTrack(const AliVParticle *mctrack){
107 // Set the aprioriPID information coming from the MC truth
109 if(mctrack) fAbInitioPID = AliHFEtools::PDG2AliPID(AliHFEtools::GetPdg(mctrack));