]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
- All mapping enums within namespace (AliMp).
authorivana <ivana@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 25 Jan 2007 17:01:24 +0000 (17:01 +0000)
committerivana <ivana@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 25 Jan 2007 17:01:24 +0000 (17:01 +0000)
- Implementation of functions moved in .cxx.

MUON/mapping/AliMpPlaneType.h
MUON/mapping/AliMpStationType.h

index 974efc92fec48eac85cddb4321996ced9e7f8435..cbd243a993f1d0081991813506b1b78c7c237205 100755 (executable)
 #ifndef ALI_MP_PLANE_TYPE_H
 #define ALI_MP_PLANE_TYPE_H
 
-#include "AliLog.h"
 #include <TString.h>
 
-enum AliMpPlaneType
-{
-  kBendingPlane,    ///< bending plane
-  kNonBendingPlane  ///< non-bending plane
-};
-
-inline 
-TString PlaneTypeName(AliMpPlaneType planeType)
-{
-  switch ( planeType ) {
-    case kBendingPlane:    return "bp";  break;
-    case kNonBendingPlane: return "nbp"; break;
-  }
-  
-  // Cannot reach this line
-  AliFatalGeneral("AliMpPlaneType.h", "Unknown plane type"); 
-  return "invalidPlane";
-}       
+namespace AliMp {
+
+  enum PlaneType
+  {
+    kBendingPlane,    ///< bending plane
+    kNonBendingPlane  ///< non-bending plane
+  };
+
+  /// Return name for given planeType
+  TString PlaneTypeName(AliMp::PlaneType planeType);
+
+
+  /// Return the other plane type
+  AliMp::PlaneType OtherPlaneType(AliMp::PlaneType planeType);
+}  
 
 #endif //ALI_MP_PLANE_TYPE_H
index e505b78507217dd4dd45e636a5609c9b9ae15597..c6e15b6aaf691901925c89d848c3190b2695bded 100644 (file)
 #ifndef ALI_MP_STATION_TYPE_H
 #define ALI_MP_STATION_TYPE_H
 
-#include "AliLog.h"
 #include <TString.h>
 
-enum AliMpStationType
-{
-  kStation1,           ///< station 1 (quadrants)
-  kStation2,           ///< station 2 (quadrants)
-  kStation345,         ///< station 3,4,5 (slats)
-  kStationTrigger      ///< trigger stations (slats)
-};
+namespace AliMp {
+
+  enum StationType
+  {
+    kStation1,           ///< station 1 (quadrants)
+    kStation2,           ///< station 2 (quadrants)
+    kStation345,         ///< station 3,4,5 (slats)
+    kStationTrigger      ///< trigger stations (slats)
+  };
 
-inline 
-TString StationTypeName(AliMpStationType stationType)
-{
-  switch ( stationType ) {
-    case kStation1:       return "st1";     break;
-    case kStation2:       return "st2";     break;
-    case kStation345:     return "slat";    break;
-    case kStationTrigger: return "trigger"; break;
-  }
-  
-  // Cannot reach this line
-  AliFatalGeneral("AliMpStationType.h", "Unknown station type"); 
-  return "invalidStation";
+  /// Return name for given stationType
+  TString StationTypeName(AliMp::StationType stationType);
 }
 
 #endif //ALI_MP_STATION_TYPE_H