add Jellyfin albumiterator

This commit is contained in:
Drew Weymouth
2023-11-14 09:05:02 -08:00
parent 08ca09d686
commit 8aed1e5234
6 changed files with 86 additions and 21 deletions
+7
View File
@@ -14,6 +14,13 @@ type AlbumFilter struct {
ExcludeUnfavorited bool // mut. exc. with ExcludeFavorited
}
// Returns true if the filter is the nil filter - i.e. matches everything
func (a *AlbumFilter) IsNil() bool {
return a.MinYear == 0 && a.MaxYear == 0 &&
len(a.Genres) == 0 &&
!a.ExcludeFavorited && !a.ExcludeUnfavorited
}
type AlbumIterator interface {
Next() *Album
}