api / org.gradle.kotlin.dsl.plugins.embedded / EmbeddedKotlinPlugin

EmbeddedKotlinPlugin

open class EmbeddedKotlinPlugin : Plugin<Project>

The embedded-kotlin plugin.

Applies the org.jetbrains.kotlin.jvm plugin, adds compile only dependencies on kotlin-stdlib and kotlin-reflect, configures an embedded repository that contains all embedded Kotlin libraries, and pins them to the embedded Kotlin version.

Functions

apply

open fun apply(project: Project): Unit

Extension Functions

closureOf

fun <T> Any.closureOf(action: T.() -> Unit): Closure<Any?>

Adapts a Kotlin function to a single argument Groovy Closure.

delegateClosureOf

fun <T> Any.delegateClosureOf(action: T.() -> Unit): Closure<Unit>

Adapts a Kotlin function to a Groovy Closure that operates on the configured Closure delegate.

withConvention

fun <ConventionType : Any, ReturnType> Any.withConvention(conventionType: KClass<ConventionType>, function: ConventionType.() -> ReturnType): ReturnType

Evaluates the given function against the convention plugin of the given conventionType.

withGroovyBuilder

fun <T> Any.withGroovyBuilder(builder: GroovyBuilderScope.() -> T): T

Executes the given builder against this object's GroovyBuilderScope.