回答

0

在Android中没有这个API,对不起。可能有您可以使用的Web服务。

+0

感谢您的回复。任何你可以建议作为教程或帮助材料的例子。 – SilentCoder 2010-12-10 01:58:44

2

这可能会帮助,不知道它是否适用于Android的..

http://code.google.com/apis/maps/documentation/places/

+0

你知道吗,这个地​​方的API有没有可用的cod实例? – SilentCoder 2010-12-22 04:45:46

+0

这是简单的网络服务请求,所以你不需要任何伟大的编码为此目的(我不是一个Android的家伙,虽然我想成为,否则我可以帮助更多),但有一个catch,这个API需要你从谷歌获得一个关键使用这个API。您需要为此提交表单并等待Google的客户端ID。请阅读URL处的文档获取更多信息。它实际上走了很长的路... – Vishwanath 2010-12-22 05:16:54

1

我有同样的问题,使得Android的导航程序。
我结束了使用Yahoo! Local Search网络服务,它工作得很好。

您应该了解Web服务是如何工作的,但基本上您可以使用参数(例如Location,Query(餐厅,咖啡等)和其他参数)创建HTTP GET请求,并获得XML或JSON响应你的选择)。

你的结果做什么,完全由你

加法:
雅虎本地搜索结果默认为XML。
这是如何在Android上的请求的示例:

public void doWebRequest() 
    { 
     try { 
      HttpClient client = new DefaultHttpClient(); 

      String url = "http://local.yahooapis.com/LocalSearchService/V3/localSearch?appid=YahooDemo&query=pizza&zip=94306&results=2";   
      HttpGet request = new HttpGet(url); 

     HttpResponse response = client.execute(request); 
      BufferedInputStream bis = new BufferedInputStream(response.getEntity().getContent()); 
      SAXReader reader = new SAXReader(); 
      handleResponse(reader.read(bis)); 
     } catch (Exception e) { 
     System.err.println(e); 
     } 
    } 

    private void handleResponse(Document doc) { 
// doc is the XML response 
    // process the results here 
} 
0

可能,这可能帮助..

意向意图=新意图(Intent.ACTION_VIEW,Uri.parse(“地理: ?0,0 q =咖啡馆“)); startActivity(intent);