diff --git a/chapi-application/src/main/kotlin/chapi/app/analyser/ChapiAnalyser.kt b/chapi-application/src/main/kotlin/chapi/app/analyser/ChapiAnalyser.kt index 1b300e01..77092858 100644 --- a/chapi-application/src/main/kotlin/chapi/app/analyser/ChapiAnalyser.kt +++ b/chapi-application/src/main/kotlin/chapi/app/analyser/ChapiAnalyser.kt @@ -1,6 +1,7 @@ package chapi.app.analyser import chapi.app.analyser.config.ChapiConfig +import chapi.app.analyser.config.Language import chapi.app.analyser.support.IAnalyser import chapi.domain.core.CodeDataStruct @@ -31,6 +32,9 @@ open class ChapiAnalyser( "scala" -> { langAnalyser = ScalaAnalyserApp(config) } + Language.KOTLIN -> { + langAnalyser = KotlinAnalyserApp(config) + } else -> { langAnalyser = JavaAnalyserApp(config) } diff --git a/chapi-application/src/main/kotlin/chapi/app/analyser/config/ChapiConfig.kt b/chapi-application/src/main/kotlin/chapi/app/analyser/config/ChapiConfig.kt index 2184a165..c9cfdf10 100644 --- a/chapi-application/src/main/kotlin/chapi/app/analyser/config/ChapiConfig.kt +++ b/chapi-application/src/main/kotlin/chapi/app/analyser/config/ChapiConfig.kt @@ -4,10 +4,9 @@ data class ChapiConfig( var language: String = "", var withoutTest: Boolean = false, var filterRule: String = "" -) { - -} +) +// TODO replace string value object Language { const val KOTLIN = "kotlin" const val JAVA = "java"