Skip to content

Instantly share code, notes, and snippets.

@abohomol
Created October 25, 2018 11:44
Show Gist options
  • Save abohomol/267e559d81e0f25becc19c286ff21acd to your computer and use it in GitHub Desktop.
Save abohomol/267e559d81e0f25becc19c286ff21acd to your computer and use it in GitHub Desktop.
interface CommunicationChannel {
fun connect(credentials: Credentials)
fun disconnect()
fun getChannelDescription(): Description
}
data class Credentials(val secret: String, val key: String)
data class Description(
val numberOfPeers: Int,
val pingIntervalMillis: Long,
val isSecured: Boolean,
val protocolVersion: Version
)
data class Version(val minor: Int, val major: Int)
object Environment {
const val LIVE = "..."
const val BETA = "..."
const val MOCKED = "..."
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment