From 6a5b4eb4a0dc1e99e08a65f28fdcfc282c5eab56 Mon Sep 17 00:00:00 2001 From: Martchus Date: Tue, 27 Dec 2016 23:40:36 +0100 Subject: [PATCH] Improve documentation --- fieldbasedtag.h | 3 +++ ogg/oggiterator.cpp | 6 +++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/fieldbasedtag.h b/fieldbasedtag.h index 8c1b814..f5d4ef2 100644 --- a/fieldbasedtag.h +++ b/fieldbasedtag.h @@ -142,6 +142,8 @@ bool FieldMapBasedTag::setValue(const typename FieldType::id /*! * \brief Assigns the given \a values to the field with the specified \a id. + * \remarks There might me more then one value assigned to an \a id. Whereas setValue() only alters the first value, this + * method will replace all currently assigned values with the specified \a values. * \sa Tag::setValues() */ template @@ -168,6 +170,7 @@ bool FieldMapBasedTag::setValues(const typename FieldType::i * \brief Assigns the given \a values to the field with the specified \a id. * \remarks There might me more then one value assigned to a \a field. Whereas setValue() only alters the first value, this * method will replace all currently assigned values with the specified \a values. + * \sa Tag::setValues() */ template bool FieldMapBasedTag::setValues(KnownField field, const std::vector &values) diff --git a/ogg/oggiterator.cpp b/ogg/oggiterator.cpp index 12bbfc2..1bf16f6 100644 --- a/ogg/oggiterator.cpp +++ b/ogg/oggiterator.cpp @@ -37,7 +37,7 @@ void OggIterator::clear(istream &stream, uint64 startOffset, uint64 streamSize) * \brief Resets the iterator to point at the first segment of the first page (matching the filter if set). * * Fetched pages (directly accessable through the page() method) remain after resetting the iterator. Use - * the clear method to clear all pages. + * clear() to clear all pages. */ void OggIterator::reset() { @@ -131,7 +131,7 @@ void OggIterator::read(char *buffer, size_t count) { size_t bytesRead = 0; while(*this && count) { - uint32 available = currentSegmentSize() - m_bytesRead; + const uint32 available = currentSegmentSize() - m_bytesRead; stream().seekg(currentCharacterOffset()); if(count <= available) { stream().read(buffer + bytesRead, count); @@ -164,7 +164,7 @@ size_t OggIterator::readAll(char *buffer, size_t max) { size_t bytesRead = 0; while(*this && max) { - uint32 available = currentSegmentSize() - m_bytesRead; + const uint32 available = currentSegmentSize() - m_bytesRead; stream().seekg(currentCharacterOffset()); if(max <= available) { stream().read(buffer + bytesRead, max);