]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HBTAN/AliHBTPair.cxx
Replacing array of objects by array of pointers
[u/mrichter/AliRoot.git] / HBTAN / AliHBTPair.cxx
1 #include "AliHBTPair.h"
2 //_________________________________________________________________________
3 ///////////////////////////////////////////////////////////////////////////
4 //
5 // class AliHBTPair
6 //
7 // class implements pair of particles and taking care of caluclation (almost)
8 // all of pair properties (Qinv, InvMass,...)
9 // 
10 // more info: http://aliweb.cern.ch/people/skowron/analyzer/index.html
11 //
12 ////////////////////////////////////////////////////////////////////////////
13
14 #include "AliVAODParticle.h"
15 #include "AliHBTWeights.h"
16
17 ClassImp(AliHBTPair)
18
19 /************************************************************************/
20 AliHBTPair::AliHBTPair(Bool_t rev):
21  AliAODPair(rev),
22  fWeight(0.0),
23  fWeightNotCalc(kTRUE)
24  {
25 //Constructor
26   
27  }
28 /************************************************************************/
29
30 AliHBTPair::AliHBTPair(AliVAODParticle* part1, AliVAODParticle* part2, Bool_t rev):
31  AliAODPair(part1,part2,rev),
32  fWeight(0.0),
33  fWeightNotCalc(kTRUE)
34  {
35 //constructor
36   
37  }
38 /************************************************************************/
39 AliHBTPair::AliHBTPair(const AliHBTPair& in):
40  AliAODPair(in),
41  fWeight(in.fWeight),
42  fWeightNotCalc(in.fWeightNotCalc)
43 {
44  //cpy constructor
45 }
46 /************************************************************************/
47
48 AliHBTPair& AliHBTPair::operator=(const AliHBTPair& in)
49 {
50  //Assigment operator
51  in.Copy(*this);
52  return *this;
53 }
54 /************************************************************************/
55
56 Double_t AliHBTPair::GetWeight()
57 {
58   //returns and buffers weight for this pair
59   if (fWeightNotCalc)
60    {
61       fWeight = AliHBTWeights::Weight(this);
62       fWeightNotCalc = kFALSE;  
63    }
64   return fWeight; 
65 }
66 /************************************************************************/