// Get Messages
        public IEnumerable <IMessageDTO> GetLatestMessagesReceived(IMessagesReceivedParameters queryParameters)
        {
            string query = _messageQueryGenerator.GetLatestMessagesReceivedQuery(queryParameters);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <IMessageDTO> >(query));
        }
Beispiel #2
0
        public IPlace GetPlaceFromId(string placeId)
        {
            string query = _geoQueryGenerator.GetPlaceFromIdQuery(placeId);

            return(_twitterAccessor.ExecuteGETQuery <IPlace>(query));
        }
Beispiel #3
0
        // Get existing message
        public IMessageDTO GetExistingMessage(long messageId)
        {
            string query = string.Format(Resources.Message_GetMessageFromId, messageId);

            return(_twitterAccessor.ExecuteGETQuery <IMessageDTO>(query));
        }
Beispiel #4
0
        public IEnumerable <long> GetUserIdsWhoseRetweetsAreMuted()
        {
            string query = _friendshipQueryGenerator.GetUserIdsWhoseRetweetsAreMutedQuery();

            return(_twitterAccessor.ExecuteGETQuery <long[]>(query));
        }
        public ITweetDTO GetTweetDTO(long tweetId)
        {
            string query = String.Format(Resources.Tweet_Get, tweetId);

            return(_twitterAccessor.ExecuteGETQuery <TweetDTO>(query));
        }
        // Get Messages
        public IGetMessagesDTO GetLatestMessages(IGetMessagesParameters queryParameters)
        {
            string query = _messageQueryGenerator.GetLatestMessagesQuery(queryParameters);

            return(_twitterAccessor.ExecuteGETQuery <IGetMessagesDTO>(query));
        }
        public IEnumerable <ISavedSearchDTO> GetSavedSearches()
        {
            string query = _savedSearchQueryGenerator.GetSavedSearchesQuery();

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ISavedSearchDTO> >(query));
        }
Beispiel #8
0
        // Home Timeline
        public IEnumerable <ITweetDTO> GetHomeTimeline(IHomeTimelineParameters timelineParameters)
        {
            string query = _timelineQueryGenerator.GetHomeTimelineQuery(timelineParameters);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ITweetDTO> >(query));
        }
Beispiel #9
0
        // Get Messages
        public IEnumerable <IMessageDTO> GetLatestMessagesReceived(int maximumMessages = TweetinviConsts.MESSAGE_GET_COUNT)
        {
            string query = _messageQueryGenerator.GetLatestMessagesReceivedQuery(maximumMessages);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <IMessageDTO> >(query));
        }
Beispiel #10
0
 // Get object (DTO) form query
 public static T ExecuteGETQuery <T>(string query) where T : class
 {
     return(_twitterAccessor.ExecuteGETQuery <T>(query));
 }
Beispiel #11
0
        private List <ITweetDTO> GetTweetDTOsFromSearch(string query)
        {
            var jObject = _twitterAccessor.ExecuteGETQuery(query);

            return(_searchQueryHelper.GetTweetsFromJsonObject(jObject));
        }
        // Get single user
        public IUserDTO GetAuthenticatedUser(IGetAuthenticatedUserParameters parameters)
        {
            var query = _userQueryParameterGenerator.GetAuthenticatedUserQuery(parameters);

            return(_twitterAccessor.ExecuteGETQuery <IUserDTO>(query));
        }
        public IAccountSettingsDTO GetLoggedUserAccountSettings()
        {
            string query = _accountQueryGenerator.GetLoggedUserAccountSettingsQuery();

            return(_twitterAccessor.ExecuteGETQuery <IAccountSettingsDTO>(query));
        }
        // Get Retweets
        public IEnumerable <ITweetDTO> GetRetweets(ITweetDTO tweet)
        {
            string query = _tweetQueryGenerator.GetRetweetsQuery(tweet);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ITweetDTO> >(query));
        }
Beispiel #15
0
        // Get single user
        public IUserDTO GetLoggedUser()
        {
            string query = Resources.TokenUser_GetCurrentUser;

            return(_twitterAccessor.ExecuteGETQuery <IUserDTO>(query));
        }
Beispiel #16
0
 private ISearchResultsDTO GetSearchTweetResultsFromQuery(string query)
 {
     return(_twitterAccessor.ExecuteGETQuery <ISearchResultsDTO>(query));
 }
Beispiel #17
0
        public IEnumerable <ITweetDTO> GetRetweets(ITweetIdentifier tweetIdentifier, int maxRetweetsToRetrieve)
        {
            var query = _tweetQueryGenerator.GetRetweetsQuery(tweetIdentifier, maxRetweetsToRetrieve);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ITweetDTO> >(query));
        }
Beispiel #18
0
        public ICredentialsRateLimits GetCurrentCredentialsRateLimits()
        {
            string query = _helpQueryGenerator.GetCredentialsLimitsQuery();

            return(_twitterAccessor.ExecuteGETQuery <ICredentialsRateLimits>(query));
        }
Beispiel #19
0
        public ISavedSearch GetSavedSearch(long searchId)
        {
            string query = _savedSearchQueryGenerator.GetSavedSearchQuery(searchId);

            return(_twitterAccessor.ExecuteGETQuery <ISavedSearch>(query));
        }
        public ITweetDTO GetTweetDTO(long tweetId)
        {
            string query = _tweetQueryGenerator.GetTweetQuery(tweetId);

            return(_twitterAccessor.ExecuteGETQuery <TweetDTO>(query));
        }
        // Get Messages
        public IEnumerable <IMessageDTO> GetLatestMessagesReceived(int maximumMessages = 40)
        {
            string query = _messageQueryGenerator.GetLatestMessagesReceivedQuery(maximumMessages);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <IMessageDTO> >(query));
        }
        public IPlaceTrends GetPlaceTrendsAt(long woeid)
        {
            string query = _trendsQueryGenerator.GetPlaceTrendsAtQuery(woeid);

            return(_twitterAccessor.ExecuteGETQuery <IPlaceTrends[]>(query)[0]);
        }
        // Favourites
        public IEnumerable <ITweetDTO> GetFavoriteTweets(IGetUserFavoritesQueryParameters parameters)
        {
            var query = _userQueryGenerator.GetFavoriteTweetsQuery(parameters);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ITweetDTO> >(query));
        }
        // User
        public IEnumerable <ITwitterListDTO> GetUserSubscribedLists(IUserIdentifier user, bool getOwnedListsFirst)
        {
            var query = _listsQueryGenerator.GetUserSubscribedListsQuery(user, getOwnedListsFirst);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ITwitterListDTO> >(query));
        }
Beispiel #25
0
        // Get existing list
        public ITwitterListDTO GetExistingList(ITwitterListIdentifier identifier)
        {
            string query = _twitterListFactoryQueryGenerator.GetListByIdQuery(identifier);

            return(_twitterAccessor.ExecuteGETQuery <ITwitterListDTO>(query));
        }
        // Favourites
        public IEnumerable <ITweetDTO> GetFavouriteTweets(IUserIdDTO userDTO, int maxFavouritesToRetrieve)
        {
            string query = _userQueryGenerator.GetFavouriteTweetsQuery(userDTO, maxFavouritesToRetrieve);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ITweetDTO> >(query));
        }
        // Get User Lists
        public IEnumerable <ITweetListDTO> GetUserLists(IUserIdDTO userDTO, bool getOwnedListsFirst)
        {
            var query = _listsQueryGenerator.GetUserListsQuery(userDTO, getOwnedListsFirst);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ITweetListDTO> >(query));
        }
        public IAccountSettingsDTO GetAuthenticatedUserAccountSettings()
        {
            var query = _accountQueryGenerator.GetAuthenticatedUserAccountSettingsQuery();

            return(_twitterAccessor.ExecuteGETQuery <IAccountSettingsDTO>(query));
        }
Beispiel #29
0
        // Home Timeline
        public IEnumerable <ITweetDTO> GetHomeTimeline(int maximumTweets = 40, bool excludeReplies = false)
        {
            string query = _timelineQueryGenerator.GetHomeTimelineQuery(maximumTweets, excludeReplies);

            return(_twitterAccessor.ExecuteGETQuery <IEnumerable <ITweetDTO> >(query));
        }