eve.backend.windows.wpoll

Windows Layer 0 fallback backend built on WSAPoll.

This backend provides a simpler alternative to the IOCP backend for environments where WSAPoll is preferred or when IOCP is unavailable. It maintains a fixed-capacity registration table and translates poll events into the shared OsEvent shape consumed by Layer 1.

WSAPoll is limited to socket handles and cannot monitor arbitrary Windows handles such as files or pipes. For general-purpose handle monitoring, the IOCP backend should be used instead.

Types 2

Native event type returned by the wpoll backend.

Unlike epoll, WSAPoll does not produce a kernel-owned event payload, so the backend materializes a small translated record directly.

Fields
Handle handleHandle that became ready.
ulong userDataOpaque user value supplied at registration time.
IoReady readyShared readiness flags observed for the handle.
structOsPoller

WSAPoll-backed poller state for Windows.

This backend maintains a registration table and uses WSAPoll for socket readiness detection. It provides simpler semantics than IOCP at the cost of being limited to socket handles.

Methods
OsPoller create() static @trusted nothrow @nogcCreate a new WSAPoll-based poller.
bool isValid() @property const pure @safe nothrow @nogcCheck whether the poller instance is still usable.
Handle handle() @property const pure @safe nothrow @nogcReturn the native handle wrapper for this poller.
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() @safe nothrow @nogcDispose the poller and drop all registrations.
int registerHandle(Handle handle, IoInterest interest, ulong userData) @trusted nothrow @nogcRegister a handle with the given interests and opaque user data.
int modifyHandle(Handle handle, IoInterest interest, ulong userData) @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 registration table.
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 wpoll event into the shared Layer 0 event shape.
IoReady translateReady(IoReady nativeReady) static pure @safe nothrow @nogcTranslate native readiness into shared readiness flags.