]> git.uio.no Git - u/mrichter/AliRoot.git/blob - FMD/AliFMDMult.cxx
Added docs and fixed a bug
[u/mrichter/AliRoot.git] / FMD / AliFMDMult.cxx
1 /**************************************************************************
2  * Copyright(c) 2004, ALICE Experiment at CERN, All rights reserved. *
3  *                                                                        *
4  * Author: The ALICE Off-line Project.                                    *
5  * Contributors are mentioned in the code where appropriate.              *
6  *                                                                        *
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  **************************************************************************/
15
16 /* $Id$ */
17
18 //____________________________________________________________________
19 //
20 // Base class for reconstructed charged particle multiplicty in the
21 // FMD.  The class contains the field fMethod which is a flag set by
22 // the AliFMDMultAlgorithm that created the object. The flag tells us
23 // which algorithm was used to create the data stored in the object. 
24 //
25 #include "AliFMDMult.h"         // ALIFMDMULT_H
26 #include <TString.h>            // ROOT_TString 
27 #include <Riostream.h>          // ROOT_Riostream
28
29 //____________________________________________________________________
30 ClassImp(AliFMDMult);
31
32 //____________________________________________________________________
33 AliFMDMult::AliFMDMult(Float_t  particles, UShort_t method)
34   : fParticles(particles),
35     fMethod(method)
36 {
37   // Constructor
38   switch (fMethod) {
39   case kPoission: 
40   case kIterative: 
41   case kNaiive:    
42     break;    
43   default:        
44     Warning("AliFMDMult", "unknown method: %d", method);
45     break;
46   }
47 }
48
49
50 //____________________________________________________________________
51 void
52 AliFMDMult::Print(Option_t* option) const
53 {
54   // Print information 
55   //
56   // Options:
57   //
58   //    V      Be verbose
59   // 
60   TString opt(option);
61   if (!opt.Contains("v", TString::kIgnoreCase)) return;
62   cout << "  Method:        " << flush;
63   switch (fMethod) {
64   case kPoission:  cout << "Poission"  << endl; break;
65   case kIterative: cout << "Iterative" << endl; break;
66   case kNaiive:    cout << "Naive"     << endl; break; 
67   default:         cout << "Unknown"   << endl; break;
68   }
69 }
70
71     
72 //____________________________________________________________________
73 //
74 // EOF
75 //