eve.core.windows.signals

Signal handling support for the Windows event loop.

This module manages console control signal detection and dispatch for the Windows event loop. Windows signals are delivered via SetConsoleCtrlHandler on a separate thread and must be bridged to the event loop through atomic flags and IOCP wakeup.

Types 1

Manages console control signal state and detection.

Windows delivers CTRL_C, CTRL_BREAK, and CTRL_CLOSE events on a separate thread. This struct bridges those events to the event loop using atomic flags that are checked each iteration.

Fields
bool consoleHandlerInstalled
Methods
void install(SelectedBackend * poller) @trusted nothrowInstall the console control handler.
bool hasSignalWatcher(Slot)(Signal signal, scope const(Slot)[] slots) const @safe nothrow @nogcCheck whether a specific signal has any registered watcher.
void checkEvents(Slot, DispatchFn)(scope Slot[] slots, scope DispatchFn dispatchFn) @trusted nothrowCheck for pending console control signals and dispatch them.
bool isInstalled() const @safe nothrow @nogcCheck whether the console control handler has been installed.
void setPending(Signal signal) @safe nothrowMark a signal as pending (for testing or programmatic signaling).
static @safe nothrow @nogc auto signalInfoFor(Signal signal)

Functions 2

fnauto SignalInfoFor(Signal signal) pure @safe nothrow @nogcBuild a signal info tuple for the given signal.
private fnint consoleCtrlHandler(uint ctrlType) nothrow

Variables 3

varbool _pendingInterrupt
varbool _pendingTerminate
varSelectedBackend * _globalPoller