Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Friends
CCalHit Class Reference

#include <CCalHit.hh>

Inheritance diagram for CCalHit:
CCalG4Hit

Public Member Functions

 CCalHit ()
 
 ~CCalHit ()
 
 CCalHit (const CCalHit &right)
 
const CCalHitoperator= (const CCalHit &right)
 
int operator== (const CCalHit &)
 
void print ()
 
CLHEP::Hep3Vector getEntry () const
 
void setEntry (CLHEP::Hep3Vector xyz)
 
double getIncidentEnergy () const
 
void setIncidentEnergy (double e)
 
int getTrackID () const
 
void setTrackID (int i)
 
unsigned int getUnitID () const
 
void setUnitID (unsigned int i)
 
double getTimeSlice () const
 
void setTimeSlice (double d)
 
int getTimeSliceID () const
 
double getEnergyDeposit () const
 
void setEnergyDeposit (const double e)
 
void addEnergyDeposit (const CCalHit &aHit)
 
void addEnergyDeposit (const double e)
 

Friends

std::ostream & operator<< (std::ostream &, const CCalHit &)
 

Detailed Description

Definition at line 52 of file CCalHit.hh.

Constructor & Destructor Documentation

CCalHit::CCalHit ( )

Definition at line 35 of file CCalHit.cc.

35  :
36  entry(0), theIncidentEnergy(0.0), theTrackID(-1),
37  theUnitID(0), theTimeSlice(0.0), theEnergyDeposit(0.0)
38 {}
CCalHit::~CCalHit ( )

Definition at line 41 of file CCalHit.cc.

41 {}
CCalHit::CCalHit ( const CCalHit right)

Definition at line 44 of file CCalHit.cc.

44  :
45  entry( right.entry ),
46  theIncidentEnergy( right.theIncidentEnergy ),
47  theTrackID( right.theTrackID ),
48  theUnitID( right.theUnitID ),
49  theTimeSlice( right.theTimeSlice ),
50  theEnergyDeposit( right.theEnergyDeposit )
51 {}

Member Function Documentation

void CCalHit::addEnergyDeposit ( const CCalHit aHit)

Definition at line 90 of file CCalHit.cc.

References getEnergyDeposit().

Referenced by CCalG4Hit::addEnergyDeposit().

90  {
92 }
double getEnergyDeposit() const
Definition: CCalHit.cc:86
void addEnergyDeposit(const CCalHit &aHit)
Definition: CCalHit.cc:90
void CCalHit::addEnergyDeposit ( const double  e)

Definition at line 94 of file CCalHit.cc.

94  {
95  theEnergyDeposit += e;
96 }
double CCalHit::getEnergyDeposit ( ) const

Definition at line 86 of file CCalHit.cc.

Referenced by addEnergyDeposit(), CCalEndOfEventAction::EndOfEventAction(), and operator<<().

86  {
87  return theEnergyDeposit;
88 }
CLHEP::Hep3Vector CCalHit::getEntry ( ) const

Definition at line 65 of file CCalHit.cc.

Referenced by operator<<().

65 {return entry;}
double CCalHit::getIncidentEnergy ( ) const

Definition at line 68 of file CCalHit.cc.

Referenced by operator<<().

68 {return theIncidentEnergy; }
double CCalHit::getTimeSlice ( ) const

Definition at line 77 of file CCalHit.cc.

Referenced by CCalEndOfEventAction::EndOfEventAction().

77 {return theTimeSlice; }
int CCalHit::getTimeSliceID ( ) const

Definition at line 79 of file CCalHit.cc.

Referenced by operator<<().

79  { if ( theTimeSlice > 1.0E9 ) return 999999999;
80  return (int)theTimeSlice;}
int CCalHit::getTrackID ( ) const

Definition at line 71 of file CCalHit.cc.

Referenced by operator<<().

71 {return theTrackID; }
unsigned int CCalHit::getUnitID ( ) const

Definition at line 74 of file CCalHit.cc.

Referenced by CCalEndOfEventAction::EndOfEventAction(), and operator<<().

74 {return theUnitID; }
const CCalHit & CCalHit::operator= ( const CCalHit right)

Definition at line 54 of file CCalHit.cc.

Referenced by CCalG4Hit::operator=().

54  {
55  entry = right.entry;
56  theIncidentEnergy = right.theIncidentEnergy;
57  theTrackID = right.theTrackID;
58  theUnitID = right.theUnitID;
59  theTimeSlice = right.theTimeSlice;
60  theEnergyDeposit = right.theEnergyDeposit;
61  return *this;
62 }
int CCalHit::operator== ( const CCalHit )
inline

Definition at line 62 of file CCalHit.hh.

62 {return 0;}
void CCalHit::print ( )

Definition at line 99 of file CCalHit.cc.

References G4cout.

99  {
100  G4cout << (*this);
101 }
G4GLOB_DLL std::ostream G4cout
void CCalHit::setEnergyDeposit ( const double  e)

Definition at line 82 of file CCalHit.cc.

82  {
83  theEnergyDeposit = e;
84 }
void CCalHit::setEntry ( CLHEP::Hep3Vector  xyz)

Definition at line 66 of file CCalHit.cc.

66 { entry = xyz; }
void CCalHit::setIncidentEnergy ( double  e)

Definition at line 69 of file CCalHit.cc.

69 {theIncidentEnergy = e; }
void CCalHit::setTimeSlice ( double  d)

Definition at line 78 of file CCalHit.cc.

78 { theTimeSlice = d; }
void CCalHit::setTrackID ( int  i)

Definition at line 72 of file CCalHit.cc.

72 { theTrackID = i; }
void CCalHit::setUnitID ( unsigned int  i)

Definition at line 75 of file CCalHit.cc.

75 { theUnitID = i; }

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const CCalHit hit 
)
friend

Definition at line 104 of file CCalHit.cc.

104  {
105  os << " Data of this CCalHit are:"<< G4endl
106  << " \t Time slice ID: " << hit.getTimeSliceID() << G4endl
107  << " \t Energy of primary particle (ID = " << hit.getTrackID()
108  << ") = " << hit.getIncidentEnergy() << " (MeV)"<< G4endl
109  << " \t Entry point in Calorimeter unit number " << hit.getUnitID()
110  << " is: " << hit.getEntry() << " (mm)" << G4endl
111  << " \t EnergyDeposit = " << hit.getEnergyDeposit() << " (MeV)" << G4endl;
112  return os;
113 }
double getIncidentEnergy() const
Definition: CCalHit.cc:68
double getEnergyDeposit() const
Definition: CCalHit.cc:86
int getTrackID() const
Definition: CCalHit.cc:71
CLHEP::Hep3Vector getEntry() const
Definition: CCalHit.cc:65
unsigned int getUnitID() const
Definition: CCalHit.cc:74
#define G4endl
Definition: G4ios.hh:61
int getTimeSliceID() const
Definition: CCalHit.cc:79

The documentation for this class was generated from the following files: