Examples of Paging


Examples of twitter4j.Paging

    public HomeConsumer(TwitterEndpoint te) {
        super(te);
    }

    public List<Status> pollConsume() throws TwitterException {
        List<Status> list = te.getProperties().getTwitter().getHomeTimeline(new Paging(lastId));
        for (Status s : list) {
            checkLastId(s.getId());
        }
        return list;
    }
View Full Code Here

Examples of twitter4j.Paging

    public DirectMessageConsumer(TwitterEndpoint te) {
        super(te);
    }

    public List<DirectMessage> pollConsume() throws TwitterException {
        List<DirectMessage> list = te.getProperties().getTwitter().getDirectMessages(new Paging(lastId));
        for (DirectMessage dm : list) {
            checkLastId(dm.getId());
        }
        return list;
    }
View Full Code Here

Examples of twitter4j.Paging

    public DirectMessageConsumer(TwitterEndpoint te) {
        this.te = te;
    }

    public List<DirectMessage> pollConsume() throws TwitterException {
        List<DirectMessage> list = te.getTwitter().getDirectMessages(new Paging(lastId));
        for (DirectMessage dm : list) {
            checkLastId(dm.getId());
        }
        return list;
    }
View Full Code Here

Examples of twitter4j.Paging

    public MentionsConsumer(TwitterEndpoint te) {
        this.te = te;
    }

    public List<Status> pollConsume() throws TwitterException {
        List<Status> list = te.getTwitter().getMentions(new Paging(lastId));
        for (Status s : list) {
            checkLastId(s.getId());
        }
        return list;
    }
View Full Code Here

Examples of twitter4j.Paging

    public RetweetsConsumer(TwitterEndpoint te) {
        this.te = te;
    }

    public List<Status> pollConsume() throws TwitterException {
        List<Status> list = te.getTwitter().getRetweetsOfMe(new Paging(lastId));
        for (Status s : list) {
            checkLastId(s.getId());
        }
        return list;
    }
View Full Code Here

Examples of twitter4j.Paging

    public UserConsumer(TwitterEndpoint te) {
        this.te = te;
    }

    public List<Status> pollConsume() throws TwitterException {
        List<Status> list = te.getTwitter().getUserTimeline(te.getProperties().getUser(), new Paging(lastId));
        for (Status s : list) {
            checkLastId(s.getId());
        }
        return list;
    }
View Full Code Here

Examples of twitter4j.Paging

    public HomeConsumer(TwitterEndpoint te) {
        this.te = te;
    }

    public List<Status> pollConsume() throws TwitterException {
        List<Status> list = te.getTwitter().getHomeTimeline(new Paging(lastId));
        for (Status s : list) {
            checkLastId(s.getId());
        }
        return list;
    }
View Full Code Here

Examples of weibo4j.Paging

  public static void main(String[] args) {
    System.setProperty("weibo4j.oauth.consumerKey", Weibo.CONSUMER_KEY);
      System.setProperty("weibo4j.oauth.consumerSecret", Weibo.CONSUMER_SECRET);
    try {
      //获取24小时内前20条用户的微博信息;args[2]:用户ID
      List<Status> statuses = getWeibo(false,args).getUserTimeline(args[2],new Paging(1,200));
      for (Status status : statuses) {
              System.out.println(status.getUser().getName() + ":" +
                                 status.getText());
          }
    } catch (WeiboException e) {
View Full Code Here

Examples of weibo4j.Paging

  public static void main(String[] args) {
    System.setProperty("weibo4j.oauth.consumerKey", Weibo.CONSUMER_KEY);
      System.setProperty("weibo4j.oauth.consumerSecret", Weibo.CONSUMER_SECRET);
        try {
          Weibo weibo = getWeibo(true,args);
          List<Status> list = weibo.getUserTimeline("1748033497", new Paging(1).count(4));
          if(list.size() > 0) {
            Status status = weibo.showStatus(list.get(0).getId());
              System.out.println( status.getId() + "  : "+status.getText());
          }
    } catch (Exception e) {
View Full Code Here

Examples of weibo4j.model.Paging

    Weibo weibo = new Weibo();
    weibo.setToken(at.getAccessToken());
    Timeline tm = new Timeline();
    try {
      Paging paging = new Paging();
      if (page.getCount() >= 0) {
        paging.setCount(page.getCount());
      }
      if (page.getMaxId() >= 0) {
        paging.setMaxId(page.getMaxId());
      }
      if (page.getPage() >= 0) {
        paging.setPage(page.getPage());
      }
      if (page.getSinceId() >= 0) {
        paging.setSinceId(page.getSinceId());
      }

      logger.info("paging:" + paging);
      StatusWapper status = tm.getHomeTimeline(0,
          BlogFeature.getIntValue(feature), paging);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.