VMC Examples Version 6.6
Loading...
Searching...
No Matches
Hit.cxx
Go to the documentation of this file.
1//------------------------------------------------
2// The Virtual Monte Carlo examples
3// Copyright (C) 2007 - 2015 Ivana Hrivnacova
4// All rights reserved.
5//
6// For the licensing terms see geant4_vmc/LICENSE.
7// Contact: root-vmc@cern.ch
8//-------------------------------------------------
9
10/// \file Gflash/src/Hit.cxx
11/// \brief Implementation of the Gflash::Hit class
12///
13/// Geant4 gflash example adapted to Virtual Monte Carlo.
14///
15/// \date 28/10/2015
16/// \author I. Hrivnacova; IPN, Orsay
17
18#include <Riostream.h>
19
20#include "Hit.h"
21
22/// \cond CLASSIMP
23ClassImp(VMC::Gflash::Hit)
24 /// \endcond
25
26 using namespace std;
27
28namespace VMC
29{
30namespace Gflash
31{
32
33//_____________________________________________________________________________
34Hit::Hit() : TObject(), fEdep(0), fPos(), fCrystalNumber(0)
35{
36 /// Default constructor
37}
38
39//_____________________________________________________________________________
41{
42 /// Destructor
43}
44
45//_____________________________________________________________________________
46void Hit::Print(Option_t* /*option*/) const
47{
48 /// Print hit info
49
50 cout << "In crystal: " << fCrystalNumber << ":" << endl
51 << " energy deposit (keV): " << fEdep * 1.0e06 << endl;
52}
53
54//_____________________________________________________________________________
56{
57 /// Reset accounted values.
58
59 fEdep = 0.;
60 fPos = TVector3();
62}
63
64} // namespace Gflash
65} // namespace VMC
The calorimeter hit.
Definition Hit.h:37
void Reset()
Definition Hit.cxx:55
TVector3 fPos
Cell position.
Definition Hit.h:58
virtual ~Hit()
Definition Hit.cxx:40
virtual void Print(Option_t *option="") const
Definition Hit.cxx:46
Int_t fCrystalNumber
Crystal number.
Definition Hit.h:59
Double_t fEdep
Energy deposit in the absorber.
Definition Hit.h:57