JavaToolchainResolver (Gradle API 8.11.1)

Package org.gradle.jvm.toolchain

## Interface JavaToolchainResolver

- All Superinterfaces:
    `BuildService<BuildServiceParameters.None>`

      @Incubating
      public interface JavaToolchainResolver
      extends BuildService<BuildServiceParameters.None>

  Interface that needs to be implemented by Java toolchain provisioning plugins.

  Plugin implementors have to provide the mapping from the Java toolchain request to a download information.

  Since:
    7.6

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `java.util.Optional<JavaToolchainDownload>` | `resolve​(JavaToolchainRequest request)` | Returns a `JavaToolchainDownload` if a Java toolchain matching the provided specification can be provided.

    - ### Methods inherited from interface org.gradle.api.services.BuildService

      `getParameters`

- - ### Method Detail

    - #### resolve

          java.util.Optional<JavaToolchainDownload> resolve​(JavaToolchainRequest request)

      Returns a `JavaToolchainDownload` if a Java toolchain matching the provided specification can be provided.
      Parameters:
        `request` - information about the toolchain needed and the environment it's needed in
      Returns:
        empty Optional if and only if the provided specification can't be matched