diff --git a/modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/api/Project.kt b/modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/api/Project.kt index 31b0b2cb..4cf4e272 100644 --- a/modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/api/Project.kt +++ b/modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/api/Project.kt @@ -2,9 +2,11 @@ package com.beust.kobalt.api import com.beust.kobalt.TestConfig import com.beust.kobalt.api.annotation.Directive +import com.beust.kobalt.internal.JvmCompilerPlugin import com.beust.kobalt.maven.dependency.MavenDependency import com.beust.kobalt.misc.KFiles import com.beust.kobalt.misc.log +import com.beust.kobalt.project import java.io.File import java.util.* @@ -67,13 +69,12 @@ open class Project( val projectProperties = ProjectProperties() - override fun equals(other: Any?): Boolean { - return name == (other as Project).name - } + override fun equals(other: Any?) = name == (other as Project).name + override fun hashCode() = name.hashCode() - override fun hashCode(): Int { - return name.hashCode() - } + /** Can be used by plug-ins */ + val dependentProjects : List + get() = projectProperties.get(JvmCompilerPlugin.DEPENDENT_PROJECTS) as List companion object { val DEFAULT_SOURCE_DIRECTORIES = setOf("src/main/java", "src/main/kotlin", "src/main/resources")