Get authorId from Device - android



我正在使用Android Market api。我用它来检索我的应用程序的所有评论:http://code.google.com/p/android-market-api/wiki/HowToGetAppComments

我的问题是如何知道当前用户的authorId是什么?我只需要知道那个用户是否已经写了评论。

谢谢!

您发布的链接中的示例代码如下:

public void onResult(ResponseContext context, CommentsResponse response)
{
    System.out.println("Response : " + response);
    // response.getComments(0).getAuthorName()
    // response.getComments(0).getCreationTime()
    // ...
}

根据源代码,要获得第一个注释的authorID,例如,您应该能够使用

String id = response.getComments(0).getAuthorID();

最新更新