00001 //---------------------------------------------------------------------------// 00002 //bb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nu// 00003 // // 00004 // MAJORANA Simulation // 00005 // // 00006 // This code implementation is the intellectual property of the // 00007 // MAJORANA Collaboration. It is based on Geant4, an intellectual // 00008 // property of the RD44 GEANT4 collaboration. // 00009 // // 00010 // ********************* // 00011 // // 00012 // Neither the authors of this software system, nor their employing // 00013 // institutes, nor the agencies providing financial support for this // 00014 // work make any representation or warranty, express or implied, // 00015 // regarding this software system or assume any liability for its use. // 00016 // By copying, distributing or modifying the Program (or any work based // 00017 // on on the Program) you indicate your acceptance of this statement, // 00018 // and all its terms. // 00019 // // 00020 //bb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nu// 00021 //---------------------------------------------------------------------------// 00022 // 00023 // $Id: MJManager.cc,v 1.2 2004/11/09 13:42:39 xliu Exp $ 00024 // 00025 // CLASS IMPLEMENTATION: MJManager.cc 00026 // 00027 //---------------------------------------------------------------------------// 00031 // 00032 //---------------------------------------------------------------------------// 00044 //---------------------------------------------------------------------------// 00045 00046 #include "G4RunManager.hh" 00047 #include "G4VisManager.hh" 00048 00049 #include "management/MJManagerMessenger.hh" 00050 #include "io/MJLogger.hh" 00051 //#include "waveform/MJWaveformManager.hh" 00052 00053 //---------------------------------------------------------------------------// 00054 00055 #include "management/MJManager.hh" 00056 00057 //---------------------------------------------------------------------------// 00058 00059 MJManager* MJManager::fMJManager = 0; 00060 00061 //---------------------------------------------------------------------------// 00062 00063 MJManager::MJManager(): 00064 fG4RunManager(0), fG4VisManager(0), 00065 fGeneratorPrimary(0), fGeometryDetectorConstruction(0), 00066 fManagementEventAction(0), fManagementRunAction(0), 00067 fManagementSteppingAction(0), fManagementTrackingAction(0) 00068 //, fWaveformManager(0) 00069 { 00070 if(fMJManager) { 00071 MJLog(error) << "MJManager must be singleton!" << endlog; 00072 MJLog(fatal) << endlog; 00073 } 00074 fMJManager = this; 00075 fG4Messenger = new MJManagerMessenger(this); 00076 } 00077 00078 //---------------------------------------------------------------------------// 00079 00080 MJManager::MJManager(const MJManager & other) 00081 {;} 00082 00083 //---------------------------------------------------------------------------// 00084 00085 MJManager::~MJManager() 00086 { 00087 delete fG4Messenger; 00088 delete fG4VisManager; 00089 //delete fWaveformManager; 00090 delete fG4RunManager; // G4RunManager deletes all the other objects. 00091 } 00092 00093 //---------------------------------------------------------------------------// 00094 00095 MJManager* MJManager::GetMJManager() 00096 { 00097 return fMJManager; 00098 } 00099 //---------------------------------------------------------------------------// 00100 //---------------------------------------------------------------------------//