autocompletePredictions
全部标签 我正在使用这个方法:Places.GeoDataApi.getAutocompletePredictions(googleApiClient,query,bounds,AutocompleteFilter.create(null))它需要一个包含东北和西南LatLng点的LatLntBounds对象作为查询的边界,但我不想提供任何对象。尝试了null,但是得到了一个空指针异常尝试过:LatLngsouthWest=newLatLng(85,-180);LatLngnorthEast=newLatLng(-85,180);LatLngBoundsbounds=newLatLngBound
我的目标是使用GooglePlacesAPI进行自动完成预测,现在我想制作某种算法来获取当前位置的纬度和经度,并仅预测100-200公里直径范围内的地点。那么,此时我获取用户当前位置的经纬度,如何设置100-200公里?privatevoidgetCurrentLocation(){mLastLocation=LocationServices.FusedLocationApi.getLastLocation(mGoogleApiClient);if(mLastLocation!=null){doublelatitude=mLastLocation.getLatitude();doubl
我在使用AndroidGooglePlacesAPI-自动完成功能时遇到问题。我使用的key与用于AndroidGoogleMapsAPI的key相同(在文档中,这样写是可以的)。这是我在list中的定义:但getAutocompletePredictions会返回“PLACES_API_ACCESS_NOT_CONFIGURED”消息作为状态。这是我的Java代码:GoogleApiClientgoogleApiClient=newGoogleApiClient.Builder(context).addApi(Places.GEO_DATA_API).addApi(Places.PL
我在使用AndroidGooglePlacesAPI-自动完成功能时遇到问题。我使用的key与用于AndroidGoogleMapsAPI的key相同(在文档中,这样写是可以的)。这是我在list中的定义:但getAutocompletePredictions会返回“PLACES_API_ACCESS_NOT_CONFIGURED”消息作为状态。这是我的Java代码:GoogleApiClientgoogleApiClient=newGoogleApiClient.Builder(context).addApi(Places.GEO_DATA_API).addApi(Places.PL
我将我的gms版本从8.4.0升级到9.6.0。在SyncNow之后我破坏了很多东西。AutocompletePrediction在9.6.0版本中是否被移除?升级前:compile'com.google.android.gms:play-services-gcm:8.4.0'compile'com.google.android.gms:play-services-maps:8.4.0'compile'com.google.android.gms:play-services-location:8.4.0'compile'com.google.android.gms:play-servi
由于firebase,我将播放服务升级到9.4.0后,因为它必须为firebase添加最新版本9.0.0或更高版本,我面临的问题是AutocompletePredictionprediction.getDescription()现在显示为未找到我的项目,除了Gradle更新,我没有改变任何东西,我认为新的播放服务缺少.getDescription方法,请帮助我这是我的新Gradle`compile'com.google.firebase:firebase-core:9.4.0'compile'org.osmdroid:osmdroid-android:5.1@aar'compile'c