]> git.uio.no Git - u/mrichter/AliRoot.git/blob - T0/AliT0LookUpValue.cxx
coding violation fixes
[u/mrichter/AliRoot.git] / T0 / AliT0LookUpValue.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 #include "AliT0LookUpValue.h"
16 #include "iostream.h"
17
18 ClassImp(AliT0LookUpValue)
19
20   AliT0LookUpValue:: AliT0LookUpValue(): TObject(),
21                                      fTRM(-1),
22                                      fTDC(-1),
23                                      fChain(-1),
24                                      fChannel(-1)
25
26
27 {
28
29   ///
30 }
31 //--------------------------------------------------------------------------------------
32  AliT0LookUpValue:: AliT0LookUpValue(Int_t trm, Int_t tdc, Int_t chain, Int_t channel) : TObject(),
33   fTRM(trm),
34   fTDC(tdc),
35   fChain(chain),
36   fChannel(channel)
37 {
38
39 //--------------------------------------------------------------------------------------
40  
41 }
42  Bool_t AliT0LookUpValue:: IsEqual(const TObject* obj) const
43 {
44      AliT0LookUpValue *b = ( AliT0LookUpValue*)obj;
45      if ( b->GetTRM() == fTRM && 
46           b->GetTDC() == fTDC && 
47           b->GetChain() == fChain &&
48           b->GetChannel() == fChannel  ) return kTRUE;
49      else return kFALSE;
50 }
51
52 //------------------------------------------------------------------------------------ 
53 void AliT0LookUpValue::Print(Option_t *) const
54 {
55   printf("AliT0LookUpValue TRM %i, TDC %i, chain %i channel %i\n",fTRM,fTDC,fChain,fChannel);
56 }
57 //--------------------------------------------------------------------------------------
58
59 ClassImp(AliT0LookUpKey)
60
61  AliT0LookUpKey::AliT0LookUpKey():
62    TObject(),
63    fKey(0),
64    fName("")
65  {
66  
67  }
68
69 //--------------------------------------------------------------------------------------
70  AliT0LookUpKey::AliT0LookUpKey(Int_t key):
71    TObject(),
72    fKey(key),
73    fName("")
74  {
75  
76  }
77
78 //--------------------------------------------------------------------------------------
79  AliT0LookUpKey::AliT0LookUpKey(TString name):
80    TObject(),
81    fKey(),
82    fName(name)
83  {
84  
85  }
86 //--------------------------------------------------------------------------------------
87
88 Bool_t AliT0LookUpKey:: IsEqual(const TObject* obj) const
89 {
90   Int_t k;
91 //  printf("IsEqual\n");
92     k=((AliT0LookUpKey*)obj)->GetKey();
93     if (k==fKey) return kTRUE; else return kFALSE;
94 }
95 //--------------------------------------------------------------------------------------
96 void AliT0LookUpKey::Print(Option_t *) const
97 {
98   printf(" AliT0LookUpKey key %i name %s\n",fKey,fName.Data());
99
100 }