public interface FriendsFollowersResources
| Modifier and Type | Method and Description | 
|---|---|
User | 
createFriendship(long userId)
Allows the authenticating users to follow the user specified in the ID parameter. 
Returns the befriended user in the requested format when successful.  | 
User | 
createFriendship(long userId,
                boolean follow)
Allows the authenticating users to follow the user specified in the ID parameter. 
Returns the befriended user in the requested format when successful.  | 
User | 
createFriendship(java.lang.String screenName)
Allows the authenticating users to follow the user specified in the ID parameter. 
Returns the befriended user in the requested format when successful.  | 
User | 
createFriendship(java.lang.String screenName,
                boolean follow)
Allows the authenticating users to follow the user specified in the ID parameter. 
Returns the befriended user in the requested format when successful.  | 
User | 
destroyFriendship(long userId)
Allows the authenticating users to unfollow the user specified in the ID parameter. 
Returns the unfollowed user in the requested format when successful.  | 
User | 
destroyFriendship(java.lang.String screenName)
Allows the authenticating users to unfollow the user specified in the ID parameter. 
Returns the unfollowed user in the requested format when successful.  | 
IDs | 
getFollowersIDs(long cursor)
Returns an array of numeric IDs for every user the specified user is followed by. 
 | 
IDs | 
getFollowersIDs(long userId,
               long cursor)
Returns an array of numeric IDs for every user the specified user is followed by. 
 | 
IDs | 
getFollowersIDs(java.lang.String screenName,
               long cursor)
Returns an array of numeric IDs for every user the specified user is followed by. 
 | 
PagableResponseList<User> | 
getFollowersList(long userId,
                long cursor)
Returns a cursored collection of user objects for users following the specified user. 
At this time, results are ordered with the most recent following first — however, this ordering is subject to unannounced change and eventual consistency issues.  | 
PagableResponseList<User> | 
getFollowersList(java.lang.String screenName,
                long cursor)
Returns a cursored collection of user objects for users following the specified user. 
At this time, results are ordered with the most recent following first — however, this ordering is subject to unannounced change and eventual consistency issues.  | 
IDs | 
getFriendsIDs(long cursor)
Returns an array of numeric IDs for every user the authenticating user is following. 
 | 
IDs | 
getFriendsIDs(long userId,
             long cursor)
Returns an array of numeric IDs for every user the specified user is following. 
 | 
IDs | 
getFriendsIDs(java.lang.String screenName,
             long cursor)
Returns an array of numeric IDs for every user the specified user is following. 
 | 
PagableResponseList<User> | 
getFriendsList(long userId,
              long cursor)
Returns a cursored collection of user objects for every user the specified user is following (otherwise known as their "friends"). 
At this time, results are ordered with the most recent following first — however, this ordering is subject to unannounced change and eventual consistency issues.  | 
PagableResponseList<User> | 
getFriendsList(java.lang.String screenName,
              long cursor)
Returns a cursored collection of user objects for every user the specified user is following (otherwise known as their "friends"). 
At this time, results are ordered with the most recent following first — however, this ordering is subject to unannounced change and eventual consistency issues.  | 
IDs | 
getIncomingFriendships(long cursor)
Returns an array of numeric IDs for every user who has a pending request to follow the authenticating user. 
 | 
IDs | 
getOutgoingFriendships(long cursor)
Returns an array of numeric IDs for every protected user for whom the authenticating user has a pending follow request. 
 | 
ResponseList<Friendship> | 
lookupFriendships(long[] ids)
Returns the relationship of the authenticating user to the specified users. 
 | 
ResponseList<Friendship> | 
lookupFriendships(java.lang.String[] screenNames)
Returns the relationship of the authenticating user to the specified users. 
 | 
Relationship | 
showFriendship(long sourceId,
              long targetId)
Returns detailed information about the relationship between two users. 
 | 
Relationship | 
showFriendship(java.lang.String sourceScreenName,
              java.lang.String targetScreenName)
Returns detailed information about the relationship between two users. 
 | 
Relationship | 
updateFriendship(long userId,
                boolean enableDeviceNotification,
                boolean retweets)
Allows you to enable or disable retweets and device notifications from the specified user. 
 | 
Relationship | 
updateFriendship(java.lang.String screenName,
                boolean enableDeviceNotification,
                boolean retweets)
Allows you to enable or disable retweets and device notifications from the specified user. 
 | 
IDs getFriendsIDs(long cursor) throws TwitterException
cursor - Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filterd out after connections are queried. TwitterException - when Twitter service or network is unavailableIDs getFriendsIDs(long userId, long cursor) throws TwitterException
userId - Specifies the ID of the user for whom to return the friends list.cursor - Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filterd out after connections are queried. TwitterException - when Twitter service or network is unavailableIDs getFriendsIDs(java.lang.String screenName, long cursor) throws TwitterException
screenName - Specifies the screen name of the user for whom to return the friends list.cursor - Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filterd out after connections are queried. TwitterException - when Twitter service or network is unavailableIDs getFollowersIDs(long cursor) throws TwitterException
cursor - Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filterd out after connections are queried. TwitterException - when Twitter service or network is unavailableIDs getFollowersIDs(long userId, long cursor) throws TwitterException
userId - Specifies the ID of the user for whom to return the followers list.cursor - Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filterd out after connections are queried. TwitterException - when Twitter service or network is unavailableIDs getFollowersIDs(java.lang.String screenName, long cursor) throws TwitterException
screenName - Specifies the screen name of the user for whom to return the followers list.cursor - Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filterd out after connections are queried. TwitterException - when Twitter service or network is unavailableResponseList<Friendship> lookupFriendships(long[] ids) throws TwitterException
ids - array of the ids to lookupTwitterException - when Twitter service or network is unavailableResponseList<Friendship> lookupFriendships(java.lang.String[] screenNames) throws TwitterException
screenNames - array of the screen names to lookupTwitterException - when Twitter service or network is unavailableIDs getIncomingFriendships(long cursor) throws TwitterException
cursor - Breaks the results into pages. A single page contains 5000 identifiers. Provide a value of -1 to begin paging.TwitterException - when Twitter service or network is unavailableIDs getOutgoingFriendships(long cursor) throws TwitterException
cursor - Breaks the results into pages. A single page contains 5000 identifiers. Provide a value of -1 to begin paging.TwitterException - when Twitter service or network is unavailableUser createFriendship(long userId) throws TwitterException
userId - the ID of the user to be befriendedTwitterException - when Twitter service or network is unavailableUser createFriendship(java.lang.String screenName) throws TwitterException
screenName - the screen name of the user to be befriendedTwitterException - when Twitter service or network is unavailableUser createFriendship(long userId, boolean follow) throws TwitterException
userId - the ID of the user to be befriendedfollow - Enable notifications for the target user in addition to becoming friends.TwitterException - when Twitter service or network is unavailableUser createFriendship(java.lang.String screenName, boolean follow) throws TwitterException
screenName - the screen name of the user to be befriendedfollow - Enable notifications for the target user in addition to becoming friends.TwitterException - when Twitter service or network is unavailableUser destroyFriendship(long userId) throws TwitterException
userId - the ID of the user for whom to request a list of friendsTwitterException - when Twitter service or network is unavailableUser destroyFriendship(java.lang.String screenName) throws TwitterException
screenName - the screen name of the user for whom to request a list of friendsTwitterException - when Twitter service or network is unavailableRelationship updateFriendship(long userId, boolean enableDeviceNotification, boolean retweets) throws TwitterException
userId - user id to updateenableDeviceNotification - set true to enable device notificationretweets - set true to enable retweetsTwitterException - when Twitter service or network is unavailableRelationship updateFriendship(java.lang.String screenName, boolean enableDeviceNotification, boolean retweets) throws TwitterException
screenName - screen name to updateenableDeviceNotification - set true to enable device notificationretweets - set true to enable retweetsTwitterException - when Twitter service or network is unavailableRelationship showFriendship(long sourceId, long targetId) throws TwitterException
sourceId - the ID of the source usertargetId - the ID of the target userTwitterException - when Twitter service or network is unavailableRelationship showFriendship(java.lang.String sourceScreenName, java.lang.String targetScreenName) throws TwitterException
sourceScreenName - the screen name of the source usertargetScreenName - the screen name of the target userTwitterException - when Twitter service or network is unavailablePagableResponseList<User> getFriendsList(long userId, long cursor) throws TwitterException
userId - The ID of the user for whom to return results for.cursor - Causes the results to be broken into pages of no more than 20 records at a time.TwitterException - when Twitter service or network is unavailablePagableResponseList<User> getFriendsList(java.lang.String screenName, long cursor) throws TwitterException
screenName - The screen name of the user for whom to return results for.cursor - Causes the results to be broken into pages of no more than 20 records at a time.TwitterException - when Twitter service or network is unavailablePagableResponseList<User> getFollowersList(long userId, long cursor) throws TwitterException
userId - The ID of the user for whom to return results for.cursor - Causes the results to be broken into pages of no more than 20 records at a time.TwitterException - when Twitter service or network is unavailablePagableResponseList<User> getFollowersList(java.lang.String screenName, long cursor) throws TwitterException
screenName - The screen name of the user for whom to return results for.cursor - Causes the results to be broken into pages of no more than 20 records at a time.TwitterException - when Twitter service or network is unavailable