]>
Commit | Line | Data |
---|---|---|
56b1929b | 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 | **************************************************************************/ | |
56b1929b | 15 | /* $Id$ */ |
c2fc1258 | 16 | /** @file AliFMDRecPoint.cxx |
17 | @author Christian Holm Christensen <cholm@nbi.dk> | |
18 | @date Mon Mar 27 12:46:26 2006 | |
19 | @brief Pseudo reconstructed charged particle multiplicity | |
20 | */ | |
56b1929b | 21 | //____________________________________________________________________ |
22 | // | |
bf000c32 | 23 | // Base class for reconstructed charged particle multiplicty in the |
24 | // FMD. | |
25 | // The class contains the field fMethod which is a flag set by | |
26 | // the AliFMDRecPointAlgorithm that created the object. The flag tells us | |
27 | // which algorithm was used to create the data stored in the object. | |
7684b53c | 28 | // |
bf000c32 | 29 | #include "AliFMDRecPoint.h" // ALIFMDRECPOINT_H |
30 | #include <TString.h> // ROOT_TString | |
56b1929b | 31 | #include <Riostream.h> // ROOT_Riostream |
32 | ||
33 | //____________________________________________________________________ | |
bf000c32 | 34 | ClassImp(AliFMDRecPoint) |
1a1fdef7 | 35 | #if 0 |
36 | ; // This is here to keep Emacs for indenting the next line | |
37 | #endif | |
56b1929b | 38 | |
56b1929b | 39 | //____________________________________________________________________ |
bf000c32 | 40 | AliFMDRecPoint::AliFMDRecPoint() |
56b1929b | 41 | : fDetector(0), |
42 | fRing('\0'), | |
43 | fSector(0), | |
44 | fStrip(0), | |
45 | fEta(0), | |
46 | fPhi(0), | |
47 | fEdep(0) | |
02a27b50 | 48 | { |
49 | // CTOR | |
50 | } | |
56b1929b | 51 | |
52 | //____________________________________________________________________ | |
bf000c32 | 53 | AliFMDRecPoint::AliFMDRecPoint(UShort_t detector, Char_t ring, |
54 | UShort_t sector, UShort_t strip, | |
55 | Float_t eta, Float_t phi, | |
56 | Float_t edep, Float_t particles) | |
57 | : fDetector(detector), | |
56b1929b | 58 | fRing(ring), |
59 | fSector(sector), | |
60 | fStrip(strip), | |
61 | fEta(eta), | |
62 | fPhi(phi), | |
bf000c32 | 63 | fEdep(edep), |
64 | fParticles(particles) | |
65 | { | |
66 | } | |
56b1929b | 67 | |
bf000c32 | 68 | //____________________________________________________________________ |
69 | const char* | |
70 | AliFMDRecPoint::GetName() const | |
71 | { | |
02a27b50 | 72 | // Get the name |
bf000c32 | 73 | static TString n; |
74 | n = Form("FMD%d%c[%2d,%3d]", fDetector,fRing,fSector,fStrip); | |
75 | return n.Data(); | |
76 | } | |
77 | ||
78 | //____________________________________________________________________ | |
79 | const char* | |
80 | AliFMDRecPoint::GetTitle() const | |
81 | { | |
02a27b50 | 82 | // Get the title |
bf000c32 | 83 | static TString t; |
84 | t = Form("%f (%f,%f)", fParticles, fEta, fPhi); | |
85 | return t.Data(); | |
86 | } | |
56b1929b | 87 | |
88 | //____________________________________________________________________ | |
89 | void | |
bf000c32 | 90 | AliFMDRecPoint::Print(Option_t* option) const |
56b1929b | 91 | { |
92 | // Print information | |
93 | // | |
94 | // Options: | |
95 | // D: Detector (default) | |
96 | // E: Eta range (default) | |
97 | // P: Phi range (default) | |
98 | // | |
99 | TString opt(option); | |
bf000c32 | 100 | cout << "FMD RecPoint in a strip: " << fParticles << endl; |
56b1929b | 101 | if (opt.Contains("D", TString::kIgnoreCase)) |
102 | cout << " Detector: FMD" << fDetector << fRing | |
103 | << "[" << fSector << "," << fStrip << "]" << endl; | |
104 | if (opt.Contains("E", TString::kIgnoreCase)) | |
105 | cout << " Eta range: " << fEta << endl; | |
106 | if (opt.Contains("P", TString::kIgnoreCase)) | |
107 | cout << " Phi range: " << fPhi << endl; | |
56b1929b | 108 | } |
109 | ||
110 | ||
111 | //____________________________________________________________________ | |
112 | // | |
113 | // EOF | |
114 | // |