-
- All Implemented Interfaces:
-
org.gradle.api.Plugin
public interface KotlinCompilerPluginSupportPlugin implements Plugin<Project>
Gradle plugin implementing support for a Kotlin compiler plugin.
In order to be discovered, it should be applied to the project as an ordinary Gradle Plugin before the Kotlin plugin inspects the project model in an afterEvaluate handler.
The default implementation of apply doesn't do anything, but it can be overridden.
Then its isApplicable is checked against compilations of the project, and if it returns true, then applyToCompilation may be called later.
-
-
Method Summary
Modifier and Type Method Description Unit
apply(Project target)
abstract Boolean
isApplicable(KotlinCompilation<?> kotlinCompilation)
abstract Provider<List<SubpluginOption>>
applyToCompilation(KotlinCompilation<?> kotlinCompilation)
Configures the compiler plugin to be incorporated into a specific kotlinCompilation. abstract String
getCompilerPluginId()
abstract SubpluginArtifact
getPluginArtifact()
SubpluginArtifact
getPluginArtifactForNative()
Legacy Kotlin/Native-specific plugin artifact.
-
-
-
Method Detail
-
isApplicable
abstract Boolean isApplicable(KotlinCompilation<?> kotlinCompilation)
-
applyToCompilation
abstract Provider<List<SubpluginOption>> applyToCompilation(KotlinCompilation<?> kotlinCompilation)
Configures the compiler plugin to be incorporated into a specific kotlinCompilation. This function is only called on kotlinCompilations approved by isApplicable. The Provider returned from this function may never get queried if the compilation is avoided in the current build.
-
getCompilerPluginId
abstract String getCompilerPluginId()
-
getPluginArtifact
abstract SubpluginArtifact getPluginArtifact()
-
getPluginArtifactForNative
SubpluginArtifact getPluginArtifactForNative()
Legacy Kotlin/Native-specific plugin artifact.
It is used only if Gradle is configured not to use Kotlin/Native embeddable compiler jar (with
kotlin.native.useEmbeddableCompilerJar=false
project property).Otherwise, getPluginArtifact is used by default.
-
-