xingheader.h
Go to the documentation of this file.
/***************************************************************************
copyright : (C) 2003 by Ismael Orenstein
email : orenstein@kde.org
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library is distributed in the hope that it will be useful, but *
* WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_XINGHEADER_H
#define TAGLIB_XINGHEADER_H
#include <memory>
#include "taglib_export.h"
#include "mpegheader.h"
namespace TagLib {
class ByteVector;
namespace MPEG {
class TAGLIB_EXPORT XingHeader
{
public:
enum HeaderType
{
Invalid = 0,
Xing = 1,
VBRI = 2,
};
XingHeader(const ByteVector &data);
~XingHeader();
XingHeader(const XingHeader &) = delete;
XingHeader &operator=(const XingHeader &) = delete;
bool isValid() const;
unsigned int totalFrames() const;
unsigned int totalSize() const;
HeaderType type() const;
private:
void parse(const ByteVector &data);
class XingHeaderPrivate;
TAGLIB_MSVC_SUPPRESS_WARNING_NEEDS_TO_HAVE_DLL_INTERFACE
std::unique_ptr<XingHeaderPrivate> d;
};
} // namespace MPEG
} // namespace TagLib
#endif
TagLib::ByteVector
A byte vector.
Definition tbytevector.h:46
TagLib::MPEG::XingHeader::XingHeader
XingHeader(const XingHeader &)=delete
TagLib::MPEG::XingHeader::isValid
bool isValid() const
TagLib::MPEG::XingHeader::XingHeader
XingHeader(const ByteVector &data)
TagLib::MPEG::XingHeader::~XingHeader
~XingHeader()
TagLib::MPEG::XingHeader::totalFrames
unsigned int totalFrames() const
TagLib::MPEG::XingHeader::operator=
XingHeader & operator=(const XingHeader &)=delete
TagLib::MPEG::XingHeader::type
HeaderType type() const
TagLib::MPEG::XingHeader::totalSize
unsigned int totalSize() const
TagLib::MPEG::XingHeader::HeaderType
HeaderType
Definition xingheader.h:59
TagLib::MPEG::XingHeader::VBRI
@ VBRI
Definition xingheader.h:73
TagLib::MPEG::XingHeader::Xing
@ Xing
Definition xingheader.h:68
TagLib::MPEG::XingHeader::Invalid
@ Invalid
Definition xingheader.h:63
mpegheader.h
TagLib::MPEG
An implementation of TagLib::File with MPEG (MP3) specific methods.
Definition mpegfile.h:43
TagLib
A namespace for all TagLib related classes and functions.
Definition apefile.h:41
taglib_export.h
TAGLIB_EXPORT
#define TAGLIB_EXPORT
Definition taglib_export.h:40
TAGLIB_MSVC_SUPPRESS_WARNING_NEEDS_TO_HAVE_DLL_INTERFACE
#define TAGLIB_MSVC_SUPPRESS_WARNING_NEEDS_TO_HAVE_DLL_INTERFACE
Definition taglib_export.h:55