예제 #1
0
        public IRelationshipDTO GetRelationshipBetween(long sourceUserId, long targetUserId)
        {
            string sourceParameter = _userQueryParameterGenerator.GenerateUserIdParameter(sourceUserId);
            string targetParameter = _userQueryParameterGenerator.GenerateUserIdParameter(targetUserId);
            string query           = String.Format(Resources.Friendship_GetRelationship, sourceParameter, targetParameter);

            return(_twitterAccessor.ExecuteGETQuery <IRelationshipDTO>(query));
        }
예제 #2
0
        public string GetMuteQuery(long userId)
        {
            if (!_userQueryValidator.IsUserIdValid(userId))
            {
                return(null);
            }

            string userIdParameter = _userQueryParameterGenerator.GenerateUserIdParameter(userId);

            return(GenerateCreateMuteQuery(userIdParameter));
        }
예제 #3
0
        public string GetFriendIdsQuery(long userId, int maxFriendsToRetrieve)
        {
            if (!_userQueryValidator.IsUserIdValid(userId))
            {
                return(null);
            }

            string userIdParameter = _userQueryParameterGenerator.GenerateUserIdParameter(userId);

            return(GenerateGetFriendIdsQuery(userIdParameter, maxFriendsToRetrieve));
        }
예제 #4
0
        public string GetUserSubscribedListsQuery(long userId, bool getOwnedListsFirst)
        {
            if (!_userQueryValidator.IsUserIdValid(userId))
            {
                return(null);
            }

            var userIdentifier = _userQueryParameterGenerator.GenerateUserIdParameter(userId);

            return(GenerateUserListsQuery(userIdentifier, getOwnedListsFirst));
        }
        public string GetPublishMessageQuery(string messageText, long targetUserId)
        {
            if (!_messageQueryValidator.IsMessageTextValid(messageText) || !_userQueryValidator.IsUserIdValid(targetUserId))
            {
                return(null);
            }

            string userIdParameter = _userQueryParameterGenerator.GenerateUserIdParameter(targetUserId);

            return(GetPublishMessageFormattedQuery(messageText, userIdParameter));
        }
예제 #6
0
        public string GetUserTimelineQuery(long userId, int maximumTweets, bool excludeReplies)
        {
            string userIdParameter = _userQueryParameterGenerator.GenerateUserIdParameter(userId);

            return(GetUserTimelineBaseQuery(userIdParameter, maximumTweets, excludeReplies));
        }