eve.backend.linux.epoll

Linux Layer 0 readiness backend built on epoll.

The backend stays intentionally thin: it owns the epoll file descriptor, exposes direct registration operations, waits for native events, and provides translation into the shared OsEvent form.

Types 2

aliasNativeEvent = epoll_event

Native event type returned by this backend.

structOsPoller

epoll-backed poller state.

Fields
private int _fd
Methods
OsPoller create() static @trusted nothrow @nogcCreate a new `epoll` poller.
bool isValid() @property const pure @safe nothrow @nogcCheck whether the poller has a valid native epoll file descriptor.
Handle handle() @property const pure @safe nothrow @nogcReturn the native handle wrapper for the epoll instance.
BackendId backendId() @property const pure @safe nothrow @nogcReturn the identifier of this backend.
BackendCapabilities capabilities() @property const pure @safe nothrow @nogcReturn the capability flags for this backend.
int dispose() @trusted nothrow @nogcClose the epoll instance.
int registerHandle(Handle handle, IoInterest interest, ulong userData, WatcherFlags flags = WatcherFlags.none) @trusted nothrow @nogcRegister a handle with the given interests and opaque user data.
int modifyHandle(Handle handle, IoInterest interest, ulong userData, WatcherFlags flags = WatcherFlags.none) @trusted nothrow @nogcModify the interest mask and user data for an already-registered handle.
int unregisterHandle(Handle handle) @trusted nothrow @nogcRemove a handle from the epoll set.
int wait(scope NativeEvent[] nativeEvents, int timeoutMs) @trusted nothrow @nogcWait for native events.
OsEvent translate(ref const(NativeEvent) nativeEvent) static pure @safe nothrow @nogcTranslate a native `epoll` event into the shared Layer 0 event shape.
IoReady translateReady(uint nativeMask) static pure @safe nothrow @nogcTranslate a native epoll readiness mask into shared readiness flags.
bool isEdgeTriggered(uint nativeMask) static pure @safe nothrow @nogcCheck whether a native epoll event mask has edge-triggered mode set.

Functions 3

private fnuint toNativeMask(IoInterest interest, WatcherFlags flags = WatcherFlags.none) pure @safe nothrow @nogc
private fnIoReady fromNativeMask(uint mask) pure @safe nothrow @nogc
private fnNativeEvent makeNativeEvent(IoInterest interest, ulong userData, WatcherFlags flags = WatcherFlags.none) @trusted nothrow @nogc