Package-level declarations

Types

Link copied to clipboard

A receiver that uses Ktor to send queries and mutations.

Properties

Link copied to clipboard
val ContextReceiver.httpClient: HttpClient?

Extension receiver for referencing the HttpClient instance needed when executing query, mutation and subscription.

Extension receiver for setting the HttpClient instance needed when executing query, mutation and subscription.

Functions

Link copied to clipboard
inline fun <T, S> buildKtorInfiniteQueryKey(id: InfiniteQueryId<T, S>, crossinline fetch: suspend HttpClient.(param: S) -> T, noinline initialParam: () -> S, noinline loadMoreParam: (QueryChunks<T, S>) -> S?): InfiniteQueryKey<T, S>

A delegation function to build an InfiniteQueryKey for Ktor.

Link copied to clipboard
inline fun <T, S> buildKtorMutationKey(id: MutationId<T, S> = MutationId.auto(), crossinline mutate: suspend HttpClient.(variable: S) -> T): MutationKey<T, S>

A delegation function to build a MutationKey for Ktor.

Link copied to clipboard
inline fun <T> buildKtorQueryKey(id: QueryId<T>, crossinline fetch: suspend HttpClient.() -> T): QueryKey<T>

A delegation function to build a QueryKey for Ktor.

Link copied to clipboard
inline fun <T> buildKtorSubscriptionKey(id: SubscriptionId<T> = SubscriptionId.auto(), crossinline subscribe: HttpClient.() -> Flow<T>): SubscriptionKey<T>

A delegation function to build a SubscriptionKey for Ktor.

Link copied to clipboard
fun KtorReceiver(client: HttpClient): KtorReceiver

Creates a new receiver that uses the given client to send queries and mutations.