From 6c4b97fcfd17e69b9f69baf8851100c42ff8a6f7 Mon Sep 17 00:00:00 2001 From: Cedric Beust Date: Fri, 30 Oct 2015 13:03:59 -0700 Subject: [PATCH] Comments. --- src/main/kotlin/com/beust/kobalt/internal/JvmCompiler.kt | 5 +++++ src/main/kotlin/com/beust/kobalt/plugin/java/JavaCompiler.kt | 3 +-- .../kotlin/com/beust/kobalt/plugin/kotlin/KotlinCompiler.kt | 3 +-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/main/kotlin/com/beust/kobalt/internal/JvmCompiler.kt b/src/main/kotlin/com/beust/kobalt/internal/JvmCompiler.kt index 56621df5..f833d777 100644 --- a/src/main/kotlin/com/beust/kobalt/internal/JvmCompiler.kt +++ b/src/main/kotlin/com/beust/kobalt/internal/JvmCompiler.kt @@ -13,6 +13,11 @@ import java.io.File * Also validates the classpath and run all the contributors. */ class JvmCompiler @Inject constructor(val dependencyManager: DependencyManager) { + + /** + * Create a final, enriched CompilerActionInfo from the contributors and the transitive dependencies and + * then pass it to the ICompilerAction. + */ fun doCompile(project: Project?, context: KobaltContext?, action: ICompilerAction, info: CompilerActionInfo) : TaskResult { File(info.outputDir).mkdirs() diff --git a/src/main/kotlin/com/beust/kobalt/plugin/java/JavaCompiler.kt b/src/main/kotlin/com/beust/kobalt/plugin/java/JavaCompiler.kt index 82c4983b..d9c4c3b6 100644 --- a/src/main/kotlin/com/beust/kobalt/plugin/java/JavaCompiler.kt +++ b/src/main/kotlin/com/beust/kobalt/plugin/java/JavaCompiler.kt @@ -47,8 +47,7 @@ class JavaCompiler @Inject constructor(val jvmCompiler: JvmCompiler) { } /** - * Create an ICompilerAction and a CompilerActionInfo suitable to be passed to doCompiler() to perform the - * actual compilation. + * Create an ICompilerAction based on the parameters and send it to JvmCompiler.doCompile(). */ fun compile(project: Project?, context: KobaltContext?, dependencies: List, sourceFiles: List, outputDir: String, args: List) : TaskResult { diff --git a/src/main/kotlin/com/beust/kobalt/plugin/kotlin/KotlinCompiler.kt b/src/main/kotlin/com/beust/kobalt/plugin/kotlin/KotlinCompiler.kt index 03bbc3bf..9100f93f 100644 --- a/src/main/kotlin/com/beust/kobalt/plugin/kotlin/KotlinCompiler.kt +++ b/src/main/kotlin/com/beust/kobalt/plugin/kotlin/KotlinCompiler.kt @@ -52,8 +52,7 @@ class KotlinCompiler @Inject constructor(val localRepo : LocalRepo, } /** - * Create an ICompilerAction and a CompilerActionInfo suitable to be passed to doCompiler() to perform the - * actual compilation. + * Create an ICompilerAction based on the parameters and send it to JvmCompiler.doCompile(). */ fun compile(project: Project?, context: KobaltContext?, compileDependencies: List, otherClasspath: List, source: List, outputDir: String, args: List) : TaskResult {