DD4hep  1.30.0
Detector Description Toolkit for High Energy Physics
Classes | Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
SignalHandler::implementation Class Reference

Classes

struct  sig_entry_t
 
struct  sig_handler_t
 
struct  sig_handler_t
 
struct  sig_handler_t
 

Public Types

typedef std::map< int, sig_handler_tSigMap
 

Public Member Functions

 implementation ()
 Default constructor. More...
 
 ~implementation ()
 Default destructor. More...
 
void init ()
 Initialize the exit handler. Subscribe to default signals. More...
 
void install (int num, const std::string &name, struct sigaction &action)
 Install handler for a single signal. More...
 
int subscribe (int signum, void *user_context, signal_handler_t handler)
 Subscribe to a given signal with a user context and a user handler. The context MUST be unique! More...
 
int unsubscribe (int signum, void *user_context)
 Unsubscribe from a given signal with a user context identifier. More...
 
void back_trace (int)
 Create simple backtrace. More...
 

Static Public Member Functions

static implementationinstance ()
 Singleton accessor. More...
 
static void handler (int signum, siginfo_t *info, void *)
 Static handler callback for system signal handler. More...
 

Public Attributes

SigMap m_map
 

Detailed Description

Small class to manipulate default signal handling

Author
M.Frank

Definition at line 49 of file SignalHandler.cpp.

Member Typedef Documentation

◆ SigMap

Definition at line 63 of file SignalHandler.cpp.

Constructor & Destructor Documentation

◆ implementation()

SignalHandler::implementation::implementation ( )

Default constructor.

Definition at line 88 of file SignalHandler.cpp.

◆ ~implementation()

SignalHandler::implementation::~implementation ( )

Default destructor.

Definition at line 92 of file SignalHandler.cpp.

Member Function Documentation

◆ back_trace()

void SignalHandler::implementation::back_trace ( int  )

Create simple backtrace.

Definition at line 169 of file SignalHandler.cpp.

◆ handler()

void SignalHandler::implementation::handler ( int  signum,
siginfo_t *  info,
void *  ptr 
)
static

Static handler callback for system signal handler.

Definition at line 210 of file SignalHandler.cpp.

◆ init()

void SignalHandler::implementation::init ( )

Initialize the exit handler. Subscribe to default signals.

Definition at line 105 of file SignalHandler.cpp.

◆ install()

void SignalHandler::implementation::install ( int  num,
const std::string &  name,
struct sigaction &  action 
)

Install handler for a single signal.

Definition at line 194 of file SignalHandler.cpp.

◆ instance()

SignalHandler::implementation & SignalHandler::implementation::instance ( )
static

Singleton accessor.

Definition at line 96 of file SignalHandler.cpp.

◆ subscribe()

int SignalHandler::implementation::subscribe ( int  signum,
void *  user_context,
signal_handler_t  handler 
)

Subscribe to a given signal with a user context and a user handler. The context MUST be unique!

Definition at line 129 of file SignalHandler.cpp.

◆ unsubscribe()

int SignalHandler::implementation::unsubscribe ( int  signum,
void *  user_context 
)

Unsubscribe from a given signal with a user context identifier.

Definition at line 154 of file SignalHandler.cpp.

Member Data Documentation

◆ m_map

SigMap SignalHandler::implementation::m_map

Definition at line 64 of file SignalHandler.cpp.


The documentation for this class was generated from the following file: