1 #ifndef ALIRSNPAIRDEF_H
2 #define ALIRSNPAIRDEF_H
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
7 ////////////////////////////////////////////////////////////////////////////////
9 // Resonance decay tree definition.
11 ////////////////////////////////////////////////////////////////////////////////
13 #include "AliRsnDaughter.h"
14 #include "AliRsnDaughterDef.h"
16 class AliRsnPairDef : public TObject {
20 AliRsnPairDef(EPARTYPE type1, Char_t ch1, EPARTYPE type2, Char_t ch2, Int_t motherPDG = 0, Double_t motherMass = 0.0);
21 AliRsnPairDef(AliRsnDaughter::ESpecies type1, Char_t ch1, AliRsnDaughter::ESpecies type2, Char_t ch2, Int_t motherPDG = 0, Double_t motherMass = 0.0);
22 AliRsnPairDef(const AliRsnPairDef ©);
23 const AliRsnPairDef& operator= (const AliRsnPairDef ©);
24 virtual ~AliRsnPairDef() { }
26 virtual const char* GetName() const {return Form("%s_%s", fDef1.GetName(), fDef2.GetName());}
27 Int_t GetMotherPDG() const {return fMotherPDG;}
28 Double_t GetMotherMass() const {return fMotherMass;}
29 AliRsnDaughterDef& GetDef1() {return fDef1;}
30 AliRsnDaughterDef& GetDef2() {return fDef2;}
31 AliRsnDaughterDef& GetDef(Int_t i) {if (i<1) return GetDef1(); else return GetDef2();}
33 void SetMotherPDG(Int_t pdg) {fMotherPDG = pdg;}
34 void SetMotherMass(Double_t mass) {fMotherMass = mass;}
35 void SetDef1(AliRsnDaughterDef *def) {if (def) fDef1 = (*def);}
36 void SetDef2(AliRsnDaughterDef *def) {if (def) fDef2 = (*def);}
37 void SetDef(Int_t i, AliRsnDaughterDef *def) {if (!def) return; if (i<1) fDef1 = (*def); else fDef2 = (*def);}
39 Bool_t IsLikeSign() const {return (fDef1.GetChargeC() == fDef2.GetChargeC());}
40 Bool_t HasEqualPID() const {return (fDef1.GetPID() == fDef2.GetPID());}
44 Double_t fMotherMass; // nominal mass of true mother
45 Int_t fMotherPDG; // PDG code of true mother (if known)
46 AliRsnDaughterDef fDef1; // definitions for daughter #1 (see class)
47 AliRsnDaughterDef fDef2; // definitions for daughter #2 (see class)
50 ClassDef(AliRsnPairDef, 1)