2020-01-14 18:22:34 -09:00
|
|
|
package model
|
2016-03-02 05:07:24 -09:00
|
|
|
|
|
|
|
|
type ArtistInfo struct {
|
2020-01-09 19:33:01 -09:00
|
|
|
ArtistID string
|
2016-03-27 16:13:00 -08:00
|
|
|
Artist string
|
|
|
|
|
AlbumCount int
|
2016-03-02 05:07:24 -09:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type ArtistIndex struct {
|
2020-01-10 15:41:35 -09:00
|
|
|
ID string
|
2016-03-03 17:42:12 -09:00
|
|
|
Artists ArtistInfos
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
type ArtistInfos []ArtistInfo
|
2016-03-03 17:01:55 -09:00
|
|
|
type ArtistIndexes []ArtistIndex
|
|
|
|
|
|
2016-03-02 05:07:24 -09:00
|
|
|
type ArtistIndexRepository interface {
|
2020-01-15 04:21:32 -09:00
|
|
|
CountAll() (int64, error)
|
|
|
|
|
Exists(id string) (bool, error)
|
2016-03-02 05:07:24 -09:00
|
|
|
Put(m *ArtistIndex) error
|
|
|
|
|
Get(id string) (*ArtistIndex, error)
|
2016-03-20 09:08:24 -08:00
|
|
|
GetAll() (ArtistIndexes, error)
|
2016-03-26 18:29:26 -08:00
|
|
|
DeleteAll() error
|
2016-03-02 05:07:24 -09:00
|
|
|
}
|