anime

package module
v0.0.0-...-1aee6c4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 13, 2021 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Anime

type Anime struct {
	Id       int        `firestore:"-"`
	Name     string     `firestore:"name"`
	Episodes []*Episode `firestore:"episodes"`
}

func NewAnime

func NewAnime() *Anime

func (*Anime) AppendFile

func (a *Anime) AppendFile(filePath string) error

func (*Anime) CheckAnime

func (a *Anime) CheckAnime() error

func (*Anime) GetAnimeEpisodeDb

func (a *Anime) GetAnimeEpisodeDb(c *firestore.Client, ctx context.Context) error

func (*Anime) GetAnimeFromDb

func (a *Anime) GetAnimeFromDb(c *firestore.Client, ctx context.Context) error

func (*Anime) GetAnimeInfoFromDb

func (a *Anime) GetAnimeInfoFromDb(c *firestore.Client, ctx context.Context) error

func (*Anime) SendToDb

func (a *Anime) SendToDb(db *kaoriDatabase.NoSqlDb) error

func (*Anime) SendToDbRel

func (a *Anime) SendToDbRel(cl *sql.DB) error

func (*Anime) SendToKaori

func (a *Anime) SendToKaori(kaoriUrl, token string) error

type Episode

type Episode struct {
	Number string `firestore:"number"`
	Title  string
	Videos []*Video
}

func GetEpisodeFromDB

func GetEpisodeFromDB(db *sql.DB, idAnime int, numEp int) (*Episode, error)

func GetEpisodesFromDB

func GetEpisodesFromDB(db *sql.DB, idAnime int) (eps []*Episode, err error)

func NewEpisode

func NewEpisode() *Episode

func (*Episode) CheckEpisode

func (ep *Episode) CheckEpisode() error

func (*Episode) SendToDbRel

func (ep *Episode) SendToDbRel(cl *sql.DB, IdAnime int) (int, error)

type InfoQuality

type InfoQuality struct {
	Width  int `firestore:"width"`
	Height int `firestore:"height"`
}
type StreamLink struct {
	Link     string  `firestore:"link"`
	Fansub   string  `firestore:"fansub"`
	Duration float64 `firestore:"duration"`
	Bitrate  int     `firestore:"bitrate"`
}

type Video

type Video struct {
	Language   string
	Modality   string
	Quality    *InfoQuality
	Server     string
	StreamLink *StreamLink
}

func GetVideoFromDB

func GetVideoFromDB(db *sql.DB, episodeID int) (videos []*Video, err error)

func NewVideo

func NewVideo() *Video

func (*Video) CheckVideo

func (v *Video) CheckVideo() error

func (*Video) GetQuality

func (v *Video) GetQuality(link string) error

func (*Video) SendToDbRel

func (v *Video) SendToDbRel(cl *sql.DB, episodeID int) (int, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL