org.springframework.social.facebook.api
Interface FeedOperations


public interface FeedOperations

Interface defining operations that can be performed on a Facebook feed.


Method Summary
 void deleteFeedEntry(java.lang.String id)
          Deletes a feed entry
 java.util.List<Post> getFeed()
          Retrieves recent feed entries for the authenticated user.
 java.util.List<Post> getFeed(java.lang.String ownerId)
          Retrieves recent feed entries for a given user.
 Post getFeedEntry(java.lang.String entryId)
          Retrieves a single feed entry.
 java.util.List<Post> getHomeFeed()
          Retrieves the user's home feed.
 java.util.List<Post> getHomeFeed(java.lang.String userId)
          Retrieves the user's home feed.
 java.util.List<LinkPost> getLinks()
          Retrieves the link entries from the authenticated user's feed.
 java.util.List<LinkPost> getLinks(java.lang.String ownerId)
          Retrieves the link entries from the specified owner's feed.
 java.util.List<NotePost> getNotes()
          Retrieves the note entries from the authenticated user's feed.
 java.util.List<NotePost> getNotes(java.lang.String ownerId)
          Retrieves the note entries from the specified owner's feed.
 java.util.List<Post> getPosts()
          Retrieves the post entries from the authenticated user's feed.
 java.util.List<Post> getPosts(java.lang.String ownerId)
          Retrieves the post entries from the specified owner's feed.
 java.util.List<StatusPost> getStatuses()
          Retrieves the status entries from the authenticated user's feed.
 java.util.List<StatusPost> getStatuses(java.lang.String userId)
          Retrieves the status entries from the specified user's feed.
 java.lang.String postLink(java.lang.String message, FacebookLink link)
          Posts a link to the authenticated user's feed.
 java.lang.String updateStatus(java.lang.String message)
          Posts a status update to the authenticated user's feed.
 

Method Detail

getFeed

java.util.List<Post> getFeed()
Retrieves recent feed entries for the authenticated user. Returns up to 50 entries or 30 days worth of entries, whichever is greatest.

Returns:
a list of Posts for the authenticated user.

getFeed

java.util.List<Post> getFeed(java.lang.String ownerId)
Retrieves recent feed entries for a given user. Returns up to 50 entries or 30 days worth of entries, whichever is greatest.

Parameters:
ownerId - the Facebook ID or alias for the owner (user, group, event, page, etc) of the feed.
Returns:
a list of Posts for the specified user.

getHomeFeed

java.util.List<Post> getHomeFeed()
Retrieves the user's home feed. This includes entries from the user's friends.

Returns:
a list of Posts from the authenticated user's home feed.

getHomeFeed

java.util.List<Post> getHomeFeed(java.lang.String userId)
Retrieves the user's home feed. This includes entries from the user's friends.

Parameters:
userId - the user ID.
Returns:
a list of Posts from the specified user's home feed.

getFeedEntry

Post getFeedEntry(java.lang.String entryId)
Retrieves a single feed entry.

Parameters:
entryId - the entry ID
Returns:
the requested Post

getStatuses

java.util.List<StatusPost> getStatuses()
Retrieves the status entries from the authenticated user's feed.

Returns:
a list of status Posts.

getStatuses

java.util.List<StatusPost> getStatuses(java.lang.String userId)
Retrieves the status entries from the specified user's feed.

Parameters:
userId - the user's ID
Returns:
a list of status Posts.

getLinks

java.util.List<LinkPost> getLinks()
Retrieves the link entries from the authenticated user's feed.

Returns:
a list of link Posts.

getLinks

java.util.List<LinkPost> getLinks(java.lang.String ownerId)
Retrieves the link entries from the specified owner's feed.

Parameters:
ownerId - the owner of the feed (could be a user, page, event, etc)
Returns:
a list of link Posts.

getNotes

java.util.List<NotePost> getNotes()
Retrieves the note entries from the authenticated user's feed.

Returns:
a list of note Posts.

getNotes

java.util.List<NotePost> getNotes(java.lang.String ownerId)
Retrieves the note entries from the specified owner's feed.

Parameters:
ownerId - the owner of the feed (could be a user, page, event, etc)
Returns:
a list of note Posts.

getPosts

java.util.List<Post> getPosts()
Retrieves the post entries from the authenticated user's feed.

Returns:
a list of post Posts.

getPosts

java.util.List<Post> getPosts(java.lang.String ownerId)
Retrieves the post entries from the specified owner's feed.

Parameters:
ownerId - the owner of the feed (could be a user, page, event, etc)
Returns:
a list of post Posts.

updateStatus

java.lang.String updateStatus(java.lang.String message)
Posts a status update to the authenticated user's feed.

Parameters:
message - the message to post.
Returns:
the ID of the new feed entry.

postLink

java.lang.String postLink(java.lang.String message,
                          FacebookLink link)
Posts a link to the authenticated user's feed.

Parameters:
message - a message to send with the link.
Returns:
the ID of the new feed entry.

deleteFeedEntry

void deleteFeedEntry(java.lang.String id)
Deletes a feed entry

Parameters:
id - the feed entry ID