| TagLib 1.13 |  |

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
34 namespace TagLib {
35
36 namespace ID3v2 {
37
39
42 class TAGLIB_EXPORT UrlLinkFrame : public Frame
43 {
44 friend class FrameFactory;
45
46 public:
51 explicit UrlLinkFrame(const ByteVector &data);
52
56 virtual ~UrlLinkFrame();
57
61 virtual String url() const;
62
66 virtual void setUrl(const String &s);
67
68 // Reimplementations.
69
70 virtual void setText(const String &s);
71 virtual String toString() const;
72 PropertyMap asProperties() const;
73
74 protected:
75 virtual void parseFields(const ByteVector &data);
76 virtual ByteVector renderFields() const;
77
81 UrlLinkFrame(const ByteVector &data, Header *h);
82
83 private:
84 UrlLinkFrame(const UrlLinkFrame &);
85 UrlLinkFrame &operator=(const UrlLinkFrame &);
86
87 class UrlLinkFramePrivate;
88 UrlLinkFramePrivate *d;
89 };
90
92
100 class TAGLIB_EXPORT UserUrlLinkFrame : public UrlLinkFrame
101 {
102 friend class FrameFactory;
103
104 public:
109 explicit UserUrlLinkFrame(String::Type encoding = String::Latin1);
110
115 explicit UserUrlLinkFrame(const ByteVector &data);
116
120 virtual ~UserUrlLinkFrame();
121
122 // Reimplementations.
123
124 virtual String toString() const;
125
134 String::Type textEncoding() const;
135
143 void setTextEncoding(String::Type encoding);
144
148 String description() const;
149
153 void setDescription(const String &s);
154
163 PropertyMap asProperties() const;
164
169 static UserUrlLinkFrame *find(Tag *tag, const String &description);
170
171 protected:
172 virtual void parseFields(const ByteVector &data);
173 virtual ByteVector renderFields() const;
174
178 UserUrlLinkFrame(const ByteVector &data, Header *h);
179
180 private:
181 UserUrlLinkFrame(const UserUrlLinkFrame &);
182 UserUrlLinkFrame &operator=(const UserUrlLinkFrame &);
183
184 class UserUrlLinkFramePrivate;
185 UserUrlLinkFramePrivate *d;
186 };
187
188 }
189}
190#endif
TagLib::ByteVector
A byte vector.
Definition: tbytevector.h:46
TagLib::ID3v2::FrameFactory
A factory for creating ID3v2 frames during parsing.
Definition: id3v2framefactory.h:66
TagLib::ID3v2::Frame
ID3v2 frame implementation.
Definition: id3v2frame.h:55
TagLib::ID3v2::Header
An implementation of ID3v2 headers.
Definition: id3v2header.h:49
TagLib::ID3v2::Tag
The main class in the ID3v2 implementation.
Definition: id3v2tag.h:128
TagLib::ID3v2::UrlLinkFrame
ID3v2 URL frame.
Definition: urllinkframe.h:43
TagLib::ID3v2::UrlLinkFrame::renderFields
virtual ByteVector renderFields() const
TagLib::ID3v2::UrlLinkFrame::~UrlLinkFrame
virtual ~UrlLinkFrame()
TagLib::ID3v2::UrlLinkFrame::toString
virtual String toString() const
TagLib::ID3v2::UrlLinkFrame::setText
virtual void setText(const String &s)
TagLib::ID3v2::UrlLinkFrame::UrlLinkFrame
UrlLinkFrame(const ByteVector &data, Header *h)
TagLib::ID3v2::UrlLinkFrame::setUrl
virtual void setUrl(const String &s)
TagLib::ID3v2::UrlLinkFrame::url
virtual String url() const
TagLib::ID3v2::UrlLinkFrame::parseFields
virtual void parseFields(const ByteVector &data)
TagLib::ID3v2::UrlLinkFrame::asProperties
PropertyMap asProperties() const
TagLib::ID3v2::UrlLinkFrame::UrlLinkFrame
UrlLinkFrame(const ByteVector &data)
TagLib::ID3v2::UserUrlLinkFrame
ID3v2 User defined URL frame.
Definition: urllinkframe.h:101
TagLib::ID3v2::UserUrlLinkFrame::textEncoding
String::Type textEncoding() const
TagLib::ID3v2::UserUrlLinkFrame::toString
virtual String toString() const
TagLib::ID3v2::UserUrlLinkFrame::renderFields
virtual ByteVector renderFields() const
TagLib::ID3v2::UserUrlLinkFrame::UserUrlLinkFrame
UserUrlLinkFrame(const ByteVector &data, Header *h)
TagLib::ID3v2::UserUrlLinkFrame::setTextEncoding
void setTextEncoding(String::Type encoding)
TagLib::ID3v2::UserUrlLinkFrame::asProperties
PropertyMap asProperties() const
TagLib::ID3v2::UserUrlLinkFrame::parseFields
virtual void parseFields(const ByteVector &data)
TagLib::ID3v2::UserUrlLinkFrame::UserUrlLinkFrame
UserUrlLinkFrame(String::Type encoding=String::Latin1)
TagLib::ID3v2::UserUrlLinkFrame::setDescription
void setDescription(const String &s)
TagLib::ID3v2::UserUrlLinkFrame::~UserUrlLinkFrame
virtual ~UserUrlLinkFrame()
TagLib::ID3v2::UserUrlLinkFrame::find
static UserUrlLinkFrame * find(Tag *tag, const String &description)
TagLib::ID3v2::UserUrlLinkFrame::UserUrlLinkFrame
UserUrlLinkFrame(const ByteVector &data)
TagLib::ID3v2::UserUrlLinkFrame::description
String description() const
TagLib::PropertyMap
A map for format-independent <key,valuelist> tag representations.
Definition: tpropertymap.h:119
TagLib::String
A wide string class suitable for unicode.
Definition: tstring.h:85
TagLib::String::Type
Type
Definition: tstring.h:97
TagLib::String::Latin1
@ Latin1
Definition: tstring.h:101
id3v2frame.h
TagLib
A namespace for all TagLib related classes and functions.
Definition: apefile.h:41
TAGLIB_EXPORT
#define TAGLIB_EXPORT
Definition: taglib_export.h:40