Documentation ¶
Index ¶
- func AlistAuthorizationCacheWithUserIDInitFunc(userID string) func(ctx context.Context, args ...struct{}) (*AlistUserCacheData, error)
- func BilibiliAuthorizationCacheWithUserIDInitFunc(userID string) func(ctx context.Context, args ...struct{}) (*BilibiliUserCacheData, error)
- func BilibiliNoSharedMovieCacheInitFunc(ctx context.Context, movie *model.Movie, args ...*BilibiliUserCache) (string, error)
- func EmbyAuthorizationCacheWithUserIDInitFunc(userID string) func(ctx context.Context, args ...struct{}) (*EmbyUserCacheData, error)
- func NewAlistMovieCacheInitFunc(movie *model.Movie) ...
- func NewBilibiliNoSharedMovieCacheInitFunc(movie *model.Movie) func(ctx context.Context, args ...*BilibiliUserCache) (string, error)
- func NewBilibiliSharedMpdCacheInitFunc(movie *model.Movie) ...
- func NewBilibiliSubtitleCacheInitFunc(movie *model.Movie) ...
- func NewEmbyMovieCacheInitFunc(movie *model.Movie) func(ctx context.Context, args ...*EmbyUserCache) (*EmbyMovieCacheData, error)
- type AliSubtitle
- type AliSubtitleCache
- type AlistMovieCache
- type AlistMovieCacheData
- type AlistUserCache
- type AlistUserCacheData
- type BilibiliMovieCache
- type BilibiliMpdCache
- type BilibiliSubtitleCache
- type BilibiliUserCache
- type BilibiliUserCacheData
- type EmbyMovieCache
- type EmbyMovieCacheData
- type EmbySource
- type EmbyUserCache
- type EmbyUserCacheData
- type MapCache
- func (b *MapCache[T, A]) Clear()
- func (b *MapCache[T, A]) LoadOrStore(ctx context.Context, id string, args ...A) (T, error)
- func (b *MapCache[T, A]) LoadOrStoreWithDynamicFunc(ctx context.Context, id string, refreshFunc MapRefreshFunc[T, A], args ...A) (T, error)
- func (b *MapCache[T, A]) StoreOrRefresh(ctx context.Context, id string, args ...A) (T, error)
- func (b *MapCache[T, A]) StoreOrRefreshWithDynamicFunc(ctx context.Context, id string, refreshFunc MapRefreshFunc[T, A], args ...A) (T, error)
- type MapRefreshFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AlistAuthorizationCacheWithUserIDInitFunc ¶
func AlistAuthorizationCacheWithUserIDInitFunc(userID string) func(ctx context.Context, args ...struct{}) (*AlistUserCacheData, error)
func BilibiliAuthorizationCacheWithUserIDInitFunc ¶
func BilibiliAuthorizationCacheWithUserIDInitFunc(userID string) func(ctx context.Context, args ...struct{}) (*BilibiliUserCacheData, error)
func EmbyAuthorizationCacheWithUserIDInitFunc ¶
func EmbyAuthorizationCacheWithUserIDInitFunc(userID string) func(ctx context.Context, args ...struct{}) (*EmbyUserCacheData, error)
func NewAlistMovieCacheInitFunc ¶
func NewAlistMovieCacheInitFunc(movie *model.Movie) func(ctx context.Context, args ...*AlistUserCache) (*AlistMovieCacheData, error)
func NewBilibiliSharedMpdCacheInitFunc ¶
func NewBilibiliSharedMpdCacheInitFunc(movie *model.Movie) func(ctx context.Context, args ...*BilibiliUserCache) (*BilibiliMpdCache, error)
func NewBilibiliSubtitleCacheInitFunc ¶
func NewBilibiliSubtitleCacheInitFunc(movie *model.Movie) func(ctx context.Context, args ...*BilibiliUserCache) (BilibiliSubtitleCache, error)
func NewEmbyMovieCacheInitFunc ¶
func NewEmbyMovieCacheInitFunc(movie *model.Movie) func(ctx context.Context, args ...*EmbyUserCache) (*EmbyMovieCacheData, error)
Types ¶
type AliSubtitle ¶
type AliSubtitle struct { Raw *alist.FsOtherResp_VideoPreviewPlayInfo_LiveTranscodingSubtitleTaskList Cache *AliSubtitleCache }
type AliSubtitleCache ¶
type AliSubtitleCache = refreshcache.RefreshCache[[]byte, struct{}]
type AlistMovieCache ¶
type AlistMovieCache = refreshcache.RefreshCache[*AlistMovieCacheData, *AlistUserCache]
func NewAlistMovieCache ¶
func NewAlistMovieCache(movie *model.Movie) *AlistMovieCache
type AlistMovieCacheData ¶
type AlistMovieCacheData struct { URL string AliM3U8ListFile []byte AliSubtitles []*AliSubtitle }
type AlistUserCache ¶
type AlistUserCache = refreshcache.RefreshCache[*AlistUserCacheData, struct{}]
func NewAlistUserCache ¶
func NewAlistUserCache(userID string) *AlistUserCache
type AlistUserCacheData ¶
func AlistAuthorizationCacheWithConfigInitFunc ¶
func AlistAuthorizationCacheWithConfigInitFunc(ctx context.Context, v *model.AlistVendor) (*AlistUserCacheData, error)
type BilibiliMovieCache ¶
type BilibiliMovieCache struct { Subtitle *refreshcache.RefreshCache[BilibiliSubtitleCache, *BilibiliUserCache] }
func NewBilibiliMovieCache ¶
func NewBilibiliMovieCache(movie *model.Movie) *BilibiliMovieCache
type BilibiliMpdCache ¶
func BilibiliSharedMpdCacheInitFunc ¶
func BilibiliSharedMpdCacheInitFunc(ctx context.Context, movie *model.Movie, args ...*BilibiliUserCache) (*BilibiliMpdCache, error)
type BilibiliSubtitleCache ¶
type BilibiliSubtitleCache map[string]*struct { Url string Srt *refreshcache.RefreshCache[[]byte, struct{}] }
func BilibiliSubtitleCacheInitFunc ¶
func BilibiliSubtitleCacheInitFunc(ctx context.Context, movie *model.Movie, args ...*BilibiliUserCache) (BilibiliSubtitleCache, error)
type BilibiliUserCache ¶
type BilibiliUserCache = refreshcache.RefreshCache[*BilibiliUserCacheData, struct{}]
func NewBilibiliUserCache ¶
func NewBilibiliUserCache(userID string) *BilibiliUserCache
type BilibiliUserCacheData ¶
type EmbyMovieCache ¶
type EmbyMovieCache = refreshcache.RefreshCache[*EmbyMovieCacheData, *EmbyUserCache]
func NewEmbyMovieCache ¶
func NewEmbyMovieCache(movie *model.Movie) *EmbyMovieCache
type EmbyMovieCacheData ¶
type EmbyMovieCacheData struct {
Sources []EmbySource
}
type EmbySource ¶
type EmbySource struct { URLs []struct { URL string Name string } Subtitles []struct { URL string Type string Name string Cache *refreshcache.RefreshCache[[]byte, struct{}] } }
type EmbyUserCache ¶
type EmbyUserCache = refreshcache.RefreshCache[*EmbyUserCacheData, struct{}]
func NewEmbyUserCache ¶
func NewEmbyUserCache(userID string) *EmbyUserCache
type EmbyUserCacheData ¶
type MapCache ¶
func (*MapCache[T, A]) LoadOrStore ¶
func (*MapCache[T, A]) LoadOrStoreWithDynamicFunc ¶
func (*MapCache[T, A]) StoreOrRefresh ¶
func (*MapCache[T, A]) StoreOrRefreshWithDynamicFunc ¶
Click to show internal directories.
Click to hide internal directories.