build(connector): add Compose and split desktop app and server

This commit is contained in:
Anthony
2024-03-30 18:43:11 +01:00
parent 609c8393ae
commit 89451ba849
25 changed files with 361 additions and 49 deletions

View File

@@ -0,0 +1 @@
const val SERVER_PORT = 8080

View File

@@ -0,0 +1,7 @@
class Greeting {
private val platform = getPlatform()
fun greet(): String {
return "Hello, ${platform.name}!"
}
}

View File

@@ -0,0 +1,5 @@
interface Platform {
val name: String
}
expect fun getPlatform(): Platform

View File

@@ -0,0 +1,5 @@
class JVMPlatform: Platform {
override val name: String = "Java ${System.getProperty("java.version")}"
}
actual fun getPlatform(): Platform = JVMPlatform()