Méthode | Description | |
---|---|---|
DiscoverDynamicCategories ( ) : int |
If the site's categories can be retrieved dynamically, then it should be done in the implementation of this method. The categories must be added to the SiteSettings retrieved from the Settings property of this class. Once the categories are added you should set SiteSettings.DynamicCategoriesDiscovered to true, so this method won't be called each time the user enters this site in the GUI (unless you want that behavior).
|
|
DiscoverNextPageCategories ( NextPageCategory category ) : int |
Override this method in your derived Util when you need paging in a list of Categorys. It will be called when the last item in that list is a NextPageCategory.
|
|
DiscoverSubCategories ( Category parentCategory ) : int |
If a category has sub-categories this function will be called when the user selects a category in the GUI. This happens only when Category.HasSubCategories is true and Category.SubCategoriesDiscovered is false.
|
|
ExecuteContextMenuEntry ( Category selectedCategory, System.VideoInfo selectedItem, OnlineVideos.Sites.ContextMenuEntry choice ) : OnlineVideos.Sites.ContextMenuExecutionResult |
This function is called when one of the custom contextmenu entries was selected by the user. Override it to handle the entries you added with GetContextMenuEntries.
|
|
GetContextMenuEntries ( Category selectedCategory, System.VideoInfo selectedItem ) : List |
This function will be called when a contextmenu for a video or category is to be shown in the GUI. Override it to add your own entries (which should be localized).
|
|
GetCurrentVideosTitle ( ) : string |
Should return the title of the current page, which will be put in #header.label at state=videos when showing videos returned from a search
|
|
GetFileNameForDownload ( System.VideoInfo video, Category category, string url ) : string |
This method will be called before downloading the video from the given url, or before adding it to the favorites. (in that case the url param is null.
|
|
GetMultipleVideoUrls ( System.VideoInfo video, bool inPlaylist = false ) : List |
This function will be called to get the urls for playback of a video. Use this if your video is split into smaller parts for playback.
|
|
GetNextPageVideos ( ) : List |
This function should return the videos of the next page. No state is given, so the class implementation has to remember and set the current category and page itself. It will only be called if HasNextPage returned true on the last call and after the user selected the menu entry for "next page".
|
|
GetPlaylistItemVideoUrl ( System.VideoInfo clonedVideoInfo, string chosenPlaybackOption, bool inPlaylist = false ) : string |
Allows the Util to resolve the url of a playlist item to playback options or a new url directly before playback.
|
|
GetSearchableCategories ( ) : string>.Dictionary |
Will be called to get the list of categories (names only) that can be chosen to search. The keys will be the names and the value will be given to the Search as parameter.
|
|
GetTrackingInfo ( System.VideoInfo video ) : ITrackingInfo |
This method will ask the Util to provide information for a VideoInfo that can be used to identify the video for http://trakt.tv/.
|
|
GetVideoUrl ( System.VideoInfo video ) : String |
This function will be called when the user selects a video for playback. It should return the absolute url to the video file.
|
|
GetVideos ( Category category ) : List |
This is the only function a subclass has to implement. It's called when a user selects a category in the GUI.
|
|
Initialize ( SiteSettings siteSettings ) : void |
You should always call this implementation, even when overriding it. It is called after the instance has been created in order to configure settings from the xml for this util.
|
|
IsPossibleVideo ( string fsUrl ) : bool |
This function checks a given string, if it points to a file that is a valid video. It will check for protocol and known and supported video extensions.
|
|
OnDownloadEnded ( System.VideoInfo video, string url, double percent, bool stoppedByUser ) : void |
This method will be called after download of a video from this site was stopped or has ended.
|
|
OnPlaybackEnded ( System.VideoInfo video, string url, double percent, bool stoppedByUser ) : void |
This method will be called after playback of a video from this site was stopped or has ended.
|
|
Search ( string query, string category = null ) : List |
Should return a list of VideoInfo or Category for the given query - limited to the given category if not null.
|
|
ToString ( ) : string |
Méthode | Description | |
---|---|---|
GetConfigurationKey ( string fieldName ) : string |
public DiscoverNextPageCategories ( NextPageCategory category ) : int | ||
category | NextPageCategory | The category item that you used to store info about how to get the next page categories. |
Résultat | int |
public DiscoverSubCategories ( Category parentCategory ) : int | ||
parentCategory | Category | the category that was selected by the user |
Résultat | int |
public ExecuteContextMenuEntry ( Category selectedCategory, System.VideoInfo selectedItem, OnlineVideos.Sites.ContextMenuEntry choice ) : OnlineVideos.Sites.ContextMenuExecutionResult | ||
selectedCategory | Category | either the |
selectedItem | System.VideoInfo | when this is null the context menu was called on the |
choice | OnlineVideos.Sites.ContextMenuEntry | the |
Résultat | OnlineVideos.Sites.ContextMenuExecutionResult |
public GetContextMenuEntries ( Category selectedCategory, System.VideoInfo selectedItem ) : List |
||
selectedCategory | Category | either the |
selectedItem | System.VideoInfo | when this is null the context menu is called on the |
Résultat | List |
public GetFileNameForDownload ( System.VideoInfo video, Category category, string url ) : string | ||
video | System.VideoInfo | The |
category | Category | The |
url | string | The url from which the download will take place. If null, a favorite name should be returned. |
Résultat | string |
public GetMultipleVideoUrls ( System.VideoInfo video, bool inPlaylist = false ) : List |
||
video | System.VideoInfo | The |
inPlaylist | bool | |
Résultat | List |
public GetPlaylistItemVideoUrl ( System.VideoInfo clonedVideoInfo, string chosenPlaybackOption, bool inPlaylist = false ) : string | ||
clonedVideoInfo | System.VideoInfo | A clone of the original |
chosenPlaybackOption | string | the key from the |
inPlaylist | bool | |
Résultat | string |
public GetSearchableCategories ( ) : string>.Dictionary |
||
Résultat | string>.Dictionary |
public GetTrackingInfo ( System.VideoInfo video ) : ITrackingInfo | ||
video | System.VideoInfo | The |
Résultat | ITrackingInfo |
public GetVideoUrl ( System.VideoInfo video ) : String | ||
video | System.VideoInfo | The |
Résultat | String |
public abstract GetVideos ( Category category ) : List |
||
category | Category | The |
Résultat | List |
public Initialize ( SiteSettings siteSettings ) : void | ||
siteSettings | SiteSettings | |
Résultat | void |
public IsPossibleVideo ( string fsUrl ) : bool | ||
fsUrl | string | the string to check which should be a valid URI. |
Résultat | bool |
public OnDownloadEnded ( System.VideoInfo video, string url, double percent, bool stoppedByUser ) : void | ||
video | System.VideoInfo | |
url | string | |
percent | double | |
stoppedByUser | bool | |
Résultat | void |
public OnPlaybackEnded ( System.VideoInfo video, string url, double percent, bool stoppedByUser ) : void | ||
video | System.VideoInfo | |
url | string | |
percent | double | |
stoppedByUser | bool | |
Résultat | void |
public Search ( string query, string category = null ) : List |
||
query | string | The user entered query. |
category | string | The category to search in, can be null to indicate a global search - not limited to a category. |
Résultat | List |