org.springframework.social.facebook.api.impl
Class VideoActionsTemplate

java.lang.Object
  extended by org.springframework.social.facebook.api.impl.VideoActionsTemplate
All Implemented Interfaces:
VideoActions

public class VideoActionsTemplate
extends Object
implements VideoActions


Constructor Summary
VideoActionsTemplate(OpenGraphOperations openGraphOperations)
           
 
Method Summary
 String rateEpisode(String episodeUrl, float rating, int scale)
          Publishes a "video.rates" action for the OpenGraph episode object at the given URL.
 String rateEpisode(String episodeUrl, float rating, int scale, ActionMetadata metadata)
          Publishes a "video.rates" action for the OpenGraph episode object at the given URL.
 String rateMovie(String movieUrl, float rating, int scale)
          Publishes a "video.rates" action for the OpenGraph movie object at the given URL.
 String rateMovie(String movieUrl, float rating, int scale, ActionMetadata metadata)
          Publishes a "video.rates" action for the OpenGraph movie object at the given URL.
 String rateTvShow(String tvShowUrl, float rating, int scale)
          Publishes a "video.rates" action for the OpenGraph TV show object at the given URL.
 String rateTvShow(String tvShowUrl, float rating, int scale, ActionMetadata metadata)
          Publishes a "video.rates" action for the OpenGraph TV show object at the given URL.
 String rateVideo(String otherUrl, float rating, int scale)
          Publishes a "video.rates" action for the OpenGraph video object at the given URL.
 String rateVideo(String otherUrl, float rating, int scale, ActionMetadata metadata)
          Publishes a "video.rates" action for the OpenGraph video object at the given URL.
 String rateVideo(String videoType, String videoUrl, float rating, int scale, ActionMetadata metadata)
          Publishes a "video.rates" action for the OpenGraph video object at the given URL.
 String wantsToWatch(String videoType, String videoUrl, ActionMetadata metadata)
          Publishes a "video.wants_to_watch" action for the OpenGraph video object at the given URL.
 String wantsToWatchEpisode(String episodeUrl)
          Publishes a "video.wants_to_watch" action for the OpenGraph episode object at the given URL.
 String wantsToWatchEpisode(String episodeUrl, ActionMetadata metadata)
          Publishes a "video.wants_to_watch" action for the OpenGraph episode object at the given URL.
 String wantsToWatchMovie(String movieUrl)
          Publishes a "video.wants_to_watch" action for the OpenGraph movie object at the given URL.
 String wantsToWatchMovie(String movieUrl, ActionMetadata metadata)
          Publishes a "video.wants_to_watch" action for the OpenGraph movie object at the given URL.
 String wantsToWatchTvShow(String tvShowUrl)
          Publishes a "video.wants_to_watch" action for the OpenGraph TV show object at the given URL.
 String wantsToWatchTvShow(String tvShowUrl, ActionMetadata metadata)
          Publishes a "video.wants_to_watch" action for the OpenGraph TV show object at the given URL.
 String wantsToWatchVideo(String otherUrl)
          Publishes a "video.wants_to_watch" action for the OpenGraph video object at the given URL.
 String wantsToWatchVideo(String otherUrl, ActionMetadata metadata)
          Publishes a "video.wants_to_watch" action for the OpenGraph video object at the given URL.
 String watchEpisode(String episodeUrl)
          Publishes a "video.watches" action for the OpenGraph episode object at the given URL.
 String watchEpisode(String episodeUrl, ActionMetadata metadata)
          Publishes a "video.watches" action for the OpenGraph episode object at the given URL.
 String watchMovie(String movieUrl)
          Publishes a "video.watches" action for the OpenGraph movie object at the given URL.
 String watchMovie(String movieUrl, ActionMetadata metadata)
          Publishes a "video.watches" action for the OpenGraph movie object at the given URL.
 String watchTvEpisode(String tvEpisodeUrl)
          Publishes a "video.watches" action for the OpenGraph TV episode object at the given URL.
 String watchTvEpisode(String tvShowUrl, ActionMetadata metadata)
          Publishes a "video.watches" action for the OpenGraph TV episode object at the given URL.
 String watchTvShow(String tvShowUrl)
          Publishes a "video.watches" action for the OpenGraph TV show object at the given URL.
 String watchTvShow(String tvShowUrl, ActionMetadata metadata)
          Publishes a "video.watches" action for the OpenGraph TV show object at the given URL.
 String watchVideo(String videoUrl)
          Publishes a "video.watches" action for the OpenGraph video object at the given URL.
 String watchVideo(String videoUrl, ActionMetadata metadata)
          Publishes a "video.watches" action for the OpenGraph video object at the given URL.
 String watchVideo(String videoType, String videoUrl, ActionMetadata metadata)
          Publishes a "video.watches" action for the OpenGraph video object at the given URL.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VideoActionsTemplate

public VideoActionsTemplate(OpenGraphOperations openGraphOperations)
Method Detail

watchMovie

public String watchMovie(String movieUrl)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph movie object at the given URL.

Specified by:
watchMovie in interface VideoActions
Parameters:
movieUrl - The URL of the movie that is being watched. Must reference an OpenGraph object of type "video.movie".
Returns:
The ID for the action created.

watchMovie

public String watchMovie(String movieUrl,
                         ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph movie object at the given URL.

Specified by:
watchMovie in interface VideoActions
Parameters:
movieUrl - The URL of the movie that is being watched. Must reference an OpenGraph object of type "video.movie".
metadata - Action metadata to be applied to the action.
Returns:
The ID for the action created.

watchTvShow

public String watchTvShow(String tvShowUrl)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph TV show object at the given URL.

Specified by:
watchTvShow in interface VideoActions
Parameters:
tvShowUrl - The URL of the TV show that is being watched. Must reference an OpenGraph object of type "video.tv_show".
Returns:
The ID for the action created.

watchTvShow

public String watchTvShow(String tvShowUrl,
                          ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph TV show object at the given URL.

Specified by:
watchTvShow in interface VideoActions
Parameters:
tvShowUrl - The URL of the TV show that is being watched. Must reference an OpenGraph object of type "video.tv_show".
metadata - Action metadata to be applied to the action.
Returns:
The ID for the action created.

watchTvEpisode

public String watchTvEpisode(String tvEpisodeUrl)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph TV episode object at the given URL.

Specified by:
watchTvEpisode in interface VideoActions
Parameters:
tvEpisodeUrl - The URL of the TV episode that is being watched. Must reference an OpenGraph object of type "video.episode".
Returns:
The ID for the action created.

watchTvEpisode

public String watchTvEpisode(String tvShowUrl,
                             ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph TV episode object at the given URL.

Specified by:
watchTvEpisode in interface VideoActions
Parameters:
tvShowUrl - The URL of the TV episode that is being watched. Must reference an OpenGraph object of type "video.episode".
metadata - Action metadata to be applied to the action.
Returns:
The ID for the action created.

watchEpisode

public String watchEpisode(String episodeUrl)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph episode object at the given URL.

Specified by:
watchEpisode in interface VideoActions
Parameters:
episodeUrl - The URL of the episode that is being watched. Must reference an OpenGraph object of type "video.episode".
Returns:
The ID for the action created.

watchEpisode

public String watchEpisode(String episodeUrl,
                           ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph episode object at the given URL.

Specified by:
watchEpisode in interface VideoActions
Parameters:
episodeUrl - The URL of the episode that is being watched. Must reference an OpenGraph object of type "video.episode".
metadata - Action metadata to be applied to the action.
Returns:
The ID for the action created.

watchVideo

public String watchVideo(String videoUrl)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph video object at the given URL.

Specified by:
watchVideo in interface VideoActions
Parameters:
videoUrl - The URL of the video that is being watched. Must reference an OpenGraph object of type "video.other".
Returns:
The ID for the action created.

watchVideo

public String watchVideo(String videoUrl,
                         ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph video object at the given URL.

Specified by:
watchVideo in interface VideoActions
Parameters:
videoUrl - The URL of the video that is being watched. Must reference an OpenGraph object of type "video.other".
metadata - Action metadata to be applied to the action.
Returns:
The ID for the action created.

watchVideo

public String watchVideo(String videoType,
                         String videoUrl,
                         ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.watches" action for the OpenGraph video object at the given URL. Generic method for creating a "video.watches" action, allowing for future addition of video types not currently supported by Facebook.

Specified by:
watchVideo in interface VideoActions
Parameters:
videoType - The type of video being watched. E.g., "movie", "tv_show", "tv_episode", "episode", "other", etc.
videoUrl - The URL of the video that is being watched. Must reference an OpenGraph object of type "video.other", "video.movie", "video.tv_show", or "video.episode".
metadata - Action metadata to be applied to the action.
Returns:
The ID for the action created.

rateMovie

public String rateMovie(String movieUrl,
                        float rating,
                        int scale)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph movie object at the given URL.

Specified by:
rateMovie in interface VideoActions
Parameters:
movieUrl - The URL of the movie that is being rated. Must reference an OpenGraph object of type "video.movie".
rating - The rating given to the movie, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
Returns:
The ID for the action created.

rateMovie

public String rateMovie(String movieUrl,
                        float rating,
                        int scale,
                        ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph movie object at the given URL.

Specified by:
rateMovie in interface VideoActions
Parameters:
movieUrl - The URL of the movie that is being rated. Must reference an OpenGraph object of type "video.movie".
rating - The rating given to the movie, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
metadata - Action metadata to be applied to the action. May be an instance of RatingActionMetadata to apply review text and/or a review link to the rating.
Returns:
The ID for the action created.

rateEpisode

public String rateEpisode(String episodeUrl,
                          float rating,
                          int scale)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph episode object at the given URL.

Specified by:
rateEpisode in interface VideoActions
Parameters:
episodeUrl - The URL of the episode that is being rated. Must reference an OpenGraph object of type "video.episode".
rating - The rating given to the movie, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
Returns:
The ID for the action created.

rateEpisode

public String rateEpisode(String episodeUrl,
                          float rating,
                          int scale,
                          ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph episode object at the given URL.

Specified by:
rateEpisode in interface VideoActions
Parameters:
episodeUrl - The URL of the episode that is being rated. Must reference an OpenGraph object of type "video.episode".
rating - The rating given to the episode, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
metadata - Action metadata to be applied to the action. May be an instance of RatingActionMetadata to apply review text and/or a review link to the rating.
Returns:
The ID for the action created.

rateTvShow

public String rateTvShow(String tvShowUrl,
                         float rating,
                         int scale)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph TV show object at the given URL.

Specified by:
rateTvShow in interface VideoActions
Parameters:
tvShowUrl - The URL of the TV show that is being rated. Must reference an OpenGraph object of type "video.tv_show".
rating - The rating given to the movie, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
Returns:
The ID for the action created.

rateTvShow

public String rateTvShow(String tvShowUrl,
                         float rating,
                         int scale,
                         ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph TV show object at the given URL.

Specified by:
rateTvShow in interface VideoActions
Parameters:
tvShowUrl - The URL of the TV show that is being rated. Must reference an OpenGraph object of type "video.tv_show".
rating - The rating given to the TV show, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
metadata - Action metadata to be applied to the action. May be an instance of RatingActionMetadata to apply review text and/or a review link to the rating.
Returns:
The ID for the action created.

rateVideo

public String rateVideo(String otherUrl,
                        float rating,
                        int scale)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph video object at the given URL.

Specified by:
rateVideo in interface VideoActions
Parameters:
otherUrl - The URL of the video that is being rated. Must reference an OpenGraph object of type "video.other".
rating - The rating given to the video, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
Returns:
The ID for the action created.

rateVideo

public String rateVideo(String otherUrl,
                        float rating,
                        int scale,
                        ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph video object at the given URL.

Specified by:
rateVideo in interface VideoActions
Parameters:
otherUrl - The URL of the video that is being rated. Must reference an OpenGraph object of type "video.other".
rating - The rating given to the video, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
metadata - Action metadata to be applied to the action. May be an instance of RatingActionMetadata to apply review text and/or a review link to the rating.
Returns:
The ID for the action created.

rateVideo

public String rateVideo(String videoType,
                        String videoUrl,
                        float rating,
                        int scale,
                        ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.rates" action for the OpenGraph video object at the given URL. Generic method for creating "video.rates" action allowing for future addition of video types that aren't currently supported by Facebook.

Specified by:
rateVideo in interface VideoActions
Parameters:
videoType - The type of video being rated. E.g., "movie", "tv_show", "tv_episode", "episode", "other", etc.
videoUrl - The URL of the video that is being rated. Must reference an OpenGraph object of type "video.other", "video.movie", "video.tv_show", or "video.episode".
rating - The rating given to the video, relative to the scale attribute. (e.g., "{rating} out of {scale} stars")
scale - The maximum rating possible.
metadata - Action metadata to be applied to the action. May be an instance of RatingActionMetadata to apply review text and/or a review link to the rating.
Returns:
The ID for the action created.

wantsToWatchMovie

public String wantsToWatchMovie(String movieUrl)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph movie object at the given URL.

Specified by:
wantsToWatchMovie in interface VideoActions
Parameters:
movieUrl - The URL of the movie that is wanted to be watched. Must reference an OpenGraph object of type "video.movie".
Returns:
The ID for the action created.

wantsToWatchMovie

public String wantsToWatchMovie(String movieUrl,
                                ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph movie object at the given URL.

Specified by:
wantsToWatchMovie in interface VideoActions
Parameters:
movieUrl - The URL of the movie that is wanted to be watched. Must reference an OpenGraph object of type "video.movie".
metadata - Action metadata to be applied to the action. May be an instance of WatchActionMetadata.
Returns:
The ID for the action created.

wantsToWatchTvShow

public String wantsToWatchTvShow(String tvShowUrl)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph TV show object at the given URL.

Specified by:
wantsToWatchTvShow in interface VideoActions
Parameters:
tvShowUrl - The URL of the TV show that is wanted to be watched. Must reference an OpenGraph object of type "video.tv_show".
Returns:
The ID for the action created.

wantsToWatchTvShow

public String wantsToWatchTvShow(String tvShowUrl,
                                 ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph TV show object at the given URL.

Specified by:
wantsToWatchTvShow in interface VideoActions
Parameters:
tvShowUrl - The URL of the TV show that is wanted to be watched. Must reference an OpenGraph object of type "video.tv_show".
metadata - Action metadata to be applied to the action. May be an instance of WatchActionMetadata.
Returns:
The ID for the action created.

wantsToWatchEpisode

public String wantsToWatchEpisode(String episodeUrl)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph episode object at the given URL.

Specified by:
wantsToWatchEpisode in interface VideoActions
Parameters:
episodeUrl - The URL of the episode that is wanted to be watched. Must reference an OpenGraph object of type "video.episode".
Returns:
The ID for the action created.

wantsToWatchEpisode

public String wantsToWatchEpisode(String episodeUrl,
                                  ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph episode object at the given URL.

Specified by:
wantsToWatchEpisode in interface VideoActions
Parameters:
episodeUrl - The URL of the episode that is wanted to be watched. Must reference an OpenGraph object of type "video.episode".
metadata - Action metadata to be applied to the action. May be an instance of WatchActionMetadata.
Returns:
The ID for the action created.

wantsToWatchVideo

public String wantsToWatchVideo(String otherUrl)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph video object at the given URL.

Specified by:
wantsToWatchVideo in interface VideoActions
Parameters:
otherUrl - The URL of the video that is wanted to be watched. Must reference an OpenGraph object of type "video.other".
Returns:
The ID for the action created.

wantsToWatchVideo

public String wantsToWatchVideo(String otherUrl,
                                ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph video object at the given URL.

Specified by:
wantsToWatchVideo in interface VideoActions
Parameters:
otherUrl - The URL of the video that is wanted to be watched. Must reference an OpenGraph object of type "video.other".
metadata - Action metadata to be applied to the action. May be an instance of WatchActionMetadata.
Returns:
The ID for the action created.

wantsToWatch

public String wantsToWatch(String videoType,
                           String videoUrl,
                           ActionMetadata metadata)
Description copied from interface: VideoActions
Publishes a "video.wants_to_watch" action for the OpenGraph video object at the given URL. Generic method that allows for future addition of video types that are currently unsupported by Facebook.

Specified by:
wantsToWatch in interface VideoActions
Parameters:
videoType - The type of video that is wanted to be watched. E.g., "movie", "tv_show", "tv_episode", "episode", "other", etc.
videoUrl - The URL of the video that is wanted to be watched. Must reference an OpenGraph object of type "video.other".
metadata - Action metadata to be applied to the action. May be an instance of WatchActionMetadata.
Returns:
The ID for the action created.