首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >twitter4j流推文

twitter4j流推文
EN

Stack Overflow用户
提问于 2013-05-30 15:27:28
回答 1查看 1.3K关注 0票数 0
代码语言:javascript
复制
public static void main(String[] args) throws TwitterException, IOException{
    StatusListener listener = new StatusListener(){
        public void onStatus(Status status) {
        System.out.println(status.getUser().getName() + " : " + status.getText());
}
public void onDeletionNotice(StatusDeletionNotice statusDeletionNotice) {}
public void onTrackLimitationNotice(int numberOfLimitedStatuses) {}
public void onException(Exception ex) {
             ex.printStackTrace();
}

我正在使用上面的代码来下载流媒体推文。我得到了这个错误。

The type new StatusListener(){} must implement the inherited abstract method StatusListener.onStallWarning(StallWarning)

The type new StatusListener(){} must implement the inherited abstract method StatusListener.onScrubGeo(long, long).

我需要包含任何特定的jar文件吗?

EN

回答 1

Stack Overflow用户

发布于 2015-06-09 21:50:34

不需要包含更多的.jar文件,只需包含以下方法

代码语言:javascript
复制
        public void onStallWarning(StallWarning arg0) {
        }

您的代码将成功编译和运行。

希望这能有所帮助!

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/16830345

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档