C# Class TraktPlugin.TraktHandlers.TVSeries

Support for TVSeries
Inheritance: ITraktHandler
Exibir arquivo Open project: trakt/Trakt-for-Mediaportal Class Usage Examples

Public Methods

Method Description
DisposeEvents ( ) : void
FindEpisodeInFacade ( DBEpisode episode ) : GUIListItem

Finds an episode in the current TVSeries Episode List

GetEpisodeInfo ( Object obj, string &title, string &year, string &showTvdbId, string &epTvdbId, string &seasonidx, string &episodeidx, bool &isWatched ) : bool

Get Episode Info for selected object

GetEpisodePersonInfo ( Object obj, SearchPeople &searchPeople ) : bool
GetSelectedType ( Object obj ) : SelectedType

Get the current selected facade item in TVSeries

GetSeriesInfo ( Object obj, string &title, string &year, string &tvdb ) : bool

Get Series Info for selected object

GetSeriesPersonInfo ( Object obj, SearchPeople &searchPeople ) : bool
PlayEpisode ( DBEpisode episode ) : bool
PlayEpisode ( int seriesid, int seasonid, int episodeid ) : bool

Playback an episode using TVSeries internal Video Handler

PlayFirstUnwatchedEpisode ( int seriesid ) : bool

Playback the first unwatched episode for a series using TVSeries internal Video Handler If no Unwatched episodes exists, play the Most Recently Aired

Scrobble ( string filename ) : bool
SeriesExists ( int seriesId ) : bool

Checks if the series id exists in the local collection

SetEpisodeUserRating ( int rating ) : void
SetShowUserRating ( int rating ) : void
StopScrobble ( ) : void
SyncLibrary ( ) : void
SyncProgress ( ) : void
TVSeries ( int priority ) : System
UpdateSettingAsBool ( string setting, bool value ) : void

Private Methods

Method Description
CreateLookupKey ( DBEpisode episode ) : string
CreateLookupKey ( TraktCache episode ) : string
CreateLookupKey ( TraktEpisodeRated item ) : string
CreateScrobbleData ( DBEpisode episode, double progress ) : TraktScrobbleEpisode

Creates Scrobble data based on a DBEpisode object

EpisodeMatch ( DBEpisode localEpisode, TraktCache onlineEpisode ) : bool
EpisodeMatch ( DBEpisode localEpisode, TraktEpisode onlineEpisode, TraktShow onlineShow ) : bool
GetCollectedEpisodesForSync ( List localCollectedEpisodes, List traktCollectedEpisodes ) : List

Returns a list of episodes for collection sync (uses episode ids) This may not be ideal as it depends on trakt knowing the episode tvdb ids since there is no show data to fallback on.

GetCollectedShowsForSyncEx ( List localCollectedEpisodes, List traktEpisodesCollected ) : TraktSyncShowsCollectedEx

Returns a list of shows for collection sync as show objects with season / episode hierarchy

GetEpisodeAudioChannels ( DBEpisode episode ) : string

Gets the trakt compatible string for the episodes Audio Channels

GetEpisodeAudioCodec ( DBEpisode episode ) : string

Gets the trakt compatible string for the episodes Audio

GetEpisodeMediaType ( DBEpisode episode ) : string

Gets the trakt compatible string for the episodes Media Type

GetEpisodeResolution ( DBEpisode episode ) : string

Gets the trakt compatible string for the episodes Resolution

GetLastPlayedDate ( DBEpisode episode ) : string

Gets the last time the episode

GetPlayerProgress ( DBEpisode episode ) : double

Get the current g_Player progress of the playing episode

GetRatedEpisodesForSync ( List localRatedEpisodes, List traktRatedEpisodes ) : List

Returns a list of episodes for ratings sync (uses episode ids) This may not be ideal as it depends on trakt knowing the episode tvdb ids since there is no show data to fallback on.

GetRatedEpisodesForSyncEx ( List localRatedEpisodes, List traktEpisodesRated ) : TraktPlugin.TraktAPI.DataStructures.TraktSyncShowsRatedEx

Returns a list of shows for rating sync as show objects with season / episode hierarchy

GetRemovedEpisodesForSync ( List localCollectedEpisodes, List traktCollectedEpisodes ) : List

Returns a list of episodes for removal sync (uses episode ids) This may not be ideal as it depends on trakt knowing the episode tvdb ids since there is no show data to fallback on.

GetRemovedShowsForSyncEx ( List localCollectedEpisodes, List traktEpisodesCollected ) : TraktSyncShowsEx

Returns a list of shows for removal sync as show objects with season / episode hierarchy

GetWatchedEpisodesForSync ( List localWatchedEpisodes, List traktWatchedEpisodes ) : List

Returns a list of episodes for watched history sync (uses episode ids) This may not be ideal as it depends on trakt knowing the episode tvdb ids since there is no show data to fallback on.

GetWatchedShowsForSyncEx ( List localWatchedEpisodes, List traktEpisodesWatched ) : TraktSyncShowsWatchedEx

Returns a list of shows for watched history sync as show objects with season / episode hierarchy

MarkEpisodesAsUnWatched ( WindowPlugins.GUITVSeries.DBSeries show, List episodes ) : void
MarkEpisodesAsWatched ( WindowPlugins.GUITVSeries.DBSeries show, List episodes ) : void
OnEpisodeStarted ( DBEpisode episode ) : void
OnEpisodeStopped ( DBEpisode episode ) : void
OnEpisodeWatched ( DBEpisode episode ) : void
OnEpisodeWatched ( DBEpisode episode, bool isPlaylist ) : void
OnImportCompleted ( bool newEpisodeAdded ) : void
OnPlaylistEpisodeWatched ( DBEpisode episode ) : void
OnRateItem ( WindowPlugins.GUITVSeries.DBTable item, string value ) : void
OnToggleWatched ( WindowPlugins.GUITVSeries.DBSeries show, List episodes, bool watched ) : void
RateEpisode ( DBEpisode episode ) : void
RateShow ( WindowPlugins.GUITVSeries.DBSeries show ) : void
ShowMatch ( WindowPlugins.GUITVSeries.DBSeries localShow, TraktShow onlineShow ) : bool
ShowRateDialog ( DBEpisode episode, bool isPlaylist ) : void

Shows the Rate Episode Dialog after playback has ended

Method Details

DisposeEvents() public method

public DisposeEvents ( ) : void
return void

FindEpisodeInFacade() public static method

Finds an episode in the current TVSeries Episode List
public static FindEpisodeInFacade ( DBEpisode episode ) : GUIListItem
episode DBEpisode
return MediaPortal.GUI.Library.GUIListItem

GetEpisodeInfo() public static method

Get Episode Info for selected object
public static GetEpisodeInfo ( Object obj, string &title, string &year, string &showTvdbId, string &epTvdbId, string &seasonidx, string &episodeidx, bool &isWatched ) : bool
obj Object
title string
year string
showTvdbId string
epTvdbId string
seasonidx string
episodeidx string
isWatched bool
return bool

GetEpisodePersonInfo() public static method

public static GetEpisodePersonInfo ( Object obj, SearchPeople &searchPeople ) : bool
obj Object
searchPeople TraktPlugin.GUI.SearchPeople
return bool

GetSelectedType() public static method

Get the current selected facade item in TVSeries
public static GetSelectedType ( Object obj ) : SelectedType
obj Object TVTag object
return SelectedType

GetSeriesInfo() public static method

Get Series Info for selected object
public static GetSeriesInfo ( Object obj, string &title, string &year, string &tvdb ) : bool
obj Object
title string
year string
tvdb string
return bool

GetSeriesPersonInfo() public static method

public static GetSeriesPersonInfo ( Object obj, SearchPeople &searchPeople ) : bool
obj Object
searchPeople TraktPlugin.GUI.SearchPeople
return bool

PlayEpisode() public static method

public static PlayEpisode ( DBEpisode episode ) : bool
episode DBEpisode
return bool

PlayEpisode() public static method

Playback an episode using TVSeries internal Video Handler
public static PlayEpisode ( int seriesid, int seasonid, int episodeid ) : bool
seriesid int series id of episode
seasonid int season index
episodeid int episode index
return bool

PlayFirstUnwatchedEpisode() public static method

Playback the first unwatched episode for a series using TVSeries internal Video Handler If no Unwatched episodes exists, play the Most Recently Aired
public static PlayFirstUnwatchedEpisode ( int seriesid ) : bool
seriesid int series id of episode
return bool

Scrobble() public method

public Scrobble ( string filename ) : bool
filename string
return bool

SeriesExists() public static method

Checks if the series id exists in the local collection
public static SeriesExists ( int seriesId ) : bool
seriesId int
return bool

SetEpisodeUserRating() public static method

public static SetEpisodeUserRating ( int rating ) : void
rating int
return void

SetShowUserRating() public static method

public static SetShowUserRating ( int rating ) : void
rating int
return void

StopScrobble() public method

public StopScrobble ( ) : void
return void

SyncLibrary() public method

public SyncLibrary ( ) : void
return void

SyncProgress() public method

public SyncProgress ( ) : void
return void

TVSeries() public method

public TVSeries ( int priority ) : System
priority int
return System

UpdateSettingAsBool() public static method

public static UpdateSettingAsBool ( string setting, bool value ) : void
setting string
value bool
return void