|
||||
File indexing completed on 2025-01-18 09:59:20
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 // 0028 0029 #ifndef G4VDigi_h 0030 #define G4VDigi_h 1 0031 0032 #include "globals.hh" 0033 0034 #include <map> 0035 #include <vector> 0036 0037 class G4AttDef; 0038 class G4AttValue; 0039 0040 // class description: 0041 // 0042 // This is the base class of digi object. The user should derive this 0043 // base class to make his/her own digi class. Two virtual method Draw() 0044 // and Print() can be implemented if the user wants these functionarities. 0045 // If a concrete digi class is used as a transient class, G4Allocator 0046 // must be used. 0047 0048 class G4VDigi 0049 { 0050 public: 0051 G4VDigi() = default; 0052 virtual ~G4VDigi() = default; 0053 0054 G4bool operator==(const G4VDigi& right) const { return (this == &right); } 0055 0056 virtual void Draw(){}; 0057 virtual void Print(){}; 0058 0059 // Returns pointer to map of attribute definitions for this digit 0060 // Caller is responsible for checking validity of returned pointer. 0061 // See `G4Trajectory` for a concrete implementation. 0062 virtual const std::map<G4String, G4AttDef>* GetAttDefs() const { return nullptr; } 0063 0064 // Returns pointer to list of attributes for this digit 0065 // Each attribute must correspond to a definition returned by `GetAffDefs`. 0066 // Caller is responsible for checking validity of returned pointer. 0067 // See `G4Trajectory` for a concrete implementation, and 0068 // `G4VTrajectory::ShowTrajectory` for an example of its use. 0069 virtual std::vector<G4AttValue>* CreateAttValues() const { return nullptr; } 0070 }; 0071 0072 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |