SignalFD

Performs a linear scan of haystack from [0 .. haystack.length$(RP), returning true if an element matching needle is found. Comparisons will be performed using the supplied predicate or '==' if none is supplied.

Constructors

this
this(int[] signals, bool mask)

Constructor. Creates a signal event file descriptor which will be written to when one of the specified signals fires. The normal signal handling for the specified signals is optionally masked.

Destructor

~this
~this()

Destructor. Destroys the signal file descriptor and unmasks all masked signals.

Members

Aliases

SignalInfo
alias SignalInfo = signalfd_siginfo

More convenient alias for signalfd_siginfo.

Classes

SignalErrnoException
class SignalErrnoException

errno exception type for signal events.

Functions

fileHandle
Handle fileHandle()

Required by ISelectable interface.

handle
void handle(SignalInfo[] siginfos)

Should be called when the signal event has fired. Fills in the provided array with structs containing information about which signals fired.

isRegistered
bool isRegistered(int signal)

Checks whether the specified signal is registered to be handled by this fd.

maskHandledSignals
void maskHandledSignals()

Masks all signals registered with this fd, meaning that the default signal (interrupt) handler will not deal with them from now.

register
typeof(this) register(int signal, bool mask)

Adds the specified signal to the set of signals handled by this fd. The normal signal handling for the specified signal is optionally masked.

registered_signals
int[] registered_signals()

Getter for the list of registered signals. Changing the contents of the returned array may lead to undefined behaviour.

unmaskHandledSignals
void unmaskHandledSignals()

Unmasks all signals registered with this fd, meaning that the default signal (interrupt) handler will deal with them from now.

Inherited Members

From ISelectable

fileHandle
Handle fileHandle()

Models a handle-oriented device.

Return Value

True if an element equivalent to needle is found, false if not.

Meta