CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Private Attributes
CaloG4Hit Class Reference

#include <CaloG4Hit.h>

Inheritance diagram for CaloG4Hit:

Public Member Functions

void addEnergyDeposit (double em, double hd)
 
void addEnergyDeposit (const CaloG4Hit &aHit)
 
 CaloG4Hit ()
 
 CaloG4Hit (const CaloG4Hit &right)
 
void Draw () override
 
uint16_t getDepth () const
 
double getEM () const
 
double getEnergyDeposit () const
 
math::XYZPoint getEntry () const
 
math::XYZPoint getEntryLocal () const
 
double getHadr () const
 
CaloHitID getID () const
 
double getIncidentEnergy () const
 
math::XYZPoint getPosition () const
 
double getTimeSlice () const
 
int getTimeSliceID () const
 
int getTrackID () const
 
uint32_t getUnitID () const
 
bool isFinecaloTrackID () const
 
void operator delete (void *CaloG4Hit)
 
void * operator new (size_t)
 
const CaloG4Hitoperator= (const CaloG4Hit &right)
 
bool operator== (const CaloG4Hit &)
 
void Print () override
 
void setEM (double e)
 
void setEntry (double x, double y, double z)
 
void setEntryLocal (double x, double y, double z)
 
void setHadr (double e)
 
void setID (uint32_t i, double d, int j, uint16_t k=0)
 
void setID (const CaloHitID &id)
 
void setIncidentEnergy (double e)
 
void setPosition (double x, double y, double z)
 
 ~CaloG4Hit () override
 

Private Attributes

double elem
 
math::XYZPoint entry
 
math::XYZPoint entryLocal
 
double hadr
 
CaloHitID hitID
 
math::XYZPoint pos
 
double theIncidentEnergy
 

Detailed Description

Definition at line 32 of file CaloG4Hit.h.

Constructor & Destructor Documentation

CaloG4Hit::CaloG4Hit ( )

Definition at line 13 of file CaloG4Hit.cc.

References elem, hadr, setEntry(), setEntryLocal(), and theIncidentEnergy.

13  {
14  setEntry(0., 0., 0.);
15  setEntryLocal(0., 0., 0.);
16  elem = 0.;
17  hadr = 0.;
18  theIncidentEnergy = 0.;
19 }
void setEntryLocal(double x, double y, double z)
Definition: CaloG4Hit.h:50
double hadr
Definition: CaloG4Hit.h:86
double theIncidentEnergy
Definition: CaloG4Hit.h:87
void setEntry(double x, double y, double z)
Definition: CaloG4Hit.h:47
double elem
Definition: CaloG4Hit.h:85
CaloG4Hit::~CaloG4Hit ( )
override

Definition at line 21 of file CaloG4Hit.cc.

21 {}
CaloG4Hit::CaloG4Hit ( const CaloG4Hit right)

Definition at line 23 of file CaloG4Hit.cc.

References elem, entry, entryLocal, hadr, hitID, pos, and theIncidentEnergy.

23  {
24  entry = right.entry;
25  entryLocal = right.entryLocal;
26  pos = right.pos;
27  elem = right.elem;
28  hadr = right.hadr;
30  hitID = right.hitID;
31 }
CaloHitID hitID
Definition: CaloG4Hit.h:88
math::XYZPoint entry
Definition: CaloG4Hit.h:82
double hadr
Definition: CaloG4Hit.h:86
math::XYZPoint entryLocal
Definition: CaloG4Hit.h:83
double theIncidentEnergy
Definition: CaloG4Hit.h:87
math::XYZPoint pos
Definition: CaloG4Hit.h:84
double elem
Definition: CaloG4Hit.h:85

Member Function Documentation

void CaloG4Hit::addEnergyDeposit ( double  em,
double  hd 
)

Definition at line 45 of file CaloG4Hit.cc.

References elem, and hadr.

Referenced by addEnergyDeposit(), and CaloSD::updateHit().

45  {
46  elem += em;
47  hadr += hd;
48 }
double hadr
Definition: CaloG4Hit.h:86
double elem
Definition: CaloG4Hit.h:85
void CaloG4Hit::addEnergyDeposit ( const CaloG4Hit aHit)

Definition at line 50 of file CaloG4Hit.cc.

References addEnergyDeposit(), getEM(), and getHadr().

50 { addEnergyDeposit(aHit.getEM(), aHit.getHadr()); }
void addEnergyDeposit(double em, double hd)
Definition: CaloG4Hit.cc:45
double getEM() const
Definition: CaloG4Hit.h:55
double getHadr() const
Definition: CaloG4Hit.h:58
void CaloG4Hit::Draw ( )
inlineoverride

Definition at line 42 of file CaloG4Hit.h.

42 {}
uint16_t CaloG4Hit::getDepth ( void  ) const
inline

Definition at line 69 of file CaloG4Hit.h.

References CaloHitID::depth(), and hitID.

Referenced by SimG4HcalValidation::fill(), CaloSD::filterHit(), CaloG4HitLess::operator()(), CaloG4HitEqual::operator()(), and CaloSD::saveHit().

69 { return hitID.depth(); }
uint16_t depth() const
Definition: CaloHitID.h:24
CaloHitID hitID
Definition: CaloG4Hit.h:88
double CaloG4Hit::getEM ( ) const
inline

Definition at line 55 of file CaloG4Hit.h.

References elem.

Referenced by addEnergyDeposit(), ZdcSD::getFromLibrary(), operator<<(), CaloSD::saveHit(), HcalTB02Analysis::update(), and ZdcTestAnalysis::update().

55 { return elem; }
double elem
Definition: CaloG4Hit.h:85
double CaloG4Hit::getEnergyDeposit ( ) const
inline
math::XYZPoint CaloG4Hit::getEntry ( ) const
inline

Definition at line 46 of file CaloG4Hit.h.

References entry.

Referenced by HcalTB04Analysis::fillBuffer(), CastorShowerLibraryMaker::FillShowerEvent(), operator<<(), and EcalSimHitsValidProducer::update().

46 { return entry; }
math::XYZPoint entry
Definition: CaloG4Hit.h:82
math::XYZPoint CaloG4Hit::getEntryLocal ( ) const
inline

Definition at line 49 of file CaloG4Hit.h.

References entryLocal.

Referenced by ZdcSD::getFromLibrary(), and operator<<().

49 { return entryLocal; }
math::XYZPoint entryLocal
Definition: CaloG4Hit.h:83
double CaloG4Hit::getHadr ( ) const
inline

Definition at line 58 of file CaloG4Hit.h.

References hadr.

Referenced by addEnergyDeposit(), ZdcSD::getFromLibrary(), operator<<(), CaloSD::saveHit(), HcalTB02Analysis::update(), and ZdcTestAnalysis::update().

58 { return hadr; }
double hadr
Definition: CaloG4Hit.h:86
CaloHitID CaloG4Hit::getID ( ) const
inline

Definition at line 72 of file CaloG4Hit.h.

References hitID.

Referenced by operator<<(), and CaloSD::shortreprID().

72 { return hitID; }
CaloHitID hitID
Definition: CaloG4Hit.h:88
double CaloG4Hit::getIncidentEnergy ( ) const
inline
math::XYZPoint CaloG4Hit::getPosition ( ) const
inline
double CaloG4Hit::getTimeSlice ( ) const
inline
int CaloG4Hit::getTimeSliceID ( ) const
inline

Definition at line 68 of file CaloG4Hit.h.

References hitID, and CaloHitID::timeSliceID().

Referenced by CaloG4HitLess::operator()(), CaloG4HitEqual::operator()(), HcalTB02Analysis::update(), and ZdcTestAnalysis::update().

68 { return hitID.timeSliceID(); }
CaloHitID hitID
Definition: CaloG4Hit.h:88
int timeSliceID() const
Definition: CaloHitID.h:21
int CaloG4Hit::getTrackID ( ) const
inline
uint32_t CaloG4Hit::getUnitID ( ) const
inline
bool CaloG4Hit::isFinecaloTrackID ( ) const
inline

Definition at line 70 of file CaloG4Hit.h.

References hitID, and CaloHitID::isFinecaloTrackID().

Referenced by CaloSD::saveHit().

70 { return hitID.isFinecaloTrackID(); }
bool isFinecaloTrackID() const
Definition: CaloHitID.h:30
CaloHitID hitID
Definition: CaloG4Hit.h:88
void CaloG4Hit::operator delete ( void *  CaloG4Hit)
inline

Definition at line 124 of file CaloG4Hit.h.

References fpCaloG4HitAllocator.

124 { fpCaloG4HitAllocator->FreeSingle((CaloG4Hit*)aHit); }
G4ThreadLocal G4Allocator< CaloG4Hit > * fpCaloG4HitAllocator
Definition: CaloG4Hit.cc:11
void * CaloG4Hit::operator new ( size_t  )
inline

Definition at line 118 of file CaloG4Hit.h.

References fpCaloG4HitAllocator.

118  {
120  fpCaloG4HitAllocator = new G4Allocator<CaloG4Hit>;
121  return (void*)fpCaloG4HitAllocator->MallocSingle();
122 }
G4ThreadLocal G4Allocator< CaloG4Hit > * fpCaloG4HitAllocator
Definition: CaloG4Hit.cc:11
const CaloG4Hit & CaloG4Hit::operator= ( const CaloG4Hit right)

Definition at line 33 of file CaloG4Hit.cc.

References elem, entry, entryLocal, hadr, hitID, pos, and theIncidentEnergy.

33  {
34  entry = right.entry;
35  entryLocal = right.entryLocal;
36  pos = right.pos;
37  elem = right.elem;
38  hadr = right.hadr;
40  hitID = right.hitID;
41 
42  return *this;
43 }
CaloHitID hitID
Definition: CaloG4Hit.h:88
math::XYZPoint entry
Definition: CaloG4Hit.h:82
double hadr
Definition: CaloG4Hit.h:86
math::XYZPoint entryLocal
Definition: CaloG4Hit.h:83
double theIncidentEnergy
Definition: CaloG4Hit.h:87
math::XYZPoint pos
Definition: CaloG4Hit.h:84
double elem
Definition: CaloG4Hit.h:85
bool CaloG4Hit::operator== ( const CaloG4Hit )
inline

Definition at line 38 of file CaloG4Hit.h.

38 { return false; }
void CaloG4Hit::Print ( void  )
override

Definition at line 52 of file CaloG4Hit.cc.

52 { edm::LogVerbatim("CaloSim") << (*this); }
Log< level::Info, true > LogVerbatim
void CaloG4Hit::setEM ( double  e)
inline

Definition at line 56 of file CaloG4Hit.h.

References alignCSCRings::e, and elem.

Referenced by CaloSD::createNewHit().

56 { elem = e; }
double elem
Definition: CaloG4Hit.h:85
void CaloG4Hit::setEntry ( double  x,
double  y,
double  z 
)
inline

Definition at line 47 of file CaloG4Hit.h.

References entry.

Referenced by CaloG4Hit(), and CaloSD::createNewHit().

47 { entry.SetCoordinates(x, y, z); }
math::XYZPoint entry
Definition: CaloG4Hit.h:82
void CaloG4Hit::setEntryLocal ( double  x,
double  y,
double  z 
)
inline

Definition at line 50 of file CaloG4Hit.h.

References entryLocal.

Referenced by CaloG4Hit(), and CaloSD::createNewHit().

50 { entryLocal.SetCoordinates(x, y, z); }
math::XYZPoint entryLocal
Definition: CaloG4Hit.h:83
void CaloG4Hit::setHadr ( double  e)
inline

Definition at line 59 of file CaloG4Hit.h.

References alignCSCRings::e, and hadr.

Referenced by CaloSD::createNewHit().

59 { hadr = e; }
double hadr
Definition: CaloG4Hit.h:86
void CaloG4Hit::setID ( uint32_t  i,
double  d,
int  j,
uint16_t  k = 0 
)
inline

Definition at line 73 of file CaloG4Hit.h.

References hitID, isotrackApplyRegressor::k, and CaloHitID::setID().

Referenced by CaloSD::createNewHit().

73 { hitID.setID(i, d, j, k); }
tuple d
Definition: ztail.py:151
CaloHitID hitID
Definition: CaloG4Hit.h:88
void setID(uint32_t unitID, double timeSlice, int trackID, uint16_t depth=0)
Definition: CaloHitID.cc:41
void CaloG4Hit::setID ( const CaloHitID id)
inline

Definition at line 74 of file CaloG4Hit.h.

References hitID, and gpuClustering::id.

74 { hitID = id; }
uint16_t *__restrict__ id
CaloHitID hitID
Definition: CaloG4Hit.h:88
void CaloG4Hit::setIncidentEnergy ( double  e)
inline

Definition at line 62 of file CaloG4Hit.h.

References alignCSCRings::e, and theIncidentEnergy.

Referenced by CaloSD::createNewHit().

62 { theIncidentEnergy = e; }
double theIncidentEnergy
Definition: CaloG4Hit.h:87
void CaloG4Hit::setPosition ( double  x,
double  y,
double  z 
)
inline

Definition at line 53 of file CaloG4Hit.h.

References pos.

Referenced by CaloSD::createNewHit().

53 { pos.SetCoordinates(x, y, z); }
math::XYZPoint pos
Definition: CaloG4Hit.h:84

Member Data Documentation

double CaloG4Hit::elem
private

Definition at line 85 of file CaloG4Hit.h.

Referenced by addEnergyDeposit(), CaloG4Hit(), getEM(), getEnergyDeposit(), operator=(), and setEM().

math::XYZPoint CaloG4Hit::entry
private

Definition at line 82 of file CaloG4Hit.h.

Referenced by CaloG4Hit(), getEntry(), operator=(), and setEntry().

math::XYZPoint CaloG4Hit::entryLocal
private

Definition at line 83 of file CaloG4Hit.h.

Referenced by CaloG4Hit(), getEntryLocal(), operator=(), and setEntryLocal().

double CaloG4Hit::hadr
private

Definition at line 86 of file CaloG4Hit.h.

Referenced by addEnergyDeposit(), CaloG4Hit(), getEnergyDeposit(), getHadr(), operator=(), and setHadr().

CaloHitID CaloG4Hit::hitID
private
math::XYZPoint CaloG4Hit::pos
private

Definition at line 84 of file CaloG4Hit.h.

Referenced by CaloG4Hit(), getPosition(), operator=(), and setPosition().

double CaloG4Hit::theIncidentEnergy
private

Definition at line 87 of file CaloG4Hit.h.

Referenced by CaloG4Hit(), getIncidentEnergy(), operator=(), and setIncidentEnergy().