AliPhysics  1811c8f (1811c8f)
ConfigureAndGetEventTriggerMaskAndCaloTriggerString.C
Go to the documentation of this file.
1 
15 #if !defined(__CINT__) || defined(__MAKECINT__)
16 
17 #include <TString.h>
18 
19 #include "AliVEvent.h"
20 
21 #endif
22 
32 (TString trigger, Int_t year, TString & triggerString)
33 {
34  //printf("ConfigureAndGetEventTriggerCaloTrackCorr - Set event trigger class for %s in year %d\n",
35  // trigger.Data(),year);
36 
37  triggerString = "";
38 
39  if( trigger.Contains("INT") || trigger.Contains("MB") || trigger.Contains("default") )
40  {
41  return ( AliVEvent::kINT7 | AliVEvent::kMB );
42  }
43  else if(trigger.Contains("EMCAL_L0"))
44  {
45  triggerString = "EMC";
46  return ( AliVEvent::kEMC7 | AliVEvent::kEMC8 | AliVEvent::kEMC1 );
47  }
48  else if(trigger.Contains("DCAL_L0"))
49  {
50  triggerString = "DMC";
51  return ( AliVEvent::kEMC7 | AliVEvent::kEMC8 | AliVEvent::kEMC1 );
52  }
53  else if(trigger.Contains("EMCAL_L1"))
54  {
55  if(year > 2012) triggerString = "EG1";
56  // before 2013 only one kind of L1 trigger
57 
58  return ( AliVEvent::kEMCEGA );
59  }
60  else if(trigger.Contains("DCAL_L1"))
61  {
62  triggerString = "DG1";
63  return ( AliVEvent::kEMCEGA );
64  }
65  else if(trigger.Contains("EMCAL_L2"))
66  {
67  triggerString = "EG2";
68  return ( AliVEvent::kEMCEGA );
69  }
70  else if(trigger.Contains("DCAL_L2"))
71  {
72  triggerString = "DG2";
73  return ( AliVEvent::kEMCEGA );
74  }
75 
76  return 0;
77 }
78 
int Int_t
Definition: External.C:63
unsigned int UInt_t
Definition: External.C:33
UInt_t ConfigureAndGetEventTriggerMaskAndCaloTriggerString(TString trigger, Int_t year, TString &triggerString)