1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
18 Revision 1.4 2006/11/29 16:08:01 hristov
21 Revision 1.3 2006/11/29 09:53:27 hristov
24 Revision 1.2 2006/11/06 14:24:21 jgrosseo
25 reading of run parameters from the logbook
26 online offline naming conversion
28 Revision 1.1 2006/06/02 14:14:36 hristov
29 Separate library for CDB (Jan)
31 Revision 1.2 2006/03/07 07:52:34 hristov
32 New version (B.Yordanov)
34 Revision 1.3 2005/11/17 17:47:34 byordano
35 TList changed to TObjArray
37 Revision 1.2 2005/11/17 14:43:22 byordano
40 Revision 1.1.1.1 2005/10/28 07:33:58 hristov
41 Initial import as subdirectory in AliRoot
43 Revision 1.1.1.1 2005/09/12 22:11:40 byordano
46 Revision 1.2 2005/08/29 21:15:47 byordano
52 // abstract interface class to AliShuttle
53 // This class is implemented by AliTestShuttle for testing and
54 // by AliShuttle for the full setup
57 #include "AliShuttleInterface.h"
61 ClassImp(AliShuttleInterface)
63 const char* AliShuttleInterface::fkSystemNames[3] = { "DAQ", "DCS", "HLT" };
65 // names of the detectors preprocessors
66 const char* AliShuttleInterface::fgkDetName[kNDetectors] = {"SPD", "SDD", "SSD", "TPC", "TRD", "TOF",
67 "PHS", "CPV", "HMP", "EMC", "MCH", "MTR", "FMD", "ZDC", "PMD", "T00", "V00", "GRP"};
69 // names of the detectors in OCDB
70 const char* AliShuttleInterface::fgkOfflineDetName[kNDetectors] = {"ITS", "ITS", "ITS", "TPC", "TRD", "TOF",
71 "PHOS", "PHOS", "HMPID", "EMCAL", "MUON", "MUON", "FMD", "ZDC", "PMD", "T0", "VZERO", "GRP"};
73 //______________________________________________________________________________________________
74 const char* AliShuttleInterface::GetOfflineDetName(const char* detName){
75 // Return "offline" detector name
77 Int_t detPos = GetDetPos(detName);
79 AliErrorClass(Form("Unknown detector: %s",detName));
83 return fgkOfflineDetName[detPos];
86 //______________________________________________________________________________________________
87 const char* AliShuttleInterface::GetDetName(UInt_t detPos){
88 // Return detector code
90 if(detPos >= kNDetectors) {
91 AliErrorClass(Form("Parameter out of bound: %d", detPos));
95 return fgkDetName[detPos];
98 //______________________________________________________________________________________________
99 const Int_t AliShuttleInterface::GetDetPos(const char* detName){
100 // Return detector position in the detector code array
102 for(UInt_t iDet=0; iDet < kNDetectors; iDet++){
103 if(!strcmp(fgkDetName[iDet], detName)) return iDet;