ThreadGuards

class ThreadGuards(logger: KtaleLogger)

Conceptual thread guards (not enforced).

Why this exists

We don't know the eventual server threading model (if any). This is a lightweight mechanism that can be used to document expectations and to optionally log diagnostics when expectations are violated.

Non-goal

This does not attempt to control or enforce threads.

Constructors

Link copied to clipboard
constructor(logger: KtaleLogger)

Functions

Link copied to clipboard
fun expectAsync(note: String)

Marker for "expected async context".

Link copied to clipboard
fun expectSync(note: String)

Marker for "expected sync context".