Deprecated List (Gradle API 9.6.1)
Description: deprecated elements

# Deprecated API

## Contents

- Interfaces
- Classes
- Enums
- Exception Classes
- Annotation Types
- Fields
- Methods
- Enum Constants

- Deprecated Interfaces
  Interface
  Description
  org.gradle.api.execution.TaskActionListener
  This type is not supported when configuration caching is enabled.
  org.gradle.api.execution.TaskExecutionListener
  This type is not supported when configuration caching is enabled.

- Deprecated Classes
  Class
  Description
  org.gradle.api.reporting.components.ComponentReport
  org.gradle.api.reporting.dependents.DependentComponentsReport
  org.gradle.api.reporting.model.ModelReport
  org.gradle.api.tasks.diagnostics.AbstractReportTask
  Use `AbstractProjectBasedReportTask` instead.
  org.gradle.api.tasks.diagnostics.ProjectBasedReportTask
  Use `AbstractProjectBasedReportTask` instead.
  org.gradle.plugins.ide.eclipse.GenerateEclipseClasspath
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.GenerateEclipseJdt
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.GenerateEclipseProject
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.GenerateEclipseWtpComponent
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.GenerateEclipseWtpFacet
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseWtp
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseWtpComponent
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseWtpFacet
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.GenerateIdeaModule
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.GenerateIdeaProject
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.GenerateIdeaWorkspace
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModuleIml
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaWorkspace
  Will be removed in Gradle 10.

- Deprecated Enums
  Enum
  Description
  org.gradle.api.plugins.quality.TargetJdk
  This type is only used by the deprecated `targetJdk` property on the PMD plugin. It will be removed in Gradle 10. PMD 5.0 and later infer the Java language version from the rule sets.

- Deprecated Exception Classes
  Exception Class
  Description
  org.gradle.api.UncheckedIOException
  Use java.io.UncheckedIOException instead. Will be removed in Gradle 10.

- Deprecated Annotation Types
  Annotation Type
  Description
  org.gradle.api.NonNullApi
  Deprecated in Gradle 9 for removal in Gradle 10. Prefer JSpecify annotations such as `NullMarked` and `Nullable`. Note that you can also still use JSR305 annotations such as `Nonnull` and `Nullable`.

- Deprecated Fields
  Field
  Description
  org.gradle.api.plugins.JavaBasePlugin.BUILD_DEPENDENTS_TASK_NAME
  org.gradle.api.plugins.JavaBasePlugin.BUILD_NEEDED_TASK_NAME
  org.gradle.plugin.devel.plugins.JavaGradlePluginPlugin.API_CONFIGURATION

- Deprecated Methods
  Method
  Description
  org.gradle.api.artifacts.ComponentSelectionRules.all(Object)
  use `ComponentSelectionRules.all(Action)` instead.
  org.gradle.api.artifacts.ComponentSelectionRules.withModule(Object, Object)
  use `ComponentSelectionRules.withModule(Object,Action)` instead.
  org.gradle.api.artifacts.Configuration.getTaskDependencyFromProjectDependency(boolean, String)
  This method will be removed in Gradle 10.
  org.gradle.api.artifacts.Configuration.isVisible()
  This property is deprecated and will be removed in Gradle 10.
  org.gradle.api.artifacts.Configuration.setVisible(boolean)
  This property is deprecated and will be removed in Gradle 10.
  org.gradle.api.artifacts.DependenciesMetadata.add(Map<String, String>)
  This method will be removed in Gradle 10. Use `DependenciesMetadata.add(String)` instead.
  org.gradle.api.artifacts.DependenciesMetadata.add(Map<String, String>, Action<? super T>)
  This method will be removed in Gradle 10. Use `DependenciesMetadata.add(String, Action)` instead.
  org.gradle.api.artifacts.dsl.ComponentMetadataHandler.all(Object)
  Use `ComponentMetadataHandler.all(Action)` or `ComponentMetadataHandler.all(Class)` instead.
  org.gradle.api.artifacts.dsl.ComponentMetadataHandler.withModule(Object, Object)
  Use `ComponentMetadataHandler.withModule(Object, Action)` or `ComponentMetadataHandler.withModule(Object, Class)` instead.
  org.gradle.api.artifacts.dsl.Dependencies.getObjectFactory()
  This method is deprecated and will be removed in Gradle 10.
  org.gradle.api.artifacts.dsl.Dependencies.getProject()
  This method is deprecated and will be removed in Gradle 10.
  org.gradle.api.artifacts.dsl.Dependencies.module(String, String, String)
  This method will be removed in Gradle 10. Use single-string notation instead.
  org.gradle.api.artifacts.dsl.DependencyFactory.create(Project)
  Use `DependencyFactory.createProjectDependency(String)` instead. This method will be removed in Gradle 10.0.
  org.gradle.api.artifacts.dsl.RepositoryHandler.flatDir(Map<String, ?>)
  This method is scheduled to be removed in Gradle 10. Use `RepositoryHandler.flatDir(Action)` instead.
  org.gradle.api.artifacts.dsl.RepositoryHandler.mavenCentral(Map<String, ?>)
  This method is scheduled to be removed in Gradle 10. Use `RepositoryHandler.mavenCentral(Action)` instead.
  org.gradle.api.artifacts.repositories.MavenArtifactRepository.artifactUrls(Object...)
  Maven repositories with separate locations for POMs and artifacts are a Gradle-only feature with no equivalent in Maven. This method is scheduled to be removed in Gradle 10.
  org.gradle.api.artifacts.repositories.MavenArtifactRepository.getArtifactUrls()
  Maven repositories with separate locations for POMs and artifacts are a Gradle-only feature with no equivalent in Maven. This method is scheduled to be removed in Gradle 10.
  org.gradle.api.artifacts.repositories.MavenArtifactRepository.setArtifactUrls(Iterable<?>)
  Maven repositories with separate locations for POMs and artifacts are a Gradle-only feature with no equivalent in Maven. This method is scheduled to be removed in Gradle 10.
  org.gradle.api.artifacts.repositories.MavenArtifactRepository.setArtifactUrls(Set<URI>)
  Maven repositories with separate locations for POMs and artifacts are a Gradle-only feature with no equivalent in Maven. This method is scheduled to be removed in Gradle 10.
  org.gradle.api.DomainObjectCollection.findAll(Closure)
  Use `DomainObjectCollection.matching(Spec)` or Collection APIs from the JDK.
  org.gradle.api.DomainObjectSet.findAll(Closure)
  org.gradle.api.execution.TaskExecutionGraph.addTaskExecutionListener(TaskExecutionListener)
  This method is not supported when configuration caching is enabled.
  org.gradle.api.execution.TaskExecutionGraph.afterTask(Closure)
  This method is not supported when configuration caching is enabled.
  org.gradle.api.execution.TaskExecutionGraph.afterTask(Action<Task>)
  This method is not supported when configuration caching is enabled.
  org.gradle.api.execution.TaskExecutionGraph.beforeTask(Closure)
  This method is not supported when configuration caching is enabled.
  org.gradle.api.execution.TaskExecutionGraph.beforeTask(Action<Task>)
  This method is not supported when configuration caching is enabled.
  org.gradle.api.execution.TaskExecutionGraph.removeTaskExecutionListener(TaskExecutionListener)
  This method is not supported when configuration caching is enabled.
  org.gradle.api.invocation.Gradle.buildFinished(Closure)
  This method is not supported when configuration caching is enabled.
  org.gradle.api.invocation.Gradle.buildFinished(Action<? super BuildResult>)
  This method is not supported when configuration caching is enabled.
  org.gradle.api.invocation.Gradle.useLogger(Object)
  Will be removed in Gradle 10. Logging customization through listeners is no longer supported.
  org.gradle.api.NamedDomainObjectList.findAll(Closure)
  org.gradle.api.NamedDomainObjectSet.findAll(Closure)
  org.gradle.api.plugins.PluginCollection.add(T)
  Use `PluginManager.apply(Class)` instead.
  org.gradle.api.plugins.PluginCollection.addAll(Collection<? extends T>)
  Use `PluginManager.apply(Class)` instead.
  org.gradle.api.plugins.PluginCollection.clear()
  plugins cannot be removed.
  org.gradle.api.plugins.PluginCollection.remove(Object)
  plugins cannot be removed.
  org.gradle.api.plugins.PluginCollection.removeAll(Collection<?>)
  plugins cannot be removed.
  org.gradle.api.plugins.quality.Pmd.getTargetJdk()
  This property has no effect for PMD 5.0 and later, which infer the language version from the rule sets. Scheduled to be removed in Gradle 10.
  org.gradle.api.plugins.quality.Pmd.setTargetJdk(TargetJdk)
  This property has no effect for PMD 5.0 and later, which infer the language version from the rule sets. Scheduled to be removed in Gradle 10.
  org.gradle.api.plugins.quality.PmdExtension.getTargetJdk()
  This property has no effect for PMD 5.0 and later, which infer the language version from the rule sets. Scheduled to be removed in Gradle 10.
  org.gradle.api.plugins.quality.PmdExtension.setTargetJdk(Object)
  This property has no effect for PMD 5.0 and later, which infer the language version from the rule sets. Scheduled to be removed in Gradle 10.
  org.gradle.api.plugins.quality.PmdExtension.setTargetJdk(TargetJdk)
  This property has no effect for PMD 5.0 and later, which infer the language version from the rule sets. Scheduled to be removed in Gradle 10.
  org.gradle.api.plugins.quality.PmdPlugin.getDefaultTargetJdk(JavaVersion)
  The `targetJdk` property has no effect for PMD 5.0 and later. Scheduled to be removed in Gradle 10.
  org.gradle.api.problems.ProblemSpec.severity(Severity)
  Severity is now determined automatically: use `ProblemReporter.report(org.gradle.api.problems.ProblemId, org.gradle.api.Action<? super org.gradle.api.problems.ProblemSpec>)` for warnings and `ProblemReporter.throwing(java.lang.Throwable, org.gradle.api.problems.ProblemId, org.gradle.api.Action<? super org.gradle.api.problems.ProblemSpec>)` for errors.
  org.gradle.api.Project.container(Class<T>)
  Use `ObjectFactory.domainObjectContainer(Class)` instead.
  org.gradle.api.Project.container(Class<T>, Closure)
  Use `ObjectFactory.domainObjectContainer(Class, NamedDomainObjectFactory)` instead.
  org.gradle.api.Project.container(Class<T>, NamedDomainObjectFactory<T>)
  Use `ObjectFactory.domainObjectContainer(Class, NamedDomainObjectFactory)` instead.
  org.gradle.api.Project.getBuildDir()
  Use `getLayout().getBuildDirectory()` instead
  org.gradle.api.Project.getProperties()
  This method will be removed in Gradle 10.0.0. Use `Project.findProperty(String)` or `ProviderFactory.gradleProperty(String)` instead. See the upgrade guide for more details.
  org.gradle.api.Project.setBuildDir(File)
  Use `getLayout().getBuildDirectory()` and set the `DirectoryProperty`
  org.gradle.api.Project.setBuildDir(Object)
  Use `getLayout().getBuildDirectory()` and set the `DirectoryProperty`
  org.gradle.api.Project.task(String)
  Use `tasks.register(String)` instead
  org.gradle.api.Project.task(String, Closure)
  Use `tasks.register(String, Action)` instead
  org.gradle.api.Project.task(String, Action<? super Task>)
  Use `tasks.register(String, Action)` instead
  org.gradle.api.Project.task(Map<String, ?>, String)
  Use a `tasks.register` variant instead
  org.gradle.api.Project.task(Map<String, ?>, String, Closure)
  Use a `tasks.register` variant instead
  org.gradle.api.reporting.ReportingExtension.file(String)
  Use `getBaseDirectory().file(path)` or `getBaseDirectory().dir(path)` instead.
  org.gradle.api.reporting.ReportingExtension.getApiDocTitle()
  Use your own way of generating a title for API documentation.
  org.gradle.api.tasks.diagnostics.BuildEnvironmentReportTask.getClientMetaData()
  org.gradle.api.tasks.diagnostics.DependencyInsightReportTask.getImmutableAttributesFactory()
  org.gradle.api.tasks.TaskContainer.create(String)
  Use `TaskContainer.register(String)` instead. See documentation for more information.
  org.gradle.api.tasks.TaskContainer.create(String, Closure)
  Use `TaskContainer.register(String, Action)` instead. See documentation for more information.
  org.gradle.api.tasks.TaskContainer.create(String, Class<T>)
  Use `TaskContainer.register(String, Class)` instead. See documentation for more information.
  org.gradle.api.tasks.TaskContainer.create(String, Class<T>, Object...)
  Use `TaskContainer.register(String, Class, Object...)` instead. See documentation for more information.
  org.gradle.api.tasks.TaskContainer.create(String, Class<T>, Action<? super T>)
  Use `TaskContainer.register(String, Class, Action)` instead. See documentation for more information.
  org.gradle.api.tasks.TaskContainer.create(String, Action<? super Task>)
  Use `TaskContainer.register(String, Action)` instead. See documentation for more information.
  org.gradle.api.tasks.TaskContainer.create(Map<String, ?>)
  Use `TaskContainer.register(String, Action)` or `TaskContainer.register(String, Class, Action)` instead. See documentation for more information.
  org.gradle.api.tasks.TaskContainer.create(Map<String, ?>, Closure)
  Use `TaskContainer.register(String, Action)` instead. See documentation for more information.
  org.gradle.api.tasks.testing.AbstractTestTask.afterSuite(Closure)
  Replace with `AbstractTestTask.addTestListener(TestListener)` and a `TestListener`.
  org.gradle.api.tasks.testing.AbstractTestTask.afterTest(Closure)
  Replace with `AbstractTestTask.addTestListener(TestListener)` and a `TestListener`.
  org.gradle.api.tasks.testing.AbstractTestTask.beforeSuite(Closure)
  Replace with `AbstractTestTask.addTestListener(TestListener)` and a `TestListener`.
  org.gradle.api.tasks.testing.AbstractTestTask.beforeTest(Closure)
  Replace with `AbstractTestTask.addTestListener(TestListener)` and a `TestListener`.
  org.gradle.api.tasks.testing.AbstractTestTask.onOutput(Closure)
  Replace with `AbstractTestTask.addTestOutputListener(TestOutputListener)` and a `TestOutputListener`.
  org.gradle.api.tasks.testing.AbstractTestTask.setTestReporter(TestReporter)
  Only present for compatibility with cashapp/paparazzi. No replacement.
  org.gradle.api.tasks.testing.Test.testFramework(Closure)
  This will be removed in Gradle 10
  org.gradle.api.tasks.testing.TestReport.getBuildOperationExecutor()
  org.gradle.api.tasks.testing.TestReport.getBuildOperationRunner()
  org.gradle.api.tasks.testing.TestReport.getMetadataRendererRegistry()
  org.gradle.api.tasks.wrapper.Wrapper.getAvailableDistributionTypes()
  Since 9.3.0. Use `Wrapper.DistributionType.values()` directly instead.
  org.gradle.BuildAdapter.buildFinished(BuildResult)
  org.gradle.BuildListener.buildFinished(BuildResult)
  This method is not supported when configuration caching is enabled.
  org.gradle.jvm.application.tasks.CreateStartScripts.getExitEnvironmentVar()
  No longer used in the default start script templates. Will be removed in Gradle 10.
  org.gradle.jvm.application.tasks.CreateStartScripts.setExitEnvironmentVar(String)
  org.gradle.plugins.ide.eclipse.model.EclipseJdt.file(Closure)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseJdt.file(Action<? super PropertiesFileContentMerger>)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseJdt.getFile()
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseJdt.getJavaRuntimeName()
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseJdt.setJavaRuntimeName(String)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseModel.getWtp()
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseModel.setWtp(EclipseWtp)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseModel.wtp(Closure)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.eclipse.model.EclipseModel.wtp(Action<? super EclipseWtp>)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModel.getWorkspace()
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModel.setWorkspace(IdeaWorkspace)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModel.workspace(Closure)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModel.workspace(Action<? super IdeaWorkspace>)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModule.getIml()
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModule.getPathFactory()
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModule.iml(Closure)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModule.iml(Action<? super IdeaModuleIml>)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModule.mergeXmlModule(Module)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaModule.setPathFactory(PathFactory)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaProject.getIpr()
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaProject.getPathFactory()
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaProject.ipr(Closure)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaProject.ipr(Action<? super XmlFileContentMerger>)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaProject.mergeXmlProject(Project)
  Will be removed in Gradle 10.
  org.gradle.plugins.ide.idea.model.IdeaProject.setPathFactory(PathFactory)
  Will be removed in Gradle 10.
  org.gradle.process.JavaForkOptions.setAllJvmArgs(Iterable<?>)
  org.gradle.process.JavaForkOptions.setAllJvmArgs(List<String>)
  org.gradle.StartParameter.isConfigurationCacheRequested()
  Use `Configuration Cache build feature` instead.
  org.gradle.util.Path.getPath()
  use `Path.asString()` instead

- Deprecated Enum Constants
  Enum Constant
  Description
  org.gradle.api.problems.Severity.ADVICE
  Only kept for backward compatibility. Will be removed in Gradle 10.0.