public List <Models.User> GetUserFollowers() { var model = new List <Models.User>(); var result = Auth.ExecuteOperationWithCredentials(_credentialService.GetUserCredentials(), () => { // Get the first 250 followers of the user var followers = User.GetFollowers(User.GetAuthenticatedUser(_credentialService.GetUserCredentials()).ScreenName); IEnumerator <IUser> e = followers.GetEnumerator(); while (e.MoveNext()) { model.Add(new Models.User { Name = e.Current.Name, ScreenName = e.Current.ScreenName, StatusesCount = e.Current.StatusesCount, FollowersCount = e.Current.FollowersCount, FriendsCount = e.Current.FriendsCount, ProfileImage = e.Current.ProfileImageUrl, BackgroundImage = e.Current.ProfileBannerURL }); } return(model); }); return(result); }
public static async Task <IEnumerable <IUser> > GetFollowers(string userScreenName, int maxFollowersToRetrieve = 250) { return(await Sync.ExecuteTaskAsync(() => User.GetFollowers(userScreenName, maxFollowersToRetrieve))); }
public static async Task <IEnumerable <IUser> > GetFollowers(IUserIdentifier userIdentifier, int maxFollowersToRetrieve = 250) { return(await Sync.ExecuteTaskAsync(() => User.GetFollowers(userIdentifier, maxFollowersToRetrieve))); }