TWTRUserTimelineDataSource Class Reference
Inherits from | NSObject |
---|---|
Conforms to | TWTRTimelineDataSource |
Declared in | TWTRUserTimelineDataSource.h |
Overview
This Timeline Data Source provides a list of Tweets roughly consistent with the list on a Users profile page. The difference is that this data source will filter out Tweets that are direct replies to other users by default.
These Tweets are ordered chronologically with the most recent first.
screenName
The screen name of the User whose Tweets are being shown. Either the screenName
or the userID
are required.
@property (nonatomic, copy, readonly) NSString *screenName
Declared In
TWTRUserTimelineDataSource.h
userID
The userID of the User whose Tweets are being shown. Either the screenName
or the userID
are required.
@property (nonatomic, copy, readonly) NSString *userID
Declared In
TWTRUserTimelineDataSource.h
maxTweetsPerRequest
The number of Tweets to request in each query to the Twitter Timeline API when fetching the next batch of Tweets. Will request 30 Tweets by default. Setting this value to 0 will use the server default.
@property (nonatomic, readonly) NSUInteger maxTweetsPerRequest
Declared In
TWTRUserTimelineDataSource.h
includeReplies
Whether to request replies in the set of Tweets from the server.
@property (nonatomic, readonly) BOOL includeReplies
Discussion
Defaults to NO.
Declared In
TWTRUserTimelineDataSource.h
includeRetweets
Whether to request retweets in the set of Tweets from the server.
@property (nonatomic, readonly) BOOL includeRetweets
Discussion
Defaults to YES.
Declared In
TWTRUserTimelineDataSource.h
– initWithScreenName:APIClient:
Convenience initializer. Uses default values for maxTweetsPerRequest
, includeReplies
and includeRetweets
.
- (instancetype)initWithScreenName:(NSString *)screenName APIClient:(TWTRAPIClient *)client
Parameters
screenName |
The screen name of a Twitter User |
---|---|
client |
The API client to use for making network requests. |
Return Value
A fully initialized user timeline datasource or nil.
Declared In
TWTRUserTimelineDataSource.h
– initWithScreenName:userID:APIClient:maxTweetsPerRequest:includeReplies:includeRetweets:
The designated initialzer accepted values for properties.
- (instancetype)initWithScreenName:(nullable NSString *)screenName userID:(nullable NSString *)userID APIClient:(TWTRAPIClient *)client maxTweetsPerRequest:(NSUInteger)maxTweetsPerRequest includeReplies:(BOOL)includeReplies includeRetweets:(BOOL)includeRetweets
Parameters
screenName |
The screen name of the Twitter User |
---|---|
userID |
The user ID of the Twitter User |
client |
The API client to use for making network requests. |
maxTweetsPerRequest |
The number of Tweets per batch to request. A value of 0 will use the server default. |
includeReplies |
Whether replies should be requested |
includeRetweets |
Whether retweets should be requested |
Return Value
A fully initialized user timeline datasource or nil.
Declared In
TWTRUserTimelineDataSource.h