Package weibo4j.examples.friendships

Source Code of weibo4j.examples.friendships.GetFriendsChainFollowers

package weibo4j.examples.friendships;

import weibo4j.Friendships;
import weibo4j.Weibo;
import weibo4j.examples.oauth2.Log;
import weibo4j.model.User;
import weibo4j.model.UserWapper;
import weibo4j.model.WeiboException;

public class GetFriendsChainFollowers {

  public static void main(String[] args) {
    String access_token = args[0];
    Weibo weibo = new Weibo();
    weibo.setToken(access_token);
    String uid = args[1];
    Friendships fm = new Friendships();
    try {
      UserWapper  users = fm.getFriendsChainFollowers(uid);
      for(User s : users.getUsers()){
        Log.logInfo(s.toString());
      }
      System.out.println(users.getNextCursor());
      System.out.println(users.getPreviousCursor());
      System.out.println(users.getTotalNumber());
    } catch (WeiboException e) {
      e.printStackTrace();
    }
  }

}
TOP

Related Classes of weibo4j.examples.friendships.GetFriendsChainFollowers

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.