]>
Commit | Line | Data |
---|---|---|
1 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
2 | * See cxx source for full Copyright notice */ | |
3 | ||
4 | // $Id$ | |
5 | // $MpId: AliMpCathodType.h,v 1.8 2006/05/24 13:58:07 ivana Exp $ | |
6 | ||
7 | // \ingroup basic | |
8 | // \enum AliMpCathodType | |
9 | // Enumeration for refering to cath0 and cath1. | |
10 | // | |
11 | // \author Ivana Hrivnacova; IPN Orsay | |
12 | ||
13 | #include "AliMpCathodType.h" | |
14 | ||
15 | #include "AliLog.h" | |
16 | ||
17 | //_____________________________________________________________________________ | |
18 | AliMp::CathodType AliMp::GetCathodType(Int_t cathodNumber) | |
19 | { | |
20 | switch ( cathodNumber ) { | |
21 | case kCath0: return kCath0; break; | |
22 | case kCath1: return kCath1; break; | |
23 | default: | |
24 | // Should reach this line | |
25 | AliErrorGeneral("AliMpCathodType.h", "Wrong cathod number"); | |
26 | return kCath0; | |
27 | } | |
28 | ||
29 | // Should reach this line | |
30 | AliErrorGeneral("AliMpCathodType.h", "Wrong cathod number"); | |
31 | return kCath0; | |
32 | } | |
33 | ||
34 | //_____________________________________________________________________________ | |
35 | TString AliMp::CathodTypeName(AliMp::CathodType cathodType) | |
36 | { | |
37 | switch ( cathodType ) { | |
38 | case kCath0: return "cath0"; break; | |
39 | case kCath1: return "cath1"; break; | |
40 | } | |
41 | ||
42 | // Cannot reach this line | |
43 | AliFatalGeneral("AliMpCathodType.h", "Unknown cathod type"); | |
44 | return "invalidCathod"; | |
45 | } | |
46 | ||
47 | //_____________________________________________________________________________ | |
48 | AliMp::CathodType AliMp::OtherCathodType(AliMp::CathodType cathodType) | |
49 | { | |
50 | switch ( cathodType ) { | |
51 | case kCath0: return kCath1; break; | |
52 | case kCath1: return kCath0; break; | |
53 | } | |
54 | ||
55 | // Cannot reach this line | |
56 | AliFatalGeneral("AliMpCathodType.h", "Unknown cathod type"); | |
57 | return kCath0; | |
58 | } |