MCPcopy Create free account
hub / github.com/MusicPlayerDaemon/MPD / LoadFromArchive

Method LoadFromArchive

src/SongUpdate.cxx:95–107  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

93#ifdef ENABLE_ARCHIVE
94
95SongPtr
96Song::LoadFromArchive(ArchiveFile &archive, std::string_view name_utf8,
97 Directory &parent) noexcept
98{
99 assert(!uri_has_scheme(name_utf8));
100 assert(VerifyRelativePathUTF8(name_utf8));
101
102 auto song = std::make_unique<Song>(name_utf8, parent);
103 if (!song->UpdateFileInArchive(archive))
104 return nullptr;
105
106 return song;
107}
108
109bool
110Song::UpdateFileInArchive(ArchiveFile &archive) noexcept

Callers

nothing calls this directly

Calls 3

uri_has_schemeFunction · 0.85
VerifyRelativePathUTF8Function · 0.85
UpdateFileInArchiveMethod · 0.80

Tested by

no test coverage detected