Geant4  10.03.p03
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
LXeRecorderBase.hh
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 // $Id: LXeRecorderBase.hh 68752 2013-04-05 10:23:47Z gcosmo $
27 //
30 //
31 // LXeRecorderBase.hh
32 // 1-Sep-1999 Bill Seligman
33 
34 // This is an abstract base class to be used with Geant 4.0.1 (and
35 // possibly higher, if the User classes don't change).
36 
37 // The concept of a Recorder object is that it records the activities of
38 // Geant in a manner that is useful to a physicist. Perhaps this record
39 // takes the form of histograms, or ntuples, or entries in an Objectivity
40 // database. This class does not care HOW the information is recorded; it
41 // abstracts the behavior of a generalized recorder of Geant variables.
42 
43 // No object should be instantiated from the Recorder class (in fact, any such
44 // object won't do anything). The user must define a new class (say, a class
45 // that creates histograms) and overload the methods of this class.
46 
47 // Why do this? First of all, it keeps all record-keeping in a single class:
48 // the class that inherits Recorder. The original Geant documentation suggests
49 // that recording activities should be split among many different classes
50 // (initialization in G4UserRunAction, recording in G4UserSteppingAction, etc.).
51 // If you use a Recorder class, than all the record-keeping details are kept in
52 // a single class instead of being spread out among many different classes.
53 
54 // Secondly, by using an abstract Recorder class, you hide the implementation
55 // details from the rest of Geant. If you change a couple of histograms, only
56 // the Recorder-derived class and main() re-compile. No other class knows or
57 // cares what or how you record.
58 
59 // The only time this class (i.e., this header file) changes is if new
60 // user action classes are added to Geant.
61 
62 #ifndef RECORDER_BASE_H_
63 #define RECORDER_BASE_H_
64 
65 // The following objects are the arguments to the methods
66 // invoked in the user action classes. In other words, they
67 // contain the variables that we are normally able to record
68 // in Geant.
69 
70 #include "G4Run.hh"
71 #include "G4Event.hh"
72 #include "G4Track.hh"
73 #include "G4Step.hh"
74 
76 
77  public:
78 
79  virtual ~LXeRecorderBase() {};
80 
81  // The following a list of methods that correspond to the available
82  // user action classes in Geant 4.0.1. In this base class, the
83  // methods are defined to do nothing.
84 
85  virtual void RecordBeginOfRun(const G4Run*) = 0;
86  virtual void RecordEndOfRun(const G4Run*) = 0;
87  virtual void RecordBeginOfEvent(const G4Event*) {};
88  virtual void RecordEndOfEvent(const G4Event*) {};
89  virtual void RecordTrack(const G4Track*) {};
90  virtual void RecordStep(const G4Step*) {};
91 
92 };
93 
94 #endif
virtual void RecordTrack(const G4Track *)
Definition: G4Run.hh:46
Definition: G4Step.hh:76
virtual void RecordBeginOfEvent(const G4Event *)
virtual void RecordEndOfRun(const G4Run *)=0
virtual ~LXeRecorderBase()
virtual void RecordStep(const G4Step *)
virtual void RecordBeginOfRun(const G4Run *)=0
virtual void RecordEndOfEvent(const G4Event *)