SongLoader: return instance, not pointer

This commit is contained in:
Max Kellermann
2017-02-08 10:02:08 +01:00
parent d184231169
commit f689e28958
6 changed files with 23 additions and 35 deletions

View File

@@ -67,20 +67,20 @@ public:
}
#endif
DetachedSong *LoadSong(const LocatedUri &uri) const;
DetachedSong LoadSong(const LocatedUri &uri) const;
/**
* Throws #std::runtime_error on error.
*/
gcc_nonnull_all
DetachedSong *LoadSong(const char *uri_utf8) const;
DetachedSong LoadSong(const char *uri_utf8) const;
private:
gcc_nonnull_all
DetachedSong *LoadFromDatabase(const char *uri) const;
DetachedSong LoadFromDatabase(const char *uri) const;
gcc_nonnull_all
DetachedSong *LoadFile(const char *path_utf8, Path path_fs) const;
DetachedSong LoadFile(const char *path_utf8, Path path_fs) const;
};
#endif