Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FileNameCleaner ¶
FileNameCleaner return a safe file name from a given show name.
func Format2Digits ¶
Format2Digits return a number with 2 digits when there is only one digit
func PathNameCleaner ¶
PathNameCleaner return a safe path name from a given show name.
Types ¶
type MatchRequest ¶
type MatchRequest struct { // Fields for matching Show string ShowID string // Future use Title string TitleID string // Future use Pitch string Provider string Playlist string // Playlist search is implemented in providers. MaxAgedDays int // Retrive media younger than MaxAgedDays when not zero // Destination name when found Destination string RetentionDays int // Media retention time, when not zero the system will delete old files }
MatchRequest holds criterions for selecting show
type Media ¶ added in v0.7.0
type Media struct { ID string // Show ID ShowType ShowType // Movie or Series? Metadata MetaDataHandler // Carry metadata scrapped online Match *MatchRequest // Matched request }
Media represents a media to be handled.
func (*Media) SetMetaData ¶ added in v0.7.0
func (m *Media) SetMetaData(info MetaDataHandler)
type MetaDataHandler ¶ added in v0.7.0
type MetaDataHandler interface { GetMediaInfo() *nfo.MediaInfo GetNFOPath(destination string) string GetSeasonNFOPath(destination string) string GetShowNFOPath(destination string) string GetSeriesPath(destination string) string GetMediaPath(destination string) string GetSeasonPath(destination string) string GetMediaPathMatcher(destination string) string WriteNFO(destination string) error }
MetaDataHandler represents a struct for managing media's metadata
type Provider ¶
type Provider interface { Configure(c Config) // Pass general configuration Name() string // Provider's name MediaList(context.Context, []*MatchRequest) chan *Media // List of available shows that match one of MatchRequest GetMediaDetails(context.Context, *Media) error // Download more details when available }
Provider is the interface for a provider
Click to show internal directories.
Click to hide internal directories.