NIST Biometric Evaluation Framework
Software components for biometric technology evaluations
Classes | Namespaces | Macros | Functions
be_time_watchdog.h File Reference
#include <csetjmp>
#include <csignal>
#include <be_time.h>
#include <be_error_exception.h>

Go to the source code of this file.

Classes

class  BiometricEvaluation::Time::Watchdog
 A Watchdog object can be used by applications to limit the amount of processing time taken by a block of code. More...
 

Namespaces

namespace  BiometricEvaluation
 This software was developed at the National Institute of Standards and Technology (NIST) by employees of the Federal Government in the course of their official duties.
 
namespace  BiometricEvaluation::Time
 Support for time and timers.
 

Macros

#define BEGIN_WATCHDOG_BLOCK(_watchdog, _blockname)
 Macros that are used by applications to indicate the start and end of a watchdog timer block. More...
 
#define END_WATCHDOG_BLOCK(_watchdog, _blockname)
 
#define ABORT_WATCHDOG(_watchdog)
 

Functions

void BiometricEvaluation::Time::WatchdogSignalHandler (int signo, siginfo_t *info, void *uap)
 

Macro Definition Documentation

◆ BEGIN_WATCHDOG_BLOCK

#define BEGIN_WATCHDOG_BLOCK (   _watchdog,
  _blockname 
)
Value:
do { \
if (!(_watchdog)->isEnabled()) \
break; \
(_watchdog)->clearExpired(); \
(_watchdog)->clearCanSigJump(); \
if (sigsetjmp( \
{ \
(_watchdog)->setExpired(); \
goto _blockname ## _end; \
} \
(_watchdog)->setCanSigJump(); \
(_watchdog)->start(); \
} while (0)

Macros that are used by applications to indicate the start and end of a watchdog timer block.

Definition at line 25 of file be_time_watchdog.h.

◆ END_WATCHDOG_BLOCK

#define END_WATCHDOG_BLOCK (   _watchdog,
  _blockname 
)
Value:
do { \
if (!(_watchdog)->isEnabled()) \
break; \
_blockname ## _end: \
(_watchdog)->clearCanSigJump(); \
(_watchdog)->stop(); \
} while (0);

Definition at line 40 of file be_time_watchdog.h.

◆ ABORT_WATCHDOG

#define ABORT_WATCHDOG (   _watchdog)
Value:
do { \
if (!(_watchdog)->isEnabled()) \
break; \
(_watchdog)->clearCanSigJump(); \
(_watchdog)->stop(); \
} while (0);

Definition at line 48 of file be_time_watchdog.h.