18 std::vector<unsigned char>
bytes;
66 std::string_view cacheKey,
67 std::string *errorMessage =
nullptr,
SaveCoverArtResult save_cover_art(std::string_view cacheKey, const std::vector< unsigned char > &bytes, const std::string &cacheRoot)
Save cover art bytes for a given cache key.
Definition cover_art_cache.cpp:122
std::string build_cover_art_cache_key(std::string_view hostUuid, std::string_view hostAddress, int appId)
Build a stable cache key for one host app's cover art.
Definition cover_art_cache.cpp:75
bool delete_cover_art(std::string_view cacheKey, std::string *errorMessage, const std::string &cacheRoot)
Delete cached cover art for a given key.
Definition cover_art_cache.cpp:90
std::string default_cover_art_cache_root()
Return the default root directory for cached cover art.
Definition cover_art_cache.cpp:71
bool cover_art_exists(std::string_view cacheKey, const std::string &cacheRoot)
Return whether cached cover art exists for a given key.
Definition cover_art_cache.cpp:80
LoadCoverArtResult load_cover_art(std::string_view cacheKey, const std::string &cacheRoot)
Load cached cover art bytes for a given key.
Definition cover_art_cache.cpp:103
Result of loading cached cover art bytes from disk.
Definition cover_art_cache.h:17
std::vector< unsigned char > bytes
Loaded cover art bytes.
Definition cover_art_cache.h:18
std::string errorMessage
Error detail when loading failed.
Definition cover_art_cache.h:20
bool fileFound
True when a cached file existed on disk.
Definition cover_art_cache.h:19
Result of saving cached cover art bytes to disk.
Definition cover_art_cache.h:26
bool success
True when the cover art was saved successfully.
Definition cover_art_cache.h:27
std::string errorMessage
Error detail when saving failed.
Definition cover_art_cache.h:28