feat: migrate playback module to modular domain pattern
This commit is contained in:
27
internal/domain/provider.go
Normal file
27
internal/domain/provider.go
Normal file
@@ -0,0 +1,27 @@
|
||||
package domain
|
||||
|
||||
import (
|
||||
"context"
|
||||
)
|
||||
|
||||
type StreamSource struct {
|
||||
URL string
|
||||
Quality string
|
||||
}
|
||||
|
||||
type StreamResult struct {
|
||||
URL string
|
||||
Referer string
|
||||
Subtitles []Subtitle
|
||||
Qualities []StreamSource
|
||||
}
|
||||
|
||||
type Subtitle struct {
|
||||
URL string
|
||||
Label string
|
||||
}
|
||||
|
||||
type Provider interface {
|
||||
Name() string
|
||||
GetStreams(ctx context.Context, animeID int, episode string, mode string) (*StreamResult, error)
|
||||
}
|
||||
Reference in New Issue
Block a user