TagLib API Documentation
oggflacfile.h
Go to the documentation of this file.
1/***************************************************************************
2 copyright : (C) 2004 by Allan Sandfeld Jensen
3 email : kde@carewolf.org
4 ***************************************************************************/
5
6/***************************************************************************
7 * This library is free software; you can redistribute it and/or modify *
8 * it under the terms of the GNU Lesser General Public License version *
9 * 2.1 as published by the Free Software Foundation. *
10 * *
11 * This library is distributed in the hope that it will be useful, but *
12 * WITHOUT ANY WARRANTY; without even the implied warranty of *
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
14 * Lesser General Public License for more details. *
15 * *
16 * You should have received a copy of the GNU Lesser General Public *
17 * License along with this library; if not, write to the Free Software *
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
19 * 02110-1301 USA *
20 * *
21 * Alternatively, this file is available under the Mozilla Public *
22 * License Version 1.1. You may obtain a copy of the License at *
23 * http://www.mozilla.org/MPL/ *
24 ***************************************************************************/
25
26#ifndef TAGLIB_OGGFLACFILE_H
27#define TAGLIB_OGGFLACFILE_H
28
29#include "taglib_export.h"
30#include "oggfile.h"
31#include "xiphcomment.h"
32#include "flacproperties.h"
33
34namespace TagLib {
35
36 class Tag;
37
38 namespace Ogg {
39
41
49 namespace FLAC {
50
52
54
63 {
64 public:
71 File(FileName file, bool readProperties = true,
73
83 File(IOStream *stream, bool readProperties = true,
85
89 ~File() override;
90
91 File(const File &) = delete;
92 File &operator=(const File &) = delete;
93
107 XiphComment *tag() const override;
108
113 Properties *audioProperties() const override;
114
115
120 PropertyMap properties() const override;
121
127
128
133 bool save() override;
134
140
146 bool hasXiphComment() const;
147
154 static bool isSupported(IOStream *stream);
155
156 private:
157 void read(bool readProperties, Properties::ReadStyle propertiesStyle);
158 void scan();
159 ByteVector streamInfoData();
160 ByteVector xiphCommentData();
161
162 class FilePrivate;
164 std::unique_ptr<FilePrivate> d;
165 };
166 } // namespace FLAC
167 } // namespace Ogg
168} // namespace TagLib
169
170#endif
ReadStyle
Definition: audioproperties.h:56
@ Average
Read more of the file and make better values guesses.
Definition: audioproperties.h:60
A byte vector.
Definition: tbytevector.h:46
An implementation of audio property reading for FLAC.
Definition: flacproperties.h:45
An abstract class that provides operations on a sequence of bytes.
Definition: tiostream.h:65
An implementation of TagLib::File with Ogg/FLAC specific methods.
Definition: oggflacfile.h:63
bool hasXiphComment() const
File(const File &)=delete
File & operator=(const File &)=delete
bool save() override
PropertyMap setProperties(const PropertyMap &) override
XiphComment * tag() const override
Properties * audioProperties() const override
PropertyMap properties() const override
File(FileName file, bool readProperties=true, Properties::ReadStyle propertiesStyle=Properties::Average)
File(IOStream *stream, bool readProperties=true, Properties::ReadStyle propertiesStyle=Properties::Average)
static bool isSupported(IOStream *stream)
An implementation of TagLib::File with some helpers for Ogg based formats.
Definition: oggfile.h:51
Ogg Vorbis comment implementation.
Definition: xiphcomment.h:71
A map for format-independent <key,values> tag representations.
Definition: tpropertymap.h:123
A namespace for all TagLib related classes and functions.
Definition: apefile.h:41
off_t offset_t
Definition: taglib.h:64
const char * FileName
Definition: tiostream.h:59
#define TAGLIB_EXPORT
Definition: taglib_export.h:40
#define TAGLIB_MSVC_SUPPRESS_WARNING_NEEDS_TO_HAVE_DLL_INTERFACE
Definition: taglib_export.h:55