aboutsummaryrefslogtreecommitdiff
path: root/integration
diff options
context:
space:
mode:
Diffstat (limited to 'integration')
-rw-r--r--integration/src/main/kotlin/org/jetbrains/dokka/configuration.kt22
1 files changed, 22 insertions, 0 deletions
diff --git a/integration/src/main/kotlin/org/jetbrains/dokka/configuration.kt b/integration/src/main/kotlin/org/jetbrains/dokka/configuration.kt
index 69d19944..287b628a 100644
--- a/integration/src/main/kotlin/org/jetbrains/dokka/configuration.kt
+++ b/integration/src/main/kotlin/org/jetbrains/dokka/configuration.kt
@@ -17,6 +17,27 @@ class UrlSerializer : ValueSerializer<URL?> {
override fun toJsonValue(value: URL?): Any? = value?.toExternalForm()
}
+enum class Platform(val key: String) {
+ jvm("jvm"),
+ js("js"),
+ common("common");
+
+
+ companion object {
+ val DEFAULT = jvm
+
+ fun fromString(key: String): Platform {
+ return when (key.toLowerCase()) {
+ jvm.key -> jvm
+ js.key -> js
+ common.key -> common
+ else -> TODO("write normal exception")
+ }
+ }
+ }
+
+}
+
interface DokkaConfiguration {
val moduleName: String
val classpath: List<String>
@@ -47,6 +68,7 @@ interface DokkaConfiguration {
interface SourceRoot {
val path: String
val platforms: List<String>
+ val analysisPlatform: Platform
}
interface SourceLinkDefinition {