<commit_before>// -*- mode: C++ -*- 
#ifndef ALIVEVENT_H
#define ALIVEVENT_H
/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
 * See cxx source for full Copyright notice                               */


/* $Id$ */

//-------------------------------------------------------------------------
//                          Class AliVEvent
//      
// Origin: <NAME>, CERN, <EMAIL> 
//-------------------------------------------------------------------------

#include <TObject.h>
#include <TTree.h>
#include <TGeoMatrix.h>
#include "AliVHeader.h"
#include "AliVParticle.h"
#include "AliVVertex.h"
#include "AliVCluster.h"
#include "AliVCaloCells.h"
#include "AliVCaloTrigger.h"
#include "TRefArray.h"
#include "AliTOFHeader.h"
#include "AliVTrdTrack.h"
#include "AliVMultiplicity.h"
class AliVfriendEvent;
class AliCentrality;
class AliEventplane;
class AliVVZERO;
class AliVZDC;
class AliVMFT;   // AU
class AliESDkink;
class AliESDv0;
class AliESDVertex;
class AliESDVZERO;
class AliMultiplicity;
class AliVTrack;
class AliVAD;

class AliVEvent : public TObject {

public:
  enum EDataLayoutType { kESD, kMC, kAOD, kMixed, kFlat };
  enum EOfflineTriggerTypes { 
      kMB                = BIT( 0), // Minimum bias trigger, i.e. interaction trigger, offline SPD or V0 selection
      kINT1              = BIT( 0), // V0A | V0C | SPD minimum bias trigger
      kINT7              = BIT( 1), // V0AND trigger, offline V0 selection
      kMUON              = BIT( 2), // Muon trigger, offline SPD or V0 selection
      kHighMult          = BIT( 3), // High-multiplicity trigger (threshold defined online), offline SPD or V0 selection
      kEMC1              = BIT( 4), // EMCAL trigger
      kCINT5             = BIT( 5), // V0OR minimum bias trigger
      kINT5              = BIT( 5), // V0OR minimum bias trigger      
      kCMUS5             = BIT( 6), // Muon trigger, offline V0 selection
      kMUSPB             = BIT( 6), // idem for PbPb
      kMuonSingleHighPt7 = BIT( 7), // Muon trigger : single muon high pt, CINT7 suite
      kMUSH7             = BIT( 7), // Muon trigger : single muon high pt, CINT7 suite
      kMUSHPB            = BIT( 7), // idem for PbPb
      kMuonLikeLowPt7    = BIT( 8), // Muon trigger : like sign muon low pt, CINT7 suite
      kMUL7              = BIT( 8), // Muon trigger : like sign muon low pt, CINT7 suite
      kMuonLikePB        = BIT( 8), // idem for PbPb
      kMuonUnlikeLowPt7  = BIT( 9), // Muon trigger : unlike sign muon low pt, CINT7 suite
      kMUU7              = BIT( 9), // Muon trigger : unlike sign muon low pt, CINT7 suite
      kMuonUnlikePB      = BIT( 9), // idem for PbPb
      kEMC7              = BIT(10), // EMCAL trigger, CINT7 suite
      kEMC8              = BIT(10), // EMCAL trigger, CINT8 suite
      kMUS7              = BIT(11), // Muon trigger : single muon low pt, CINT7 suite
      kMuonSingleLowPt7  = BIT(11), // Muon trigger : single muon low pt, CINT7 suite
      kPHI1              = BIT(12), // PHOS trigger, CINT1 suite
      kPHI7              = BIT(13), // PHOS trigger, CINT7 suite
      kPHI8              = BIT(13), // PHOS trigger, CINT8 suite
      kPHOSPb            = BIT(13), // idem for PbPb
      kEMCEJE            = BIT(14), // EMCAL jet patch trigger
      kEMCEGA            = BIT(15), // EMCAL gamma trigger
      kCentral           = BIT(16), // PbPb central collision trigger
      kSemiCentral       = BIT(17), // PbPb semicentral collision trigger
      kDG5               = BIT(18), // Double gap diffractive
      kZED               = BIT(19), // ZDC electromagnetic dissociation
      kSPI7              = BIT(20), // Power interaction trigger
      kSPI               = BIT(20), // Power interaction trigger
      kINT8              = BIT(21), // CINT8 trigger: 0TVX (T0 vertex) trigger
      kMuonSingleLowPt8  = BIT(22), // Muon trigger : single muon, low pt, T0 selection, CINT8 suite
      kMuonSingleHighPt8 = BIT(23), // Muon trigger : single muon, high pt, T0 selection, CINT8 suite
      kMuonLikeLowPt8    = BIT(24), // Muon trigger : like sign muon, low pt, T0 selection, CINT8 suite
      kMuonUnlikeLowPt8  = BIT(25), // Muon trigger : unlike sign muon, low pt, T0 selection, CINT8 suite
      kMuonUnlikeLowPt0  = BIT(26), // Muon trigger : unlike sign muon, low pt, no additional L0 requirement
      kUserDefined       = BIT(27), // Set when custom trigger classes are set in AliPhysicsSelection, offline SPD or V0 selection
      kTRD               = BIT(28), // TRD trigger
      // Bits 29 and above are reserved for FLAGS
      kFastOnly          = BIT(30), // The fast cluster fired. This bit is set in to addition another trigger bit, e.g. kMB
      kAny               = 0xffffffff, // to accept any trigger
      kAnyINT            = kMB | kINT7 | kINT5 | kINT8 | kSPI7 // to accept any interaction (aka minimum bias) trigger
  };

  AliVEvent() { }
  virtual ~AliVEvent() { } 
  AliVEvent(const AliVEvent& vEvnt); 
  AliVEvent& operator=(const AliVEvent& vEvnt);

  // Services
  virtual void AddObject(TObject* obj) = 0;
  virtual TObject* FindListObject(const char *name) const = 0;
  virtual TList* GetList() const = 0;

  virtual void CreateStdContent() = 0;
  virtual void GetStdContent() = 0;

  virtual void ReadFromTree(TTree *tree, Option_t* opt) = 0;
  virtual void WriteToTree(TTree* tree) const = 0;

  virtual void Reset() = 0;
  //virtual void ResetStdContent() = 0;
  virtual void SetStdNames() = 0;

  virtual void Print(Option_t *option="") const = 0;

  // Header
  virtual AliVHeader* GetHeader() const = 0;
  //
  // field initialization
  virtual Bool_t InitMagneticField() const {return kFALSE;}

  // Delegated methods for fESDRun or AODHeader
  
  virtual void     SetRunNumber(Int_t n) = 0;
  virtual void     SetPeriodNumber(UInt_t n) = 0;
  virtual void     SetMagneticField(Double_t mf) = 0;
  
  virtual Int_t    GetRunNumber() const = 0;
  virtual UInt_t   GetPeriodNumber() const = 0;
  virtual Double_t GetMagneticField() const = 0;

  virtual Double_t GetDiamondX() const {return -999.;}
  virtual Double_t GetDiamondY() const {return -999.;}
  virtual void     GetDiamondCovXY(Float_t cov[3]) const
             {cov[0]=-999.; return;}

  // Delegated methods for fHeader
  virtual void      SetOrbitNumber(UInt_t n) = 0;
  virtual void      SetBunchCrossNumber(UShort_t n) = 0;
  virtual void      SetEventType(UInt_t eventType)= 0;
  virtual void      SetTriggerMask(ULong64_t n) = 0;
  virtual void      SetTriggerCluster(UChar_t n) = 0;

  virtual UInt_t    GetOrbitNumber() const = 0;
  virtual UShort_t  GetBunchCrossNumber() const = 0;
  virtual UInt_t    GetEventType()  const = 0;
  virtual ULong64_t GetTriggerMask() const = 0;
  virtual UChar_t   GetTriggerCluster() const = 0;
  virtual TString   GetFiredTriggerClasses() const = 0;
  virtual Bool_t    IsTriggerClassFired(const char* /*name*/) const {return 0;}
  virtual Double_t  GetZDCN1Energy() const = 0;
  virtual Double_t  GetZDCP1Energy() const = 0;
  virtual Double_t  GetZDCN2Energy() const = 0;
  virtual Double_t  GetZDCP2Energy() const = 0;
  virtual Double_t  GetZDCEMEnergy(Int_t i) const = 0;
 
  // Tracks
  virtual AliVParticle *GetTrack(Int_t i) const = 0;
  virtual AliVTrack    *GetVTrack(Int_t /*i*/) const {return NULL;}
  //virtual AliVTrack    *GetVTrack(Int_t /*i*/) {return NULL;}
  //virtual Int_t        AddTrack(const AliVParticle *t) = 0;<commit_msg>Add virtual GetTriggerMaskNext50() to AliVEvent<commit_after>// -*- mode: C++ -*- 
#ifndef ALIVEVENT_H
#define ALIVEVENT_H
/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
 * See cxx source for full Copyright notice                               */


/* $Id$ */

//-------------------------------------------------------------------------
//                          Class AliVEvent
//      
// Origin: <NAME>, CERN, <EMAIL> 
//-------------------------------------------------------------------------

#include <TObject.h>
#include <TTree.h>
#include <TGeoMatrix.h>
#include "AliVHeader.h"
#include "AliVParticle.h"
#include "AliVVertex.h"
#include "AliVCluster.h"
#include "AliVCaloCells.h"
#include "AliVCaloTrigger.h"
#include "TRefArray.h"
#include "AliTOFHeader.h"
#include "AliVTrdTrack.h"
#include "AliVMultiplicity.h"
class AliVfriendEvent;
class AliCentrality;
class AliEventplane;
class AliVVZERO;
class AliVZDC;
class AliVMFT;   // AU
class AliESDkink;
class AliESDv0;
class AliESDVertex;
class AliESDVZERO;
class AliMultiplicity;
class AliVTrack;
class AliVAD;

class AliVEvent : public TObject {

public:
  enum EDataLayoutType { kESD, kMC, kAOD, kMixed, kFlat };
  enum EOfflineTriggerTypes { 
      kMB                = BIT( 0), // Minimum bias trigger, i.e. interaction trigger, offline SPD or V0 selection
      kINT1              = BIT( 0), // V0A | V0C | SPD minimum bias trigger
      kINT7              = BIT( 1), // V0AND trigger, offline V0 selection
      kMUON              = BIT( 2), // Muon trigger, offline SPD or V0 selection
      kHighMult          = BIT( 3), // High-multiplicity trigger (threshold defined online), offline SPD or V0 selection
      kEMC1              = BIT( 4), // EMCAL trigger
      kCINT5             = BIT( 5), // V0OR minimum bias trigger
      kINT5              = BIT( 5), // V0OR minimum bias trigger      
      kCMUS5             = BIT( 6), // Muon trigger, offline V0 selection
      kMUSPB             = BIT( 6), // idem for PbPb
      kMuonSingleHighPt7 = BIT( 7), // Muon trigger : single muon high pt, CINT7 suite
      kMUSH7             = BIT( 7), // Muon trigger : single muon high pt, CINT7 suite
      kMUSHPB            = BIT( 7), // idem for PbPb
      kMuonLikeLowPt7    = BIT( 8), // Muon trigger : like sign muon low pt, CINT7 suite
      kMUL7              = BIT( 8), // Muon trigger : like sign muon low pt, CINT7 suite
      kMuonLikePB        = BIT( 8), // idem for PbPb
      kMuonUnlikeLowPt7  = BIT( 9), // Muon trigger : unlike sign muon low pt, CINT7 suite
      kMUU7              = BIT( 9), // Muon trigger : unlike sign muon low pt, CINT7 suite
      kMuonUnlikePB      = BIT( 9), // idem for PbPb
      kEMC7              = BIT(10), // EMCAL trigger, CINT7 suite
      kEMC8              = BIT(10), // EMCAL trigger, CINT8 suite
      kMUS7              = BIT(11), // Muon trigger : single muon low pt, CINT7 suite
      kMuonSingleLowPt7  = BIT(11), // Muon trigger : single muon low pt, CINT7 suite
      kPHI1              = BIT(12), // PHOS trigger, CINT1 suite
      kPHI7              = BIT(13), // PHOS trigger, CINT7 suite
      kPHI8              = BIT(13), // PHOS trigger, CINT8 suite
      kPHOSPb            = BIT(13), // idem for PbPb
      kEMCEJE            = BIT(14), // EMCAL jet patch trigger
      kEMCEGA            = BIT(15), // EMCAL gamma trigger
      kCentral           = BIT(16), // PbPb central collision trigger
      kSemiCentral       = BIT(17), // PbPb semicentral collision trigger
      kDG5               = BIT(18), // Double gap diffractive
      kZED               = BIT(19), // ZDC electromagnetic dissociation
      kSPI7              = BIT(20), // Power interaction trigger
      kSPI               = BIT(20), // Power interaction trigger
      kINT8              = BIT(21), // CINT8 trigger: 0TVX (T0 vertex) trigger
      kMuonSingleLowPt8  = BIT(22), // Muon trigger : single muon, low pt, T0 selection, CINT8 suite
      kMuonSingleHighPt8 = BIT(23), // Muon trigger : single muon, high pt, T0 selection, CINT8 suite
      kMuonLikeLowPt8    = BIT(24), // Muon trigger : like sign muon, low pt, T0 selection, CINT8 suite
      kMuonUnlikeLowPt8  = BIT(25), // Muon trigger : unlike sign muon, low pt, T0 selection, CINT8 suite
      kMuonUnlikeLowPt0  = BIT(26), // Muon trigger : unlike sign muon, low pt, no additional L0 requirement
      kUserDefined       = BIT(27), // Set when custom trigger classes are set in AliPhysicsSelection, offline SPD or V0 selection
      kTRD               = BIT(28), // TRD trigger
      // Bits 29 and above are reserved for FLAGS
      kFastOnly          = BIT(30), // The fast cluster fired. This bit is set in to addition another trigger bit, e.g. kMB
      kAny               = 0xffffffff, // to accept any trigger
      kAnyINT            = kMB | kINT7 | kINT5 | kINT8 | kSPI7 // to accept any interaction (aka minimum bias) trigger
  };

  AliVEvent() { }
  virtual ~AliVEvent() { } 
  AliVEvent(const AliVEvent& vEvnt); 
  AliVEvent& operator=(const AliVEvent& vEvnt);

  // Services
  virtual void AddObject(TObject* obj) = 0;
  virtual TObject* FindListObject(const char *name) const = 0;
  virtual TList* GetList() const = 0;

  virtual void CreateStdContent() = 0;
  virtual void GetStdContent() = 0;

  virtual void ReadFromTree(TTree *tree, Option_t* opt) = 0;
  virtual void WriteToTree(TTree* tree) const = 0;

  virtual void Reset() = 0;
  //virtual void ResetStdContent() = 0;
  virtual void SetStdNames() = 0;

  virtual void Print(Option_t *option="") const = 0;

  // Header
  virtual AliVHeader* GetHeader() const = 0;
  //
  // field initialization
  virtual Bool_t InitMagneticField() const {return kFALSE;}

  // Delegated methods for fESDRun or AODHeader
  
  virtual void     SetRunNumber(Int_t n) = 0;
  virtual void     SetPeriodNumber(UInt_t n) = 0;
  virtual void     SetMagneticField(Double_t mf) = 0;
  
  virtual Int_t    GetRunNumber() const = 0;
  virtual UInt_t   GetPeriodNumber() const = 0;
  virtual Double_t GetMagneticField() const = 0;

  virtual Double_t GetDiamondX() const {return -999.;}
  virtual Double_t GetDiamondY() const {return -999.;}
  virtual void     GetDiamondCovXY(Float_t cov[3]) const
             {cov[0]=-999.; return;}

  // Delegated methods for fHeader
  virtual void      SetOrbitNumber(UInt_t n) = 0;
  virtual void      SetBunchCrossNumber(UShort_t n) = 0;
  virtual void      SetEventType(UInt_t eventType)= 0;
  virtual void      SetTriggerMask(ULong64_t n) = 0;
  virtual void      SetTriggerCluster(UChar_t n) = 0;

  virtual UInt_t    GetOrbitNumber() const = 0;
  virtual UShort_t  GetBunchCrossNumber() const = 0;
  virtual UInt_t    GetEventType()  const = 0;
  virtual ULong64_t GetTriggerMask() const = 0;
  virtual ULong64_t GetTriggerMaskNext50() const {return 0;}
  virtual UChar_t   GetTriggerCluster() const = 0;
  virtual TString   GetFiredTriggerClasses() const = 0;
  virtual Bool_t    IsTriggerClassFired(const char* /*name*/) const {return 0;}
  virtual Double_t  GetZDCN1Energy() const = 0;
  virtual Double_t  GetZDCP1Energy() const = 0;
  virtual Double_t  GetZDCN2Energy() const = 0;
  virtual Double_t  GetZDCP2Energy() const = 0;
  virtual Double_t  GetZDCEMEnergy(Int_t i) const = 0;
 
  // Tracks
  virtual AliVParticle *GetTrack(Int_t i) const = 0;
  virtual AliVTrack    *GetVTrack(Int_t /*i*/) const {return NULL;}
  //virtual AliVTrack    *GetVTrack(Int_t /*i*/) {return NULL;}
  //virtual Int_t        AddTrack(const AliVParticle *t) = 0;
{'fraction_non_alphanumeric': 0.11756459042659724, 'fraction_numerical': 0.027705454302690433, 'mean_word_length': 2.26432774024842, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 2, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6509827', 'n_tokens_mistral': 5099, 'n_tokens_neox': 4743, 'n_words': 1533}