Ashet OS

namespace: ashet.overlapped

Types

System Calls

syscall schedule(in async_call: *ARC)

Starts new asynchronous operations.

syscall await_completion(in completed: []*ARC, in options: Await_Options, out completed_count: usize)

Awaits one or more scheduled asynchronous operations and returns the number of await_completion.completed elements.

The kernel will fill out await_completion.completed up to the returned number of elements. All other values are undefined.

syscall await_completion_of(in events: []?*ARC, out completed_count: usize)

Awaits one or more explicit asynchronous operations and returns the number of await_completion_of.events elements.

The kernel will only await elements provided in await_completion_of.events and all of those events must not be awaited by another await_completion_of.

When the function returns, await_completion_of.events will have all completed events unchanged, and all unfinished events set to null. This way, a simple check via index can be done instead of the need for iteration of await_completion_of.events to find what was finished.

syscall cancel(in aop: *ARC)

Cancels an asynchronous call.