#include <ExceptionHandler.h>
Definition at line 10 of file ExceptionHandler.h.
ExceptionHandler::ExceptionHandler |
( |
RunManager * |
rm | ) |
|
ExceptionHandler::ExceptionHandler |
( |
| ) |
|
|
inline |
ExceptionHandler::~ExceptionHandler |
( |
| ) |
|
|
virtual |
bool ExceptionHandler::Notify |
( |
const char * |
exceptionOrigin, |
|
|
const char * |
exceptionCode, |
|
|
G4ExceptionSeverity |
severity, |
|
|
const char * |
description |
|
) |
| |
|
virtual |
Definition at line 25 of file ExceptionHandler.cc.
References RunManager::abortRun(), RunManagerMT::abortRun(), gather_cfg::cout, fRunManager, and fRunManagerMT.
31 cout <<
"*** G4Exception : " << exceptionCode <<
" issued by " << exceptionOrigin << endl;
33 bool abortionForCoreDump =
false;
34 G4ApplicationState aps = G4StateManager::GetStateManager()->GetCurrentState();
38 if ( aps==G4State_EventProc && exceptionOrigin==
string(
"G4HadronicProcess") )
40 cout <<
"*** Fatal exception *** " << endl;
41 throw SimG4Exception(
"SimG4CoreApplication: Bug in G4HadronicProcess" ) ;
45 cout <<
"*** Fatal exception *** core dump ***" << endl;
46 abortionForCoreDump =
true;
53 case FatalErrorInArgument:
54 cout <<
"*** Fatal error in argument *** core dump ***" << endl;
55 abortionForCoreDump =
true;
57 case RunMustBeAborted:
58 if(aps==G4State_GeomClosed || aps==G4State_EventProc)
60 cout <<
"*** Run must be aborted " << endl;
64 abortionForCoreDump =
false;
66 case EventMustBeAborted:
67 if(aps==G4State_EventProc)
69 cout <<
"*** Event must be aborted " << endl;
97 throw SimG4Exception(
"SimG4CoreApplication: G4Navigator:StuckTrack detected" ) ;
99 abortionForCoreDump =
false;
102 cout <<
"*** This is just a warning message " << endl;
103 abortionForCoreDump =
false;
107 return abortionForCoreDump;
void abortRun(bool softAbort=false)
void abortRun(bool softAbort=false)
RunManagerMT * fRunManagerMT