![]() |
|
|||
File indexing completed on 2025-02-23 09:21:08
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 /// \file eventgenerator/HepMC/HepMCEx01/include/HepMCG4PythiaInterface.hh 0027 /// \brief Definition of the HepMCG4PythiaInterface class 0028 // 0029 // 0030 0031 #ifndef HEPMC_G4_PYTHIA_INTERFACE_H 0032 #define HEPMC_G4_PYTHIA_INTERFACE_H 0033 0034 #include "HepMC/IO_HEPEVT.h" 0035 #include "HepMCG4Interface.hh" 0036 0037 class HepMCG4PythiaMessenger; 0038 0039 /// A generic interface class with Pythia event generator via HepMC. 0040 0041 class HepMCG4PythiaInterface : public HepMCG4Interface 0042 { 0043 protected: 0044 G4int verbose; 0045 G4int mpylist; 0046 HepMC::IO_HEPEVT hepevtio; 0047 0048 HepMCG4PythiaMessenger* messenger; 0049 0050 // In default, this is automatic conversion, Pythia->HEPEVT->HepMC, 0051 // by HepMC utilities. 0052 virtual HepMC::GenEvent* GenerateHepMCEvent(); 0053 0054 public: 0055 HepMCG4PythiaInterface(); 0056 ~HepMCG4PythiaInterface(); 0057 0058 // set/get methods 0059 void SetVerboseLevel(G4int i); 0060 G4int GetVerboseLevel() const; 0061 0062 void SetPylist(G4int i); 0063 G4int GetPylist() const; 0064 0065 // call pyxxx 0066 void CallPyinit(G4String frame, G4String beam, G4String target, G4double win); 0067 void CallPystat(G4int istat); 0068 0069 // random numbers operations 0070 void SetRandomSeed(G4int iseed); 0071 void CallPygive(G4String par); 0072 void CallPyrget(G4int lun, G4int move); 0073 void CallPyrset(G4int lun, G4int move); 0074 void PrintRandomStatus(std::ostream& ostr = G4cout) const; 0075 0076 // setup user parameters (empty in default). 0077 // Implement your parameters in a delived class if you want. 0078 virtual void SetUserParameters(); 0079 0080 virtual void Print() const; 0081 }; 0082 0083 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 0084 inline void HepMCG4PythiaInterface::SetVerboseLevel(G4int i) 0085 { 0086 verbose = i; 0087 } 0088 0089 inline G4int HepMCG4PythiaInterface::GetVerboseLevel() const 0090 { 0091 return verbose; 0092 } 0093 0094 inline void HepMCG4PythiaInterface::SetPylist(G4int i) 0095 { 0096 mpylist = i; 0097 } 0098 0099 inline G4int HepMCG4PythiaInterface::GetPylist() const 0100 { 0101 return mpylist; 0102 } 0103 0104 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
![]() ![]() |