简体   繁体   English

获取帖子的评论列表-适用于Android 3.0的Facebook SDK

[英]Get comment list of a post - Facebook SDK for Android 3.0

I look at the Request.newRestRequest class but I don't know what to pass to it. 我看着Request.newRestRequest类,但我不知道该如何传递给它。 There is no example which uses this method. 没有使用此方法的示例。 Can you give an example for this? 你能举个例子吗?

If your original rest request was https://api.facebook.com/method/method_name?access_token=oauth_access_token&arg0=value0&arg1=value1 如果您最初的休息请求是https://api.facebook.com/method/method_name?access_token=oauth_access_token&arg0=value0&arg1=value1

Then you would do: 然后,您将执行以下操作:

Bundle b = new Bundle();
b.putString("arg0", "value");
b.putString("arg1", "value1");
Request r = Request.newRestRequest(session, "method_name", b, HttpMethod.GET);

But if you're building a new app, you should really start using the Graph API, since Facebook is in the process of deprecating the REST API as stated on this page . 但是,如果您要构建一个新的应用程序,则应该真正开始使用Graph API,因为Facebook正按照此页面上的说明弃用REST API。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM