blob: da36365ace04011ec9a355f26aecf3b6493c22dc (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
#pragma once
#include <util/generic/ptr.h>
#include <functional>
struct TEventHandler {
virtual ~TEventHandler() {
}
virtual int Handle(int signum) = 0;
};
void SetAsyncSignalHandler(int signum, TAutoPtr<TEventHandler> handler);
void SetAsyncSignalHandler(int signum, void (*handler)(int));
void SetAsyncSignalFunction(int signum, std::function<void(int)> func);
|