lib/xiph/FlacMetadataChain: un-inline Read(InputStream)

This commit is contained in:
Max Kellermann 2018-07-07 14:22:22 +02:00
parent 37897d1550
commit 2e116c9e28
3 changed files with 17 additions and 7 deletions

View File

@ -24,6 +24,7 @@
#include "FlacCommon.hxx"
#include "lib/xiph/FlacMetadataChain.hxx"
#include "OggCodec.hxx"
#include "input/InputStream.hxx"
#include "fs/Path.hxx"
#include "fs/NarrowPath.hxx"
#include "Log.hxx"

View File

@ -20,8 +20,21 @@
#include "config.h"
#include "FlacMetadataChain.hxx"
#include "FlacMetadataIterator.hxx"
#include "FlacIOHandle.hxx"
#include "decoder/plugins/FlacMetadata.hxx"
bool
FlacMetadataChain::Read(InputStream &is) noexcept
{
return Read(::ToFlacIOHandle(is), ::GetFlacIOCallbacks(is));
}
bool
FlacMetadataChain::ReadOgg(InputStream &is) noexcept
{
return ReadOgg(::ToFlacIOHandle(is), ::GetFlacIOCallbacks(is));
}
void
FlacMetadataChain::Scan(TagHandler &handler) noexcept
{

View File

@ -20,11 +20,11 @@
#ifndef MPD_FLAC_METADATA_CHAIN_HXX
#define MPD_FLAC_METADATA_CHAIN_HXX
#include "FlacIOHandle.hxx"
#include "Compiler.h"
#include <FLAC/metadata.h>
class InputStream;
class TagHandler;
class FlacMetadataChain {
@ -52,9 +52,7 @@ public:
callbacks);
}
bool Read(InputStream &is) noexcept {
return Read(::ToFlacIOHandle(is), ::GetFlacIOCallbacks(is));
}
bool Read(InputStream &is) noexcept;
bool ReadOgg(const char *path) noexcept {
return ::FLAC__metadata_chain_read_ogg(chain, path);
@ -67,9 +65,7 @@ public:
callbacks);
}
bool ReadOgg(InputStream &is) {
return ReadOgg(::ToFlacIOHandle(is), ::GetFlacIOCallbacks(is));
}
bool ReadOgg(InputStream &is) noexcept;
gcc_pure
FLAC__Metadata_ChainStatus GetStatus() const noexcept {