ROOT logo
//*-- Author : Manuel Sanchez, Santiago
//*-- Modified : 22/11/2000 by Romain Holzmann
//*-- Copyright : GSI, Darmstadt
//
//***************************************************************************
//
//  HGeantEmc
// 
//  GEANT EMC hit data
//
//  This class stores the GEANT hits in the EMC detector,
//  per sector, cell. Cell is one crystal
//
//****************************************************************************
//
// Inline functions:
//
//  inline void setAddress(Char_t s, Char_t m, Char_t c)
//                                        set sector, module, and cell numbers
//  inline void setTrack(Int_t track)     set GEANT track number
//  inline Int_t getTrack()               return GEANT track number
//  inline Char_t getSector(void)         return sector number
//  inline Char_t getCell(void)           return crystal number
//
#include "hgeantemc.h"

ClassImp(HGeantEmc)

HGeantEmc::HGeantEmc(void) {
  // Default constructor.
  trackNumber = 0;
  trackLength = 0.F;
  peHit  = 0.F;
  xHit   = 0.F;
  yHit   = 0.F;
  zHit   = 0.F;
  tofHit = 0.F;
  momHit = 0.F;
  sector = -1;
  cell   = 0;
}
/*
HGeantEmc::HGeantEmc(HGeantEmc &aEmc) {
  // Copy constructor.
  trackNumber = aEmc.trackNumber;
  trackLength = aEmc.trackLength;
  peHit = aEmc.peHit;
  xHit = aEmc.xHit;
  yHit = aEmc.yHit;
  zHit = aEmc.zHit;
  tofHit = aEmc.tofHit;
  momHit = aEmc.momHit;
  sector = aEmc.sector;
  cell   = aEmc.cell;
}
*/
void HGeantEmc::setHit(Float_t ae, Float_t ax, Float_t ay, Float_t az, 
                       Float_t atof, Float_t amom, Float_t alen) {
  // Set hit data (energy loss, y,x in cell system, time of flight, momentum and track length).
  peHit       = ae;
  xHit        = ax;
  yHit        = ay;
  zHit        = az;
  tofHit      = atof;
  momHit      = amom;
  trackLength = alen;
}

void HGeantEmc::getHit(Float_t& ae, Float_t& ax,  Float_t& ay, Float_t& az,
                       Float_t& atof, Float_t& amom, Float_t& alen) {
  // Retrieve hit data (energy loss, y,x in cell system, time of flight, momentum and track length).
  ae   = peHit;
  ax   = xHit;
  ay   = yHit;
  az   = zHit;
  atof = tofHit;
  amom = momHit;
  alen = trackLength;
}
 hgeantemc.cc:1
 hgeantemc.cc:2
 hgeantemc.cc:3
 hgeantemc.cc:4
 hgeantemc.cc:5
 hgeantemc.cc:6
 hgeantemc.cc:7
 hgeantemc.cc:8
 hgeantemc.cc:9
 hgeantemc.cc:10
 hgeantemc.cc:11
 hgeantemc.cc:12
 hgeantemc.cc:13
 hgeantemc.cc:14
 hgeantemc.cc:15
 hgeantemc.cc:16
 hgeantemc.cc:17
 hgeantemc.cc:18
 hgeantemc.cc:19
 hgeantemc.cc:20
 hgeantemc.cc:21
 hgeantemc.cc:22
 hgeantemc.cc:23
 hgeantemc.cc:24
 hgeantemc.cc:25
 hgeantemc.cc:26
 hgeantemc.cc:27
 hgeantemc.cc:28
 hgeantemc.cc:29
 hgeantemc.cc:30
 hgeantemc.cc:31
 hgeantemc.cc:32
 hgeantemc.cc:33
 hgeantemc.cc:34
 hgeantemc.cc:35
 hgeantemc.cc:36
 hgeantemc.cc:37
 hgeantemc.cc:38
 hgeantemc.cc:39
 hgeantemc.cc:40
 hgeantemc.cc:41
 hgeantemc.cc:42
 hgeantemc.cc:43
 hgeantemc.cc:44
 hgeantemc.cc:45
 hgeantemc.cc:46
 hgeantemc.cc:47
 hgeantemc.cc:48
 hgeantemc.cc:49
 hgeantemc.cc:50
 hgeantemc.cc:51
 hgeantemc.cc:52
 hgeantemc.cc:53
 hgeantemc.cc:54
 hgeantemc.cc:55
 hgeantemc.cc:56
 hgeantemc.cc:57
 hgeantemc.cc:58
 hgeantemc.cc:59
 hgeantemc.cc:60
 hgeantemc.cc:61
 hgeantemc.cc:62
 hgeantemc.cc:63
 hgeantemc.cc:64
 hgeantemc.cc:65
 hgeantemc.cc:66
 hgeantemc.cc:67
 hgeantemc.cc:68
 hgeantemc.cc:69
 hgeantemc.cc:70
 hgeantemc.cc:71
 hgeantemc.cc:72
 hgeantemc.cc:73
 hgeantemc.cc:74
 hgeantemc.cc:75
 hgeantemc.cc:76
 hgeantemc.cc:77
 hgeantemc.cc:78
 hgeantemc.cc:79