gpt4 book ai didi

java - 迁移到 New Places SDK 客户端不起作用

转载 作者:行者123 更新时间:2023-11-29 09:26:49 25 4
gpt4 key购买 nike

我正在尝试使用 google 提供的新方法在我的 Android 应用程序上实现地点选取器:这是完整的教程网址:

https://developers.google.com/places/android-sdk/client-migration

但是在将此实现添加到 gradale 时:

implementation 'com.google.android.libraries.places:places:1.0.0'

出现这个错误:

error: cannot access zzbck class file for com.google.android.gms.internal.zzbck not found

这意味着我猜,上面的植入和FCM库之间存在冲突。

这是我的gradle:

dependencies {
implementation 'com.google.android.libraries.places:places:1.0.0'
implementation 'com.google.android.libraries.places:places-compat:1.0.0'
implementation(name:'HERE-sdk', ext:'aar')
implementation project(':base')
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation('com.crashlytics.sdk.android:crashlytics:2.5.5@aar') {
transitive = true;
}
implementation(
[group: 'com.fasterxml.jackson.core', name: 'jackson-annotations', version: '2.4.1'],
)
implementation 'com.nostra13.universalimageloader:universal-image-loader:1.9.4'
implementation 'com.android.support:multidex:1.0.1'
implementation 'com.google.code.gson:gson:2.6.2'
implementation 'com.squareup.picasso:picasso:2.5.2'
implementation 'com.bignerdranch.android:expandablerecyclerview:2.1.1'
//noinspection GradleCompatible
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.squareup:android-times-square:1.6.5@aar'
implementation 'cat.ereza:customactivityoncrash:1.5.0'
implementation 'commons-io:commons-io:2.4'
// implementation 'com.github.bumptech.glide:glide:4.0.0-RC1'
implementation 'com.android.support:design:28.0.0'
implementation 'com.google.android.gms:play-services:11.4.0'
implementation 'com.wang.avi:library:2.1.3'
implementation 'com.mikhaellopez:circularprogressbar:1.1.1'
implementation 'com.android.support.constraint:constraint-layout:1.0.2'
implementation 'com.makeramen:roundedimageview:2.3.0'
implementation 'com.priyankvex:smarttextview:1.0.1'
implementation 'com.github.lespinsideg:panoramagl:0.1.1'
implementation 'me.leolin:ShortcutBadger:1.1.16@aar'
implementation 'com.google.firebase:firebase-core:11.4.0'
implementation 'com.github.rey5137:material:1.2.2'
implementation 'com.android.support:support-v4:28.0.0'
// implementation 'com.google.firebase:firebase-messaging:10.2.1'
implementation 'com.loopj.android:android-async-http:1.4.9'
implementation 'com.squareup.okhttp3:okhttp:3.12.1'
implementation 'com.github.darsh2:MultipleImageSelect:v0.0.4'
// annotationProcessor 'com.github.bumptech.glide:compiler:4.8.0'
// implementation 'com.github.bumptech.glide:glide:4.8.0'
// implementation 'com.github.bumptech.glide:glide:4.4.0'
// annotationProcessor 'com.github.bumptech.glide:compiler:4.4.0'
annotationProcessor 'com.github.bumptech.glide:compiler:4.8.0'
implementation 'com.github.bumptech.glide:glide:3.6.1'
implementation 'com.makeramen:roundedimageview:2.3.0'
implementation 'com.google.firebase:firebase-messaging:11.4.0'
// implementation 'com.google.android.gms:play-services-maps:11.0.4'
implementation 'com.google.android.gms:play-services-maps:11.4.0'
implementation 'com.google.android.gms:play-services-location:11.4.0'
// implementation 'com.github.aliumujib:Nibo:2.0'

}
apply plugin: 'com.google.gms.google-services'

最佳答案

根据谷歌

https://developers.google.com/places/android-sdk/client-migration#install_the_compatibility_library

The Place Picker is only supported in the compatibility library, NOT in the new client library. To continue using the Place Picker, you must install the compatibility library. If you have enabled the previous Places SDK for Android service in the console, do NOT disable it! You must also enable the new API services in the console if you're using them.

将 Places SDK for Android 兼容性库添加到您的项目

dependencies {
implementation 'com.google.android.libraries.places:places-compat:1.1.0'
}

注意您只能安装客户端库或兼容性库,不能同时安装。

记住这一点

IMPORTANT: The Place Picker is deprecated as of January 29, 2019. This feature will be turned off on July 29, 2019, and will no longer be available after that date. To continue using the Place Picker through the deprecation period, do NOT disable the Places SDK for Android service in your Google Cloud Platform project, as doing so will also disable the Place Picker.

关于java - 迁移到 New Places SDK 客户端不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54669201/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com