TagLib API Documentation
urllinkframe.h
Go to the documentation of this file.
1/***************************************************************************
2 copyright : (C) 2002 - 2008 by Scott Wheeler
3 email : wheeler@kde.org
4
5 copyright : (C) 2006 by Urs Fleisch
6 email : ufleisch@users.sourceforge.net
7 ***************************************************************************/
8
9/***************************************************************************
10 * This library is free software; you can redistribute it and/or modify *
11 * it under the terms of the GNU Lesser General Public License version *
12 * 2.1 as published by the Free Software Foundation. *
13 * *
14 * This library is distributed in the hope that it will be useful, but *
15 * WITHOUT ANY WARRANTY; without even the implied warranty of *
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
17 * Lesser General Public License for more details. *
18 * *
19 * You should have received a copy of the GNU Lesser General Public *
20 * License along with this library; if not, write to the Free Software *
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
22 * 02110-1301 USA *
23 * *
24 * Alternatively, this file is available under the Mozilla Public *
25 * License Version 1.1. You may obtain a copy of the License at *
26 * http://www.mozilla.org/MPL/ *
27 ***************************************************************************/
28
29#ifndef TAGLIB_URLLINKFRAME_H
30#define TAGLIB_URLLINKFRAME_H
31
32#include "id3v2frame.h"
33
34namespace TagLib {
35
36 namespace ID3v2 {
37
39
43 {
44 friend class FrameFactory;
45
46 public:
51 explicit UrlLinkFrame(const ByteVector &data);
52
56 ~UrlLinkFrame() override;
57
58 UrlLinkFrame(const UrlLinkFrame &) = delete;
60
64 virtual String url() const;
65
69 virtual void setUrl(const String &s);
70
71 // Reimplementations.
72
73 void setText(const String &s) override;
74 String toString() const override;
75 PropertyMap asProperties() const override;
76
77 protected:
78 void parseFields(const ByteVector &data) override;
79 ByteVector renderFields() const override;
80
84 UrlLinkFrame(const ByteVector &data, Header *h);
85
86 private:
87 class UrlLinkFramePrivate;
89 std::unique_ptr<UrlLinkFramePrivate> d;
90 };
91
93
102 {
103 friend class FrameFactory;
104
105 public:
111
116 explicit UserUrlLinkFrame(const ByteVector &data);
117
122
125
126 // Reimplementations.
127
128 String toString() const override;
129
139
148
153
157 void setDescription(const String &s);
158
167 PropertyMap asProperties() const override;
168
173 static UserUrlLinkFrame *find(const Tag *tag, const String &description);
174
175 protected:
176 void parseFields(const ByteVector &data) override;
177 ByteVector renderFields() const override;
178
183
184 private:
185 class UserUrlLinkFramePrivate;
187 std::unique_ptr<UserUrlLinkFramePrivate> d;
188 };
189
190 } // namespace ID3v2
191} // namespace TagLib
192#endif
A byte vector.
Definition: tbytevector.h:46
A factory for creating ID3v2 frames during parsing.
Definition: id3v2framefactory.h:68
ID3v2 frame implementation.
Definition: id3v2frame.h:57
An implementation of ID3v2 headers.
Definition: id3v2header.h:49
The main class in the ID3v2 implementation.
Definition: id3v2tag.h:134
ID3v2 URL frame.
Definition: urllinkframe.h:43
void setText(const String &s) override
void parseFields(const ByteVector &data) override
String toString() const override
UrlLinkFrame(const UrlLinkFrame &)=delete
UrlLinkFrame & operator=(const UrlLinkFrame &)=delete
UrlLinkFrame(const ByteVector &data, Header *h)
PropertyMap asProperties() const override
ByteVector renderFields() const override
virtual void setUrl(const String &s)
virtual String url() const
UrlLinkFrame(const ByteVector &data)
ID3v2 User defined URL frame.
Definition: urllinkframe.h:102
UserUrlLinkFrame(const UserUrlLinkFrame &)=delete
String::Type textEncoding() const
UserUrlLinkFrame(const ByteVector &data, Header *h)
void setTextEncoding(String::Type encoding)
static UserUrlLinkFrame * find(const Tag *tag, const String &description)
ByteVector renderFields() const override
UserUrlLinkFrame(String::Type encoding=String::Latin1)
void setDescription(const String &s)
UserUrlLinkFrame & operator=(const UserUrlLinkFrame &)=delete
String toString() const override
PropertyMap asProperties() const override
void parseFields(const ByteVector &data) override
UserUrlLinkFrame(const ByteVector &data)
A map for format-independent <key,values> tag representations.
Definition: tpropertymap.h:123
A wide string class suitable for unicode.
Definition: tstring.h:83
Type
Definition: tstring.h:96
@ Latin1
Definition: tstring.h:100
A namespace for all TagLib related classes and functions.
Definition: apefile.h:41
#define TAGLIB_EXPORT
Definition: taglib_export.h:40
#define TAGLIB_MSVC_SUPPRESS_WARNING_NEEDS_TO_HAVE_DLL_INTERFACE
Definition: taglib_export.h:55