#include <BLAlarm.hh>
used to prevent an infinite tracking loop from hanging an entire job.
NOTE: all functions are inline, so no .cc file is needed.
Static Public Member Functions | |
static void | clear () |
clear will clear any alarm. | |
static void | set (int seconds) |
set() sets an alarm in the future. Implicitly clears any previous alarm. | |
static void | init () |
init() will setup the signal handler Must be called before set(). | |
Static Private Member Functions | |
static void | sighandler (int sig) |
sighandler() handles the alarm signal |
static void BLAlarm::clear | ( | ) | [inline, static] |
static void BLAlarm::set | ( | int | seconds | ) | [inline, static] |
set() sets an alarm in the future. Implicitly clears any previous alarm.
Referenced by BLManager::BeginOfEventAction().
static void BLAlarm::init | ( | ) | [inline, static] |
init() will setup the signal handler Must be called before set().
References sighandler().
Referenced by BLManager::BLManager().
00055 { signal(SIGALRM,sighandler); }
static void BLAlarm::sighandler | ( | int | sig | ) | [inline, static, private] |
sighandler() handles the alarm signal
Referenced by init().
00059 { 00060 G4Exception("BLAlarm","Alarm Signal",FatalException, 00061 "SIGALRM fired, cannot be recovered"); 00062 }