UseCase
Base class for every use case (GetScreenUseCase, SendNetworkRequestUseCase, the data-source ones, etc.) — a single-method, Result-returning unit of domain logic, always run on Dispatchers.IO via invoke rather than the caller's own dispatcher.
Parameters
the type this use case produces on success.
the input this use case needs — a dedicated Params data class by convention when more than one value is needed, Unit when none is.
Functions
The use case's real logic — implement this, never call it directly (call invoke instead, which adds the Dispatchers.IO dispatch).
Runs execute on Dispatchers.IO — the only sanctioned way to run a UseCase.
UseCase.invoke overload for a use case whose Params is Unit — lets a parameterless use case be called as useCase() instead of useCase(Unit).