PlacePicker.getPlace() 已弃用

PlacePicker.getPlace() is deprecated

我正在尝试开发基于 google 地方 API 的应用程序。当我尝试使用

Place place=PlacePicker.getPlace(data,this);

有错误显示 getPlace() 已弃用。 请提出解决方案。 提前致谢!

documentation 状态

This method is deprecated.
Use getPlace(Context, Intent) instead.

您也应该在 Android Studio 中找到此信息。