2016-09-23 76 views
3

我將gms的版本從8.4.0升級到9.6.0。 Sync Now後我會分解很多東西。 AutocompletePrediction是否已在9.6.0版本中刪除?找不到符號類AutocompletePrediction

之前升級:

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-services-analytics:8.4.0' 

升級後:

compile 'com.google.android.gms:play-services-gcm:9.6.0' 
compile 'com.google.android.gms:play-services-maps:9.6.0' 
compile 'com.google.android.gms:play-services-location:9.6.0' 
compile 'com.google.android.gms:play-services-analytics:9.6.0' 

堆棧跟蹤:

Error:(15, 46) error: cannot find symbol class AutocompleteFilter 
Error:(16, 46) error: cannot find symbol class AutocompletePrediction 
Error:(17, 46) error: cannot find symbol class AutocompletePredictionBuffer 
Error:(18, 46) error: cannot find symbol class Places 
Error:(48, 13) error: cannot find symbol class AutocompleteFilter 
Error:(51, 83) error: cannot find symbol class AutocompleteFilter 
Error:(110, 23) error: cannot find symbol class AutocompletePrediction 
Error:Execution failed for task ':app:compileClientReleaseJavaWithJavac'. 
Compilation failed; see the compiler error output for details. 

回答

6

除了增加你也需要添加播放服務,地方戲的服務定位庫圖書館作爲地方和自動完成類已被移動到該庫,在我的情況下,我使用

compile 'com.google.android.gms:play-services-places:9.6.1'