예제 #1
0
        /// <summary>
        /// Returns up to 100 of the authenticating user's friends who have most recently updated, each with current status.
        /// </summary>
        /// <param name="Parameters">Optional. Accepts ID, Page, and Since parameters.</param>
        /// <returns></returns>
        public TwitterUserCollection Friends(TwitterParameters Parameters)
        {
            // page 0 == page 1 is the start
            TwitterRequest     Request = new TwitterRequest();
            TwitterRequestData Data    = new TwitterRequestData();

            Data.UserName = userName;
            Data.Password = password;

            string actionUri = (Parameters == null ? Twitter.Urls.FriendsUrl : Parameters.BuildActionUri(Twitter.Urls.FriendsUrl));

            Data.ActionUri = new Uri(actionUri);
            Data           = Request.PerformWebRequest(Data);
            return(Data.Users);
        }
예제 #2
0
        /// <summary>
        /// Returns the 20 most recent statuses posted from the authenticating user.
        /// </summary>
        /// <param name="Parameters">Accepts Count, Since, SinceID, and Page parameters.</param>
        /// <returns></returns>
        public TwitterStatusCollection UserTimeline(TwitterParameters Parameters)
        {
            TwitterRequest     Request = new TwitterRequest();
            TwitterRequestData Data    = new TwitterRequestData();

            Data.UserName = userName;
            Data.Password = password;

            string actionUri = (Parameters == null ? Twitter.Urls.UserTimelineUrl : Parameters.BuildActionUri(Twitter.Urls.RootUrl));

            Data.ActionUri = new Uri(actionUri);

            Data = Request.PerformWebRequest(Data);

            return(Data.Statuses);
        }
예제 #3
0
        /// <summary>
        /// Returns a list of the most recent direct messages sent to the authenticating user.
        /// </summary>
        /// <param name="Parameters">Accepts Since, SinceID, and Page parameters</param>
        /// <returns></returns>
        public TwitterStatusCollection DirectMessages(TwitterParameters Parameters)
        {
            TwitterRequest     Request = new TwitterRequest();
            TwitterRequestData Data    = new TwitterRequestData();

            Data.UserName = userName;
            Data.Password = password;

            string actionUri = (Parameters == null ? Twitter.Urls.DirectMessagesUrl : Parameters.BuildActionUri(Twitter.Urls.DirectMessagesUrl));

            Data.ActionUri = new Uri(actionUri);

            Data = Request.PerformWebRequest(Data, "GET");

            return(Data.Statuses);
        }