]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PMD/AliPMDdigit.cxx
Fixing wrong usage of bits
[u/mrichter/AliRoot.git] / PMD / AliPMDdigit.cxx
1 /***************************************************************************
2  * Copyright(c) 1998-1999, 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 //                                                     //
17 //  Date   : August 05 2003                            //
18 //                                                     //
19 //  Store digits for ALICE-PMD                         //
20 //                                                     //
21 //-----------------------------------------------------//
22 #include "Riostream.h"
23 #include "Rtypes.h"
24 #include "AliPMDdigit.h"
25 #include <stdio.h>
26
27 ClassImp(AliPMDdigit)
28
29 AliPMDdigit::AliPMDdigit():
30   fTrNumber(0),
31   fTrPid(0),
32   fDet(0),
33   fSMNumber(0),
34   fRow(0),
35   fColumn(0),
36   fADC(0.)
37 {
38   // Default Constructor
39 }
40
41 AliPMDdigit::AliPMDdigit(Int_t trnumber, Int_t trpid, Int_t det,
42                          Int_t smnumber, 
43                          Int_t irow, Int_t icol, Float_t adc):
44   fTrNumber(trnumber),
45   fTrPid(trpid),
46   fDet(det),
47   fSMNumber(smnumber),
48   fRow(irow),
49   fColumn(icol),
50   fADC(adc)
51 {
52   // Constructor
53 }
54 AliPMDdigit::AliPMDdigit(AliPMDdigit *pmddigit):
55   fTrNumber(0),
56   fTrPid(0),
57   fDet(0),
58   fSMNumber(0),
59   fRow(0),
60   fColumn(0),
61   fADC(0.)
62 {
63   *this = *pmddigit;
64 }
65
66 AliPMDdigit::AliPMDdigit(const AliPMDdigit& pmddigit):
67   TObject(pmddigit),
68   fTrNumber(pmddigit.fTrNumber),
69   fTrPid(pmddigit.fTrPid),
70   fDet(pmddigit.fDet),
71   fSMNumber(pmddigit.fSMNumber),
72   fRow(pmddigit.fRow),
73   fColumn(pmddigit.fColumn),
74   fADC(pmddigit.fADC)
75 {
76   //Copy Constructor 
77 }
78 AliPMDdigit & AliPMDdigit::operator=(const AliPMDdigit& pmddigit) {
79   //Assignment operator 
80   if(this != &pmddigit)
81     {
82       fTrNumber   = pmddigit.fTrNumber;
83       fTrPid      = pmddigit.fTrPid;
84       fDet        = pmddigit.fDet;
85       fSMNumber   = pmddigit.fSMNumber;
86       fRow        = pmddigit.fRow;
87       fColumn     = pmddigit.fColumn;
88       fADC        = pmddigit.fADC;
89     }
90   return *this;
91 }
92 AliPMDdigit::~AliPMDdigit()
93 {
94   // Default destructor
95 }
96 Int_t AliPMDdigit::GetTrackNumber() const
97 {
98   return fTrNumber;
99 }
100 Int_t AliPMDdigit::GetTrackPid() const
101 {
102   return fTrPid;
103 }
104 Int_t AliPMDdigit::GetDetector() const
105 {
106   return fDet;
107 }
108 Int_t AliPMDdigit::GetSMNumber() const
109 {
110   return fSMNumber;
111 }
112 Int_t AliPMDdigit::GetRow() const
113 {
114   return fRow;
115 }
116 Int_t AliPMDdigit::GetColumn() const
117 {
118   return fColumn;
119 }
120 Float_t AliPMDdigit::GetADC() const
121 {
122   return fADC;
123 }
124