|
Spring Social Twitter | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface TimelineOperations
Interface defining the operations for sending and retrieving tweets.
| Method Summary | |
|---|---|
void |
addToFavorites(long id)
Adds a tweet to the user's collection of favorite tweets. |
void |
deleteStatus(long tweetId)
Removes a status entry. |
java.util.List<Tweet> |
getFavorites()
Retrieves the 20 most recent tweets favorited by the authenticated user. |
java.util.List<Tweet> |
getFavorites(int pageSize)
Retrieves tweets favorited by the authenticated user. |
java.util.List<Tweet> |
getHomeTimeline()
Retrieves the 20 most recently posted tweets, including retweets, from the authenticating user's home timeline. |
java.util.List<Tweet> |
getHomeTimeline(int pageSize)
Retrieves tweets, including retweets, from the authenticating user's home timeline. |
java.util.List<Tweet> |
getHomeTimeline(int pageSize,
long sinceId,
long maxId)
Retrieves tweets, including retweets, from the authenticating user's home timeline. |
java.util.List<Tweet> |
getMentions()
Retrieve the 20 most recent tweets that mention the authenticated user. |
java.util.List<Tweet> |
getMentions(int pageSize)
Retrieve tweets that mention the authenticated user. |
java.util.List<Tweet> |
getMentions(int pageSize,
long sinceId,
long maxId)
Retrieve tweets that mention the authenticated user. |
java.util.List<Tweet> |
getRetweets(long tweetId)
Retrieves up to 100 retweets of a specific tweet. |
java.util.List<Tweet> |
getRetweets(long tweetId,
int count)
Retrieves retweets of a specific tweet. |
Tweet |
getStatus(long tweetId)
Returns a single tweet. |
java.util.List<Tweet> |
getUserTimeline()
Retrieves the 20 most recent tweets posted by the authenticating user. |
java.util.List<Tweet> |
getUserTimeline(int pageSize)
Retrieves tweets posted by the authenticating user. |
java.util.List<Tweet> |
getUserTimeline(int pageSize,
long sinceId,
long maxId)
Retrieves tweets posted by the authenticating user. |
java.util.List<Tweet> |
getUserTimeline(long userId)
Retrieves the 20 most recent tweets posted by the given user. |
java.util.List<Tweet> |
getUserTimeline(long userId,
int pageSize)
Retrieves tweets posted by the given user. |
java.util.List<Tweet> |
getUserTimeline(long userId,
int pageSize,
long sinceId,
long maxId)
Retrieves tweets posted by the given user. |
java.util.List<Tweet> |
getUserTimeline(java.lang.String screenName)
Retrieves the 20 most recent tweets posted by the given user. |
java.util.List<Tweet> |
getUserTimeline(java.lang.String screenName,
int pageSize)
Retrieves tweets posted by the given user. |
java.util.List<Tweet> |
getUserTimeline(java.lang.String screenName,
int pageSize,
long sinceId,
long maxId)
Retrieves tweets posted by the given user. |
void |
removeFromFavorites(long id)
Removes a tweet from the user's collection of favorite tweets. |
void |
retweet(long tweetId)
Posts a retweet of an existing tweet. |
Tweet |
updateStatus(java.lang.String status)
Updates the user's status. |
Tweet |
updateStatus(java.lang.String status,
org.springframework.core.io.Resource photo)
Updates the user's status along with a picture. |
Tweet |
updateStatus(java.lang.String status,
org.springframework.core.io.Resource photo,
StatusDetails details)
Updates the user's status, including a picture and additional metadata concerning the status. |
Tweet |
updateStatus(java.lang.String status,
StatusDetails details)
Updates the user's status, including additional metadata concerning the status. |
| Method Detail |
|---|
java.util.List<Tweet> getHomeTimeline()
Tweets in the authenticating user's home timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.java.util.List<Tweet> getHomeTimeline(int pageSize)
pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)
Tweets in the authenticating user's home timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.
java.util.List<Tweet> getHomeTimeline(int pageSize,
long sinceId,
long maxId)
pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)sinceId - The minimum Tweet ID to return in the resultsmaxId - The maximum Tweet ID to return in the results
Tweets in the authenticating user's home timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.java.util.List<Tweet> getUserTimeline()
Tweets that have been posted by the authenticating user.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.java.util.List<Tweet> getUserTimeline(int pageSize)
pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)
Tweets that have been posted by the authenticating user.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.
java.util.List<Tweet> getUserTimeline(int pageSize,
long sinceId,
long maxId)
pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)sinceId - The minimum Tweet ID to return in the resultsmaxId - The maximum Tweet ID to return in the results
Tweets that have been posted by the authenticating user.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.java.util.List<Tweet> getUserTimeline(java.lang.String screenName)
screenName - The screen name of the user whose timeline is being requested.
Tweets from the specified user's timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
java.util.List<Tweet> getUserTimeline(java.lang.String screenName,
int pageSize)
screenName - The screen name of the user whose timeline is being requested.pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)
Tweets from the specified user's timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
java.util.List<Tweet> getUserTimeline(java.lang.String screenName,
int pageSize,
long sinceId,
long maxId)
screenName - The screen name of the user whose timeline is being requested.pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)sinceId - The minimum Tweet ID to return in the resultsmaxId - The maximum Tweet ID to return in the results
Tweets from the specified user's timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.java.util.List<Tweet> getUserTimeline(long userId)
userId - The user ID of the user whose timeline is being requested.
Tweets from the specified user's timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
java.util.List<Tweet> getUserTimeline(long userId,
int pageSize)
userId - The user ID of the user whose timeline is being requested.pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)
Tweets from the specified user's timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
java.util.List<Tweet> getUserTimeline(long userId,
int pageSize,
long sinceId,
long maxId)
userId - The user ID of the user whose timeline is being requested.pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)sinceId - The minimum Tweet ID to return in the resultsmaxId - The maximum Tweet ID to return in the results
Tweets from the specified user's timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.java.util.List<Tweet> getMentions()
Tweet objects that mention the authenticated user.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.java.util.List<Tweet> getMentions(int pageSize)
pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)
Tweet objects that mention the authenticated user.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.
java.util.List<Tweet> getMentions(int pageSize,
long sinceId,
long maxId)
pageSize - The number of Tweets per page. Should be less than or equal to 200. (Will return at most 200 entries, even if pageSize is greater than 200.)sinceId - The minimum Tweet ID to return in the resultsmaxId - The maximum Tweet ID to return in the results
Tweet objects that mention the authenticated user.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.Tweet getStatus(long tweetId)
tweetId - the tweet's ID
org.springframework.social.ApiException - if there is an error while communicating with Twitter.Tweet updateStatus(java.lang.String status)
status - The status message
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
DuplicateTweetException - if the status message duplicates a previously posted status.
MessageTooLongException - if the length of the status message exceeds Twitter's 140 character limit.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.
Tweet updateStatus(java.lang.String status,
org.springframework.core.io.Resource photo)
status - The status messagephoto - A Resource for the photo data. The given Resource must implement the getFilename() method (such as FileSystemResource or ClassPathResource) and must contain GIF, JPG, or PNG data.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
DuplicateTweetException - if the status message duplicates a previously posted status.
MessageTooLongException - if the length of the status message exceeds Twitter's 140 character limit.
org.springframework.social.OperationNotPermittedException - if the photo resource isn't a GIF, JPG, or PNG.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.
Tweet updateStatus(java.lang.String status,
StatusDetails details)
status - The status messagedetails - Metadata pertaining to the status
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
DuplicateTweetException - if the status message duplicates a previously posted status.
MessageTooLongException - if the length of the status message exceeds Twitter's 140 character limit.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.
Tweet updateStatus(java.lang.String status,
org.springframework.core.io.Resource photo,
StatusDetails details)
status - The status messagephoto - A Resource for the photo data. The given Resource must implement the getFilename() method (such as FileSystemResource or ClassPathResource) and must contain GIF, JPG, or PNG data.details - Metadata pertaining to the status
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
DuplicateTweetException - if the status message duplicates a previously posted status.
MessageTooLongException - if the length of the status message exceeds Twitter's 140 character limit.
org.springframework.social.OperationNotPermittedException - if the photo resource isn't a GIF, JPG, or PNG.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.void deleteStatus(long tweetId)
tweetId - the tweet's ID
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.void retweet(long tweetId)
tweetId - The ID of the tweet to be retweeted
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.java.util.List<Tweet> getRetweets(long tweetId)
tweetId - the tweet's ID
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
java.util.List<Tweet> getRetweets(long tweetId,
int count)
tweetId - the tweet's IDcount - The maximum number of retweets to return. Should be less than or equal to 100. (Will return at most 100 entries, even if pageSize is greater than 100.)
org.springframework.social.ApiException - if there is an error while communicating with Twitter.java.util.List<Tweet> getFavorites()
Tweets from the specified user's favorite timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.java.util.List<Tweet> getFavorites(int pageSize)
pageSize - The number of entries per page.
Tweets from the specified user's favorite timeline.
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.void addToFavorites(long id)
id - the tweet's ID
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.void removeFromFavorites(long id)
id - the tweet's ID
org.springframework.social.ApiException - if there is an error while communicating with Twitter.
org.springframework.social.MissingAuthorizationException - if TwitterTemplate was not created with OAuth credentials.
|
Spring Social Twitter | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||