本文整理了Java中twitter4j.Twitter.getPublicTimeline()
方法的一些代码示例,展示了Twitter.getPublicTimeline()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Twitter.getPublicTimeline()
方法的具体详情如下:
包路径:twitter4j.Twitter
类名称:Twitter
方法名:getPublicTimeline
[英]Returns the 20 most recent statuses from non-protected users who have set a custom user icon.
This method calls http://twitter.com/statuses/public_timeline
[中]返回设置了自定义用户图标的非受保护用户最近的20种状态。
此方法调用http://twitter.com/statuses/public_timeline
代码示例来源:origin: net.homeip.yusuke/twitter4j
/**
* Returns only public statuses with an ID greater than (that is, more recent than) the specified ID.
* <br>This method calls http://twitter.com/statuses/public_timeline
*
* @param sinceID returns only public statuses with an ID greater than (that is, more recent than) the specified ID
* @return the 20 most recent statuses
* @throws TwitterException when Twitter service or network is unavailable
* @see <a href="http://apiwiki.twitter.com/Twitter-REST-API-Method%3A-statuses-public_timeline">Twitter API Wiki / Twitter REST API Method: statuses public_timeline</a>
* @deprecated use getPublicTimeline(long sinceID) instead
*/
public List<Status> getPublicTimeline(int sinceID) throws
TwitterException {
return getPublicTimeline((long)sinceID);
}
/**
代码示例来源:origin: stackoverflow.com
try {
List<Status> statuses = unauthenticatedTwitter
.getPublicTimeline();
for (Status status : statuses) {
System.out.println(status.getUser().getName() + ":"
代码示例来源:origin: net.homeip.yusuke/twitter4j
System.out.println("Showing public timeline.");
try {
List<Status> statuses = unauthenticatedTwitter.getPublicTimeline();
for (Status status : statuses) {
System.out.println(status.getUser().getName() + ":" +
内容来源于网络,如有侵权,请联系作者删除!