myMPD
Internal API documentation
Loading...
Searching...
No Matches
webradio_favorites.c File Reference

myMPD webradio favorites API More...

#include "compile_time.h"
#include "src/mympd_api/webradio_favorites.h"
#include "dist/rax/rax.h"
#include "src/lib/log.h"
#include <time.h>
Include dependency graph for webradio_favorites.c:

Functions

bool mympd_api_webradio_favorite_save (struct t_webradios *webradio_favorites, struct t_webradio_data *webradio, sds old_name)
 
int mympd_api_webradio_favorite_delete (struct t_webradios *webradio_favorites, struct t_list *names)
 

Detailed Description

myMPD webradio favorites API

Function Documentation

◆ mympd_api_webradio_favorite_delete()

int mympd_api_webradio_favorite_delete ( struct t_webradios webradio_favorites,
struct t_list names 
)

Deletes webradio favorites

Parameters
webradio_favoritesWebradio favorites struct
nameswebradio ids to delete
Returns
Number of removed favorites

◆ mympd_api_webradio_favorite_save()

bool mympd_api_webradio_favorite_save ( struct t_webradios webradio_favorites,
struct t_webradio_data webradio,
sds  old_name 
)

Saves a webradio favorite. Removes the old_name and overwrites favorites with same name.

Parameters
webradio_favoritesWebradio favorites struct
webradiowebradio struct to save
old_nameold webradio name
Returns
true on success, else false