Class GradleBuildToolAdapter
java.lang.Object
io.github.bud127.modulecomposer.plugin.GradleBuildToolAdapter
- All Implemented Interfaces:
io.github.bud127.modulecomposer.core.BuildToolAdapter
public final class GradleBuildToolAdapter
extends Object
implements io.github.bud127.modulecomposer.core.BuildToolAdapter
Gradle implementation of the generic build-tool adapter contract.
-
Constructor Summary
ConstructorsConstructorDescriptionGradleBuildToolAdapter(org.gradle.api.Project root) Creates an adapter for the given root project. -
Method Summary
Modifier and TypeMethodDescriptionorg.gradle.api.provider.Provider<String>archiveFilePath(String taskPath) Resolves the archive file path produced by an archive task.io.github.bud127.modulecomposer.core.BuildInvocationgeneratedBuild(io.github.bud127.modulecomposer.core.FrameworkAdapter frameworkAdapter) io.github.bud127.modulecomposer.core.BuildInvocationgeneratedRun(io.github.bud127.modulecomposer.core.FrameworkAdapter frameworkAdapter) io.github.bud127.modulecomposer.core.BuildInvocationmoduleArtifact(io.github.bud127.modulecomposer.core.ModuleRegistration module) io.github.bud127.modulecomposer.core.BuildInvocationprojectArtifact(String projectReference) booleanprojectExists(String projectReference) org.gradle.api.ProjectprojectForTaskPath(String taskPath) Finds the project that owns the given Gradle task path.io.github.bud127.modulecomposer.core.BuildInvocationstandaloneBuild(io.github.bud127.modulecomposer.core.FrameworkAdapter frameworkAdapter, io.github.bud127.modulecomposer.core.ModuleRegistration module) io.github.bud127.modulecomposer.core.BuildInvocationstandaloneRun(io.github.bud127.modulecomposer.core.FrameworkAdapter frameworkAdapter, io.github.bud127.modulecomposer.core.ModuleRegistration module) Extracts the task name from a Gradle task path.
-
Constructor Details
-
GradleBuildToolAdapter
public GradleBuildToolAdapter(org.gradle.api.Project root) Creates an adapter for the given root project.- Parameters:
root- root Gradle project
-
-
Method Details
-
buildToolId
- Specified by:
buildToolIdin interfaceio.github.bud127.modulecomposer.core.BuildToolAdapter
-
projectExists
- Specified by:
projectExistsin interfaceio.github.bud127.modulecomposer.core.BuildToolAdapter
-
standaloneRun
public io.github.bud127.modulecomposer.core.BuildInvocation standaloneRun(io.github.bud127.modulecomposer.core.FrameworkAdapter frameworkAdapter, io.github.bud127.modulecomposer.core.ModuleRegistration module) - Specified by:
standaloneRunin interfaceio.github.bud127.modulecomposer.core.BuildToolAdapter
-
standaloneBuild
public io.github.bud127.modulecomposer.core.BuildInvocation standaloneBuild(io.github.bud127.modulecomposer.core.FrameworkAdapter frameworkAdapter, io.github.bud127.modulecomposer.core.ModuleRegistration module) - Specified by:
standaloneBuildin interfaceio.github.bud127.modulecomposer.core.BuildToolAdapter
-
moduleArtifact
public io.github.bud127.modulecomposer.core.BuildInvocation moduleArtifact(io.github.bud127.modulecomposer.core.ModuleRegistration module) - Specified by:
moduleArtifactin interfaceio.github.bud127.modulecomposer.core.BuildToolAdapter
-
projectArtifact
public io.github.bud127.modulecomposer.core.BuildInvocation projectArtifact(String projectReference) - Specified by:
projectArtifactin interfaceio.github.bud127.modulecomposer.core.BuildToolAdapter
-
generatedRun
public io.github.bud127.modulecomposer.core.BuildInvocation generatedRun(io.github.bud127.modulecomposer.core.FrameworkAdapter frameworkAdapter) - Specified by:
generatedRunin interfaceio.github.bud127.modulecomposer.core.BuildToolAdapter
-
generatedBuild
public io.github.bud127.modulecomposer.core.BuildInvocation generatedBuild(io.github.bud127.modulecomposer.core.FrameworkAdapter frameworkAdapter) - Specified by:
generatedBuildin interfaceio.github.bud127.modulecomposer.core.BuildToolAdapter
-
archiveFilePath
Resolves the archive file path produced by an archive task.- Parameters:
taskPath- task path to anAbstractArchiveTask- Returns:
- provider for the produced archive absolute path
-
projectForTaskPath
Finds the project that owns the given Gradle task path.- Parameters:
taskPath- Gradle task path- Returns:
- owning project
-
taskName
Extracts the task name from a Gradle task path.- Parameters:
taskPath- Gradle task path- Returns:
- task name
-