Documentation ¶
Index ¶
- Constants
- func NewAccount(ctx context.Context, alias string, clientID string, clientSecret string, ...) (shared.Account, error)
- func Reauth(ctx context.Context, account shared.Account, clientID string, ...) error
- type AccountActions
- type Actions
- func (e Actions) Album(ctx context.Context, id shared.RemoteID) (shared.RemoteAlbum, error)
- func (e Actions) Artist(ctx context.Context, id shared.RemoteID) (shared.RemoteArtist, error)
- func (e Actions) SearchAlbums(ctx context.Context, what shared.RemoteAlbum) ([10]shared.RemoteAlbum, error)
- func (e Actions) SearchArtists(ctx context.Context, what shared.RemoteArtist) ([10]shared.RemoteArtist, error)
- func (e Actions) SearchTracks(ctx context.Context, what shared.RemoteTrack) ([10]shared.RemoteTrack, error)
- func (e Actions) Track(ctx context.Context, id shared.RemoteID) (shared.RemoteTrack, error)
- type Album
- type AlbumsSearchAction
- type Artist
- type ArtistsSearchAction
- type Entity
- type LikedAlbumsActions
- type LikedArtistsActions
- type LikedTracksActions
- type Playlist
- func (e *Playlist) AddTracks(ctx context.Context, ids []shared.RemoteID) error
- func (e Playlist) Description() *string
- func (e Playlist) FromAccount() shared.Account
- func (e *Playlist) IsVisible() (bool, error)
- func (e *Playlist) RemoveTracks(ctx context.Context, ids []shared.RemoteID) error
- func (e *Playlist) Rename(ctx context.Context, newName string) error
- func (e Playlist) SetDescription(ctx context.Context, newDesc string) error
- func (e *Playlist) SetIsVisible(ctx context.Context, val bool) error
- func (e *Playlist) Tracks(ctx context.Context) ([]shared.RemoteTrack, error)
- type PlaylistActions
- func (e PlaylistActions) Create(ctx context.Context, name string, isVisible bool, description *string) (shared.RemotePlaylist, error)
- func (e PlaylistActions) Delete(ctx context.Context, entities []shared.RemoteID) error
- func (e *PlaylistActions) MyPlaylists(ctx context.Context) ([]shared.RemotePlaylist, error)
- func (e PlaylistActions) Playlist(ctx context.Context, id shared.RemoteID) (shared.RemotePlaylist, error)
- type Remote
- func (s Remote) Actions() (shared.RemoteActions, error)
- func (s Remote) AssignAccountActions(account shared.Account) (shared.AccountActions, error)
- func (s *Remote) Boot(repo shared.RemoteRepository) error
- func (e Remote) EntityURL(etype shared.EntityType, id shared.RemoteID) url.URL
- func (s Remote) Name() shared.RemoteName
- func (s Remote) Repository() shared.RemoteRepository
- type Track
- type TracksSearchAction
Constants ¶
View Source
const (
RemoteName shared.RemoteName = "Spotify"
)
Variables ¶
This section is empty.
Functions ¶
func NewAccount ¶
Types ¶
type AccountActions ¶
type AccountActions struct {
// contains filtered or unexported fields
}
func (AccountActions) LikedAlbums ¶
func (e AccountActions) LikedAlbums() shared.LikedActions
func (AccountActions) LikedArtists ¶
func (e AccountActions) LikedArtists() shared.LikedActions
func (AccountActions) LikedTracks ¶
func (e AccountActions) LikedTracks() shared.LikedActions
func (AccountActions) Playlist ¶
func (e AccountActions) Playlist() shared.PlaylistActions
type Actions ¶
type Actions struct {
// contains filtered or unexported fields
}
func (Actions) SearchAlbums ¶
func (e Actions) SearchAlbums(ctx context.Context, what shared.RemoteAlbum) ([10]shared.RemoteAlbum, error)
func (Actions) SearchArtists ¶
func (e Actions) SearchArtists(ctx context.Context, what shared.RemoteArtist) ([10]shared.RemoteArtist, error)
func (Actions) SearchTracks ¶
func (e Actions) SearchTracks(ctx context.Context, what shared.RemoteTrack) ([10]shared.RemoteTrack, error)
type Album ¶
type Album struct { *Entity // contains filtered or unexported fields }
func (Album) Artists ¶
func (e Album) Artists() []shared.RemoteArtist
func (Album) TrackCount ¶
type AlbumsSearchAction ¶
type AlbumsSearchAction struct {
// contains filtered or unexported fields
}
func (AlbumsSearchAction) Search ¶
func (e AlbumsSearchAction) Search(ctx context.Context, what shared.RemoteAlbum) ([10]shared.RemoteAlbum, error)
type Artist ¶
type Artist struct { *Entity // contains filtered or unexported fields }
func (*Artist) OldestAlbumsNames ¶
type ArtistsSearchAction ¶
type ArtistsSearchAction struct {
// contains filtered or unexported fields
}
func (ArtistsSearchAction) Search ¶
func (e ArtistsSearchAction) Search(ctx context.Context, what shared.RemoteArtist) ([10]shared.RemoteArtist, error)
type Entity ¶
type Entity struct {
// contains filtered or unexported fields
}
func (Entity) RemoteName ¶
func (e Entity) RemoteName() shared.RemoteName
type LikedAlbumsActions ¶
type LikedAlbumsActions struct {
// contains filtered or unexported fields
}
func (LikedAlbumsActions) Liked ¶
func (e LikedAlbumsActions) Liked(ctx context.Context) ([]shared.RemoteEntity, error)
type LikedArtistsActions ¶
type LikedArtistsActions struct {
// contains filtered or unexported fields
}
func (LikedArtistsActions) Liked ¶
func (e LikedArtistsActions) Liked(ctx context.Context) ([]shared.RemoteEntity, error)
type LikedTracksActions ¶
type LikedTracksActions struct {
// contains filtered or unexported fields
}
func (LikedTracksActions) Liked ¶
func (e LikedTracksActions) Liked(ctx context.Context) ([]shared.RemoteEntity, error)
type Playlist ¶
type Playlist struct { *Entity // contains filtered or unexported fields }
func (Playlist) Description ¶
func (Playlist) FromAccount ¶
func (*Playlist) RemoveTracks ¶
func (Playlist) SetDescription ¶
func (*Playlist) SetIsVisible ¶
type PlaylistActions ¶
type PlaylistActions struct {
// contains filtered or unexported fields
}
func (PlaylistActions) Create ¶
func (e PlaylistActions) Create(ctx context.Context, name string, isVisible bool, description *string) (shared.RemotePlaylist, error)
func (*PlaylistActions) MyPlaylists ¶
func (e *PlaylistActions) MyPlaylists(ctx context.Context) ([]shared.RemotePlaylist, error)
func (PlaylistActions) Playlist ¶
func (e PlaylistActions) Playlist(ctx context.Context, id shared.RemoteID) (shared.RemotePlaylist, error)
type Remote ¶
type Remote struct { }
func (Remote) AssignAccountActions ¶
func (Remote) Name ¶
func (s Remote) Name() shared.RemoteName
func (Remote) Repository ¶
func (s Remote) Repository() shared.RemoteRepository
type Track ¶
type Track struct { *Entity // contains filtered or unexported fields }
func (*Track) Artists ¶
func (e *Track) Artists() []shared.RemoteArtist
type TracksSearchAction ¶
type TracksSearchAction struct {
// contains filtered or unexported fields
}
func (TracksSearchAction) Search ¶
func (e TracksSearchAction) Search(ctx context.Context, what shared.RemoteTrack) ([10]shared.RemoteTrack, error)
Click to show internal directories.
Click to hide internal directories.