|
||||
File indexing completed on 2025-01-18 09:58:16
0001 // 0002 // ******************************************************************** 0003 // * License and Disclaimer * 0004 // * * 0005 // * The Geant4 software is copyright of the Copyright Holders of * 0006 // * the Geant4 Collaboration. It is provided under the terms and * 0007 // * conditions of the Geant4 Software License, included in the file * 0008 // * LICENSE and available at http://cern.ch/geant4/license . These * 0009 // * include a list of copyright holders. * 0010 // * * 0011 // * Neither the authors of this software system, nor their employing * 0012 // * institutes,nor the agencies providing financial support for this * 0013 // * work make any representation or warranty, express or implied, * 0014 // * regarding this software system or assume any liability for its * 0015 // * use. Please see the license in the file LICENSE and URL above * 0016 // * for the full disclaimer and the limitation of liability. * 0017 // * * 0018 // * This code implementation is the result of the scientific and * 0019 // * technical work of the GEANT4 collaboration. * 0020 // * By using, copying, modifying or distributing the software (or * 0021 // * any work based on the software) you agree to acknowledge its * 0022 // * use in resulting scientific publications, and indicate your * 0023 // * acceptance of all terms of the Geant4 Software license. * 0024 // ******************************************************************** 0025 // 0026 0027 #ifndef G4FASTHIT_HH 0028 #define G4FASTHIT_HH 0029 0030 #include "G4ThreeVector.hh" 0031 0032 /** 0033 * @brief Minimal hit created in the fast simulation 0034 * 0035 * Minimal hit containing energy and position, for use in the fast simulation 0036 * classes. 0037 * Hits of G4FastHit type can be created in user implementation of fast 0038 * simulation model and then deposited in the detector using G4FastSimHitMaker 0039 * helper class. The helper will locate the sensitive volume and check if it 0040 * inherits from both base classes: 0041 * - G4VSensitiveDetector: for processing of detailed/non-fast simulation hits; 0042 * - G4VFastSimSensitiveDetector: for processing of fast sim (G4FastSim) hits; 0043 * An extended example extended/parameterisations/Par03 demonstrates how to use 0044 * G4FastHit to create multiple deposits from the fast simulation model. 0045 */ 0046 0047 class G4FastHit 0048 { 0049 public: 0050 G4FastHit() = default; 0051 G4FastHit(const G4ThreeVector& aPosition, G4double aEnergy) 0052 : fEnergy(aEnergy), fPosition(aPosition) 0053 {} 0054 virtual ~G4FastHit() = default; 0055 0056 /// Set energy 0057 inline void SetEnergy(const G4double& aEnergy) { fEnergy = aEnergy; } 0058 /// Get energy 0059 inline G4double GetEnergy() const { return fEnergy; } 0060 /// Set position 0061 inline void SetPosition(const G4ThreeVector& aPosition) { fPosition = aPosition; } 0062 /// Get position 0063 inline G4ThreeVector GetPosition() const { return fPosition; } 0064 0065 private: 0066 /// energy 0067 G4double fEnergy = 0; 0068 /// position 0069 G4ThreeVector fPosition = G4ThreeVector(); 0070 }; 0071 0072 #endif /* G4FASTHIT_HH */
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |