Documentation ¶
Index ¶
- func FlushDB()
- func InitRedisClient(flashDB bool)
- type CookiesDB
- type CookiesDBClient
- type SpotifyDB
- func (sDB SpotifyDB) DeleteFavTracksSnapshot(username string, timestamp string) (*models.FavTracksSnapshot, error)
- func (sDB SpotifyDB) DeletePlaylistsSnapshot(username string, timestamp string) (*models.PlaylistsSnapshot, error)
- func (sDB SpotifyDB) GetAllFavTracksSnapshots(username string) []models.FavTracksSnapshot
- func (sDB SpotifyDB) GetAllPlaylistsSnapshots(username string) []models.PlaylistsSnapshot
- func (sDB SpotifyDB) GetFavTracksSnapshot(key string) *models.FavTracksSnapshot
- func (sDB SpotifyDB) GetFavTracksSnapshotByTimestamp(username string, timestamp string) (*models.FavTracksSnapshot, error)
- func (sDB SpotifyDB) GetPlaylistsSnapshot(key string) *models.PlaylistsSnapshot
- func (sDB SpotifyDB) GetPlaylistsSnapshotByTimestamp(username string, timestamp string) (*models.PlaylistsSnapshot, error)
- func (sDB SpotifyDB) SaveFavTracksSnapshot(ft *models.FavTracksSnapshot) (saved bool)
- func (sDB SpotifyDB) SavePlaylistsSnapshot(ps *models.PlaylistsSnapshot) (saved bool)
- type SpotifyDBClient
- type UsersDBClient
- type UsersDBRedisClient
- type UsersDBTestClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitRedisClient ¶
func InitRedisClient(flashDB bool)
Types ¶
type CookiesDB ¶
type CookiesDB struct{}
func (CookiesDB) GetCookiesInfo ¶
func (CookiesDB) SaveCookiesInfo ¶
type CookiesDBClient ¶
type CookiesDBClient interface { SaveCookiesInfo(cookieID2usernameMap map[string]string) GetCookiesInfo() (cookieID2usernameMap map[string]string) }
func GetCookiesDBClient ¶
func GetCookiesDBClient() CookiesDBClient
type SpotifyDB ¶
type SpotifyDB struct{}
func (SpotifyDB) DeleteFavTracksSnapshot ¶
func (SpotifyDB) DeletePlaylistsSnapshot ¶
func (SpotifyDB) GetAllFavTracksSnapshots ¶
func (sDB SpotifyDB) GetAllFavTracksSnapshots(username string) []models.FavTracksSnapshot
func (SpotifyDB) GetAllPlaylistsSnapshots ¶
func (sDB SpotifyDB) GetAllPlaylistsSnapshots(username string) []models.PlaylistsSnapshot
func (SpotifyDB) GetFavTracksSnapshot ¶
func (sDB SpotifyDB) GetFavTracksSnapshot(key string) *models.FavTracksSnapshot
func (SpotifyDB) GetFavTracksSnapshotByTimestamp ¶
func (SpotifyDB) GetPlaylistsSnapshot ¶
func (sDB SpotifyDB) GetPlaylistsSnapshot(key string) *models.PlaylistsSnapshot
func (SpotifyDB) GetPlaylistsSnapshotByTimestamp ¶
func (SpotifyDB) SaveFavTracksSnapshot ¶
func (sDB SpotifyDB) SaveFavTracksSnapshot(ft *models.FavTracksSnapshot) (saved bool)
func (SpotifyDB) SavePlaylistsSnapshot ¶
func (sDB SpotifyDB) SavePlaylistsSnapshot(ps *models.PlaylistsSnapshot) (saved bool)
type SpotifyDBClient ¶
type SpotifyDBClient interface { SaveFavTracksSnapshot(ft *models.FavTracksSnapshot) (saved bool) SavePlaylistsSnapshot(ps *models.PlaylistsSnapshot) (saved bool) DeletePlaylistsSnapshot(username string, timestamp string) (*models.PlaylistsSnapshot, error) DeleteFavTracksSnapshot(username string, timestamp string) (*models.FavTracksSnapshot, error) GetPlaylistsSnapshotByTimestamp(username string, timestamp string) (*models.PlaylistsSnapshot, error) GetFavTracksSnapshotByTimestamp(username string, timestamp string) (*models.FavTracksSnapshot, error) GetPlaylistsSnapshot(key string) *models.PlaylistsSnapshot GetFavTracksSnapshot(key string) *models.FavTracksSnapshot GetAllFavTracksSnapshots(username string) []models.FavTracksSnapshot GetAllPlaylistsSnapshots(username string) []models.PlaylistsSnapshot }
func GetSpotifyDBClient ¶
func GetSpotifyDBClient() SpotifyDBClient
type UsersDBClient ¶
type UsersDBClient interface { SaveUser(user *models.User) (stored bool) GetUser(username string) *models.User GetAllUsers() []models.User }
func GetUsersDBClient ¶
func GetUsersDBClient() UsersDBClient
type UsersDBRedisClient ¶
type UsersDBRedisClient struct{}
func (*UsersDBRedisClient) GetAllUsers ¶
func (uDB *UsersDBRedisClient) GetAllUsers() []models.User
type UsersDBTestClient ¶
type UsersDBTestClient struct {
// contains filtered or unexported fields
}
func NewUsersDBTest ¶
func NewUsersDBTest(testUsers []models.User) *UsersDBTestClient
func (*UsersDBTestClient) GetAllUsers ¶
func (c *UsersDBTestClient) GetAllUsers() []models.User
Click to show internal directories.
Click to hide internal directories.