Could not find method implementation() for arguments […] on object of type org.gradle.api.internal.artifacts.dsl.depende

huangapple 未分类评论48阅读模式
英文:

Could not find method implementation() for arguments [...] on object of type org.gradle.api.internal.artifacts.dsl.depende

问题

我在与Gradle同步项目时遇到了错误消息。我的错误消息是:

  1. Caused by: org.gradle.internal.metaobject.AbstractDynamicObject$CustomMessageMissingMethodException:
  2. 无法在类型为org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler的对象上找到方法implementation(),参数为
  3. [DefaultProjectDependency{dependencyProject='project ':mobilertc''configuration='default'}]。

我的build.gradle文件如下:

  1. apply plugin: 'com.android.application'
  2. apply plugin: 'com.google.gms.google-services'
  3. android {
  4. compileSdkVersion 29
  5. buildToolsVersion "29.0.3"
  6. defaultConfig {
  7. applicationId "com.CS.kba"
  8. minSdkVersion 16
  9. targetSdkVersion 29
  10. versionCode 1
  11. versionName "1.0"
  12. testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  13. }
  14. buildTypes {
  15. release {
  16. minifyEnabled false
  17. proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
  18. }
  19. }
  20. }
  21. dependencies {
  22. implementation 'androidx.appcompat:appcompat:1.1.0'
  23. implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
  24. implementation 'com.google.firebase:firebase-auth:19.3.1'
  25. implementation 'com.google.firebase:firebase-analytics:17.4.0'
  26. implementation 'androidx.navigation:navigation-fragment:2.2.2'
  27. implementation 'androidx.navigation:navigation-ui:2.2.2'
  28. testImplementation 'junit:junit:4.13'
  29. androidTestImplementation 'androidx.test.ext:junit:1.1.1'
  30. androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
  31. implementation 'com.google.android.material:material:1.1.0'
  32. }

我正在将Zoom API集成到我的应用程序中。我按照文档中的说明进行操作。问题是在我添加了一些模块和库作为依赖后出现的。

英文:

I'm getting an error message while syncing the project with gradle. My error message is:

  1. Caused by: org.gradle.internal.metaobject.AbstractDynamicObject$CustomMessageMissingMethodException:
  2. Could not find method implementation() for arguments
  3. [DefaultProjectDependency{dependencyProject='project ':mobilertc'', configuration='default'}] on
  4. object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.

My build.gradle file

  1. apply plugin: 'com.android.application'
  2. apply plugin: 'com.google.gms.google-services'
  3. android {
  4. compileSdkVersion 29
  5. buildToolsVersion "29.0.3"
  6. defaultConfig {
  7. applicationId "com.CS.kba"
  8. minSdkVersion 16
  9. targetSdkVersion 29
  10. versionCode 1
  11. versionName "1.0"
  12. testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
  13. }
  14. buildTypes {
  15. release {
  16. minifyEnabled false
  17. proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
  18. }
  19. }
  20. }
  21. dependencies {
  22. implementation 'androidx.appcompat:appcompat:1.1.0'
  23. implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
  24. implementation 'com.google.firebase:firebase-auth:19.3.1'
  25. implementation 'com.google.firebase:firebase-analytics:17.4.0'
  26. implementation 'androidx.navigation:navigation-fragment:2.2.2'
  27. implementation 'androidx.navigation:navigation-ui:2.2.2'
  28. testImplementation 'junit:junit:4.13'
  29. androidTestImplementation 'androidx.test.ext:junit:1.1.1'
  30. androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
  31. implementation 'com.google.android.material:material:1.1.0'
  32. }

I'm working on ingratiating zoom API to my app. I just did as the documentation said. The problem raised after I have added some modules and libraries as dependencies.

huangapple
  • 本文由 发表于 2020年5月4日 04:15:33
  • 转载请务必保留本文链接:https://java.coder-hub.com/61581025.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定