15 lines
504 B
Kotlin
15 lines
504 B
Kotlin
package net.sergeych.parsec3
|
|
|
|
import kotlinx.coroutines.flow.StateFlow
|
|
|
|
/**
|
|
* Transport level protocol (conforms to parsec 3.0). It is not specially secured could be used as is, as it provides bidirectional
|
|
* asynchronous (push capable) calls, but normally it should be used as a transport for parsec 3.1 secure
|
|
* protocol which uses this transport interface to run.
|
|
*/
|
|
interface Parsec3Transport<S> {
|
|
val connectedFlow: StateFlow<Boolean>
|
|
fun close()
|
|
|
|
suspend fun adapter(): Adapter<S>
|
|
} |