Package com.rnett.krosstalk.client

Krosstalk APIs necessary for defining a client. See the module description.

Types

Link copied to clipboard
open class ClientFailureException @InternalKrosstalkApi constructor(methodName: String, cause: Throwable) : KrosstalkException

A Krosstalk call failed in the client. Happens when a request could not be made.

Link copied to clipboard
class DuplicateScopeException @InternalKrosstalkApi constructor(scope: Scope) : KrosstalkException
Link copied to clipboard
interface KrosstalkClient<C : ClientScope<*>>

The interface for a krosstalk client. Have your Krosstalk object implement this to be a client.

Link copied to clipboard
class ServerDefaultInEndpointException(methodName: String, parameter: String) : KrosstalkException
Link copied to clipboard
class WrongHeadersTypeException @InternalKrosstalkApi constructor(methodName: String, type: KClass<*>) : KrosstalkException
Link copied to clipboard
class WrongScopeTypeException @InternalKrosstalkApi constructor(scope: Scope, required: KType) : KrosstalkException

Functions

Link copied to clipboard
operator fun <T : ClientScope<C>, C> T.invoke(clientData: C): ScopeInstance<T>
Link copied to clipboard
suspend fun krosstalkCall(): Nothing
suspend fun krosstalkCall(requestHeaders: Headers): Nothing
suspend fun krosstalkCall(vararg scopes: ScopeInstance<*>): Nothing
suspend fun krosstalkCall(serverUrl: String?): Nothing
suspend fun krosstalkCall(scopes: Iterable<ScopeInstance<*>>): Nothing
suspend fun krosstalkCall(serverUrl: String? = null, requestHeaders: Headers = headersOf(), vararg scopes: ScopeInstance<*>): Nothing
suspend fun krosstalkCall(serverUrl: String? = null, requestHeaders: Headers = headersOf(), scopes: Iterable<ScopeInstance<*>> = emptyList()): Nothing

Placeholder for a Krosstalk client side method. Will be replaced by the compiler plugin.