[Gradle] Deprecate rare api in KotlinDependencyHandler
Recommend users default `project.dependencies` instead. Gradle's DependencyHanlder has its own evolution thus we cannot easily maintain API of KotlinDependencyHandler to look like Gradle's DependencyHandler. We're going to support only our own factory methods to create dependencies + `project` dependencies. KT-58759 Verification Pending
This commit is contained in:
committed by
Space Team
parent
1a29b9efff
commit
b3b0f23a50
+16
@@ -59,15 +59,31 @@ interface KotlinDependencyHandler {
|
|||||||
|
|
||||||
fun project(notation: Map<String, Any?>): ProjectDependency
|
fun project(notation: Map<String, Any?>): ProjectDependency
|
||||||
|
|
||||||
|
@Deprecated(
|
||||||
|
"Scheduled for removal in Kotlin 2.0. Check KT-58759",
|
||||||
|
replaceWith = ReplaceWith("project.dependencies.enforcedPlatform(notation)")
|
||||||
|
)
|
||||||
fun enforcedPlatform(notation: Any): Dependency =
|
fun enforcedPlatform(notation: Any): Dependency =
|
||||||
project.dependencies.enforcedPlatform(notation)
|
project.dependencies.enforcedPlatform(notation)
|
||||||
|
|
||||||
|
@Deprecated(
|
||||||
|
"Scheduled for removal in Kotlin 2.0. Check KT-58759",
|
||||||
|
replaceWith = ReplaceWith("project.dependencies.enforcedPlatform(notation, configureAction)")
|
||||||
|
)
|
||||||
fun enforcedPlatform(notation: Any, configureAction: Action<in Dependency>): Dependency =
|
fun enforcedPlatform(notation: Any, configureAction: Action<in Dependency>): Dependency =
|
||||||
project.dependencies.enforcedPlatform(notation, configureAction)
|
project.dependencies.enforcedPlatform(notation, configureAction)
|
||||||
|
|
||||||
|
@Deprecated(
|
||||||
|
"Scheduled for removal in Kotlin 2.0. Check KT-58759",
|
||||||
|
replaceWith = ReplaceWith("project.dependencies.platform(notation)")
|
||||||
|
)
|
||||||
fun platform(notation: Any): Dependency =
|
fun platform(notation: Any): Dependency =
|
||||||
project.dependencies.platform(notation)
|
project.dependencies.platform(notation)
|
||||||
|
|
||||||
|
@Deprecated(
|
||||||
|
"Scheduled for removal in Kotlin 2.0. Check KT-58759",
|
||||||
|
replaceWith = ReplaceWith("project.dependencies.platform(notation, configureAction)")
|
||||||
|
)
|
||||||
fun platform(notation: Any, configureAction: Action<in Dependency>): Dependency =
|
fun platform(notation: Any, configureAction: Action<in Dependency>): Dependency =
|
||||||
project.dependencies.platform(notation, configureAction)
|
project.dependencies.platform(notation, configureAction)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user