'Fetch the sequence of public Status messages for a single user.
The twitter.Api instance must be authenticated if the user is private.
Args:
user_id:
Specifies the ID of the user for whom to return the
user_timeline. Helpful for disambiguating when a valid user ID
is also a valid screen name. [Optional]
screen_name:
Specifies the screen name of the user for whom to return the
user_timeline. Helpful for disambiguating when a valid screen
name is also a user ID. [Optional]
since_id:
Returns results with an ID greater than (that is, more recent
than) the specified ID. There are limits to the number of
Tweets which can be accessed through the API. If the limit of
Tweets has occurred since the since_id, the since_id will be
forced to the oldest ID available. [Optional]
max_id:
Returns only statuses with an ID less than (that is, older
than) or equal to the specified ID. [Optional]
count:
Specifies the number of statuses to retrieve. May not be
greater than 200.  [Optional]
include_rts:
If True, the timeline will contain native retweets (if they
exist) in addition to the standard stream of tweets. [Optional]
trim_user:
If True, statuses will only contain the numerical user ID only.
Otherwise a full user object will be returned for each status.
[Optional]
exclude_replies:
If True, this will prevent replies from appearing in the returned
timeline. Using exclude_replies with the count parameter will mean you
will receive up-to count tweets - this is because the count parameter
retrieves that many tweets before filtering out retweets and replies.
This parameter is only supported for JSON and XML responses. [Optional]
Returns:
A sequence of Status instances, one for each message up to count'

def GetUserTimeline(self, user_id=None, screen_name=None, since_id=None, max_id=None, count=None, include_rts=None, trim_user=None, exclude_replies=None):

    parameters = {}
    url = ('%s/statuses/user_timeline.json' % self.base_url)
    if user_id:
        parameters['user_id'] = user_id
    elif screen_name:
        parameters['screen_name'] = screen_name
    if since_id:
        try:
            parameters['since_id'] = long(since_id)
        except:
            raise TwitterError('since_id    must    be    an    integer')
    if max_id:
        try:
            parameters['max_id'] = long(max_id)
        except:
            raise TwitterError('max_id    must    be    an    integer')
    if count:
        try:
            parameters['count'] = int(count)
        except:
            raise TwitterError('count    must    be    an    integer')
    if include_rts:
        parameters['include_rts'] = 1
    if trim_user:
        parameters['trim_user'] = 1
    if exclude_replies:
        parameters['exclude_replies'] = 1
    json = self._FetchUrl(url, parameters=parameters)
    data = self._ParseAndCheckTwitter(json)
    return [Status.NewFromJsonDict(x) for x in data]
