TagLib 1.9.1 (apeitem.h Source File)
Home
Class Hierarchy
Namespaces
Classes
Headers
Namespace Members
Class Members
File Members
taglib
ape
apeitem.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_APEITEM_H
27
#define TAGLIB_APEITEM_H
28
29
#include "
tbytevector.h
"
30
#include "
tstring.h
"
31
#include "
tstringlist.h
"
32
33
namespace
TagLib {
34
35
namespace
APE {
36
38
42
class
TAGLIB_EXPORT
Item
43
{
44
public
:
48
enum
ItemTypes
{
50
Text = 0,
52
Binary = 1,
54
Locator = 2
55
};
59
Item
();
60
64
// BIC: Remove this, StringList has a constructor from a single string
65
Item
(
const
String
&key,
const
String
&value);
66
70
Item
(
const
String
&key,
const
StringList
&values);
71
76
Item
(
const
String
&key,
const
ByteVector
&value,
bool
binary);
77
81
Item
(
const
Item
&item);
82
86
virtual
~
Item
();
87
91
Item
&operator=(
const
Item
&item);
92
96
String
key()
const
;
97
102
ByteVector
binaryData()
const
;
103
108
void
setBinaryData(
const
ByteVector
&value);
109
110
#ifndef DO_NOT_DOCUMENT
111
/* Remove in next binary incompatible release */
112
ByteVector
value()
const
;
113
#endif
114
118
void
setKey(
const
String
&key);
119
125
void
setValue(
const
String
&value);
126
133
void
setValues(
const
StringList
&values);
134
140
void
appendValue(
const
String
&value);
141
147
void
appendValues(
const
StringList
&values);
148
152
int
size()
const
;
153
159
String
toString()
const
;
160
161
#ifndef DO_NOT_DOCUMENT
162
/* Remove in next binary incompatible release */
163
StringList
toStringList()
const
;
164
#endif
165
170
StringList
values()
const
;
171
175
ByteVector
render()
const
;
176
180
void
parse(
const
ByteVector
& data);
181
185
void
setReadOnly(
bool
readOnly);
186
190
bool
isReadOnly()
const
;
191
197
void
setType(ItemTypes type);
198
202
ItemTypes type()
const
;
203
207
bool
isEmpty()
const
;
208
209
private
:
210
class
ItemPrivate;
211
ItemPrivate *d;
212
};
213
}
214
215
}
216
217
#endif
218
219