mirror of
https://github.com/taglib/taglib.git
synced 2025-05-27 21:20:26 -04:00
clang: fix documentation (#1111)
* Use [[deprecated]] always Simplifies the code. Codebase is C++17 anyways. Signed-off-by: Rosen Penev <rosenp@gmail.com> * clang: fix documentation Found with Wdocumentation Signed-off-by: Rosen Penev <rosenp@gmail.com> * add deprecated to length() and fix usages Signed-off-by: Rosen Penev <rosenp@gmail.com> --------- Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
parent
d2bd56c519
commit
ecf1d4fa53
@ -26,6 +26,7 @@
|
||||
#ifndef TAGLIB_AUDIOPROPERTIES_H
|
||||
#define TAGLIB_AUDIOPROPERTIES_H
|
||||
|
||||
#include "taglib.h"
|
||||
#include "taglib_export.h"
|
||||
|
||||
#include <memory>
|
||||
@ -77,6 +78,7 @@ namespace TagLib {
|
||||
*
|
||||
* \deprecated Use lengthInSeconds().
|
||||
*/
|
||||
TAGLIB_DEPRECATED
|
||||
virtual int length() const;
|
||||
|
||||
/*!
|
||||
|
@ -15,8 +15,8 @@ namespace TagLib {
|
||||
* Used to specify which version of the ID3 standard to use when saving tags.
|
||||
*/
|
||||
enum Version {
|
||||
v3 = 3, //<! ID3v2.3
|
||||
v4 = 4 //<! ID3v2.4
|
||||
v3 = 3, //!< ID3v2.3
|
||||
v4 = 4 //!< ID3v2.4
|
||||
};
|
||||
} // namespace ID3v2
|
||||
} // namespace TagLib
|
||||
|
@ -135,8 +135,6 @@ namespace TagLib {
|
||||
*
|
||||
* \param data data of the frame (might be modified)
|
||||
* \param tagHeader the tag header
|
||||
* \param header reference to frame header pointer, will be set to
|
||||
* nullptr if the frame is invalid
|
||||
* \return {header, ok}: header is a created frame header or nullptr
|
||||
* if the frame is invalid; ok is true if the frame is supported.
|
||||
*/
|
||||
|
@ -38,15 +38,7 @@
|
||||
#define TAGLIB_CONSTRUCT_BITSET(x) static_cast<unsigned long>(x)
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201402
|
||||
#define TAGLIB_DEPRECATED [[deprecated]]
|
||||
#elif defined(__GNUC__) || defined(__clang__)
|
||||
#define TAGLIB_DEPRECATED __attribute__((deprecated))
|
||||
#elif defined(_MSC_VER)
|
||||
#define TAGLIB_DEPRECATED __declspec(deprecated)
|
||||
#else
|
||||
#define TAGLIB_DEPRECATED
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#include <sys/types.h>
|
||||
|
@ -66,8 +66,8 @@ namespace TagLib {
|
||||
* Specify which tags to strip either explicitly, or on save.
|
||||
*/
|
||||
enum StripTags {
|
||||
StripNone, //<! Don't strip any tags
|
||||
StripOthers //<! Strip all tags not explicitly referenced in method call
|
||||
StripNone, //!< Don't strip any tags
|
||||
StripOthers //!< Strip all tags not explicitly referenced in method call
|
||||
};
|
||||
|
||||
/*!
|
||||
@ -75,8 +75,8 @@ namespace TagLib {
|
||||
* types should be synchronized.
|
||||
*/
|
||||
enum DuplicateTags {
|
||||
Duplicate, //<! Synchronize values between different tag types
|
||||
DoNotDuplicate //<! Do not synchronize values between different tag types
|
||||
Duplicate, //!< Synchronize values between different tag types
|
||||
DoNotDuplicate //!< Do not synchronize values between different tag types
|
||||
};
|
||||
|
||||
/*!
|
||||
|
@ -107,7 +107,7 @@ private:
|
||||
CPPUNIT_ASSERT(nullptr != p);
|
||||
CPPUNIT_ASSERT(nullptr != t);
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL( 0, p->length());
|
||||
CPPUNIT_ASSERT_EQUAL( 0, p->lengthInSeconds());
|
||||
CPPUNIT_ASSERT_EQUAL( 0, p->bitrate());
|
||||
CPPUNIT_ASSERT_EQUAL( 0, p->sampleRate());
|
||||
CPPUNIT_ASSERT_EQUAL(64, p->channels());
|
||||
|
@ -113,7 +113,7 @@ private:
|
||||
CPPUNIT_ASSERT(nullptr != p);
|
||||
CPPUNIT_ASSERT(nullptr != t);
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->length());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->lengthInSeconds());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->bitrate());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->sampleRate());
|
||||
CPPUNIT_ASSERT_EQUAL(8, p->channels());
|
||||
|
@ -98,7 +98,7 @@ private:
|
||||
CPPUNIT_ASSERT(nullptr != p);
|
||||
CPPUNIT_ASSERT(nullptr != t);
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL( 0, p->length());
|
||||
CPPUNIT_ASSERT_EQUAL( 0, p->lengthInSeconds());
|
||||
CPPUNIT_ASSERT_EQUAL( 0, p->bitrate());
|
||||
CPPUNIT_ASSERT_EQUAL( 0, p->sampleRate());
|
||||
CPPUNIT_ASSERT_EQUAL(16, p->channels());
|
||||
|
@ -130,7 +130,7 @@ public:
|
||||
CPPUNIT_ASSERT(nullptr != p);
|
||||
CPPUNIT_ASSERT(nullptr != t);
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->length());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->lengthInSeconds());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->bitrate());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->sampleRate());
|
||||
CPPUNIT_ASSERT_EQUAL(8, p->channels());
|
||||
@ -176,7 +176,7 @@ private:
|
||||
CPPUNIT_ASSERT(nullptr != p);
|
||||
CPPUNIT_ASSERT(nullptr != t);
|
||||
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->length());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->lengthInSeconds());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->bitrate());
|
||||
CPPUNIT_ASSERT_EQUAL(0, p->sampleRate());
|
||||
CPPUNIT_ASSERT_EQUAL(8, p->channels());
|
||||
|
Loading…
Reference in New Issue
Block a user