quintodrome/domain/mediafile.go

36 lines
631 B
Go
Raw Normal View History

2016-03-02 05:07:24 -09:00
package domain
2016-02-26 23:35:01 -09:00
import (
"time"
)
type MediaFile struct {
2016-02-26 23:35:01 -09:00
Id string
Path string
Title string
Album string
Artist string
AlbumArtist string
2016-03-02 09:18:39 -09:00
AlbumId string `parent:"album"`
2016-03-03 06:34:17 -09:00
HasCoverArt bool
TrackNumber int
DiscNumber int
Year int
2016-03-02 19:51:26 -09:00
Size string
Suffix string
Duration int
BitRate int
Genre string
2016-02-26 23:35:01 -09:00
Compilation bool
2016-03-02 21:07:13 -09:00
Starred bool
2016-02-26 23:35:01 -09:00
CreatedAt time.Time
UpdatedAt time.Time
}
type MediaFileRepository interface {
BaseRepository
Put(m *MediaFile) error
2016-03-03 08:08:44 -09:00
Get(id string) (*MediaFile, error)
FindByAlbum(albumId string) ([]MediaFile, error)
2016-03-02 09:18:39 -09:00
}