Sayonara Player
Loading...
Searching...
No Matches
src
Components
Library
Importer
ImportCache.h
1
/* ImportCache.h */
2
3
/* Copyright (C) 2011-2024 Michael Lugmair (Lucio Carreras)
4
*
5
* This file is part of sayonara player
6
*
7
* This program is free software: you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation, either version 3 of the License, or
10
* (at your option) any later version.
11
12
* This program is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
17
* You should have received a copy of the GNU General Public License
18
* along with this program. If not, see <http://www.gnu.org/licenses/>.
19
*/
20
21
#ifndef IMPORTCACHE_H
22
#define IMPORTCACHE_H
23
24
#include "Utils/Pimpl.h"
25
26
#include <QList>
27
#include <QPair>
28
29
class
MetaData
;
30
class
MetaDataList
;
31
32
namespace
Tagging
33
{
34
class
TagReader;
35
}
36
37
namespace
Library
38
{
39
class
ImportCache
40
{
41
PIMPL(
ImportCache
)
42
43
public
:
44
ImportCache
(
const
QString& libraryPath,
const
std::shared_ptr<Tagging::TagReader>& tagReader);
45
virtual
~ImportCache
();
46
47
ImportCache
(
const
ImportCache
& other);
48
ImportCache
& operator=(
const
ImportCache
& other);
49
50
void
clear();
51
52
void
addFile(
const
QString& filename,
const
QString& parentDirectory);
53
54
[[nodiscard]] QStringList files()
const
;
55
[[nodiscard]]
MetaDataList
soundfiles()
const
;
56
[[nodiscard]]
int
count()
const
;
57
[[nodiscard]]
int
soundFileCount()
const
;
58
59
[[nodiscard]] QString targetFilename(
const
QString& srcFilename,
const
QString& targetDirectory)
const
;
60
[[nodiscard]]
MetaData
metadata(
const
QString& filename)
const
;
61
void
changeMetadata(
const
QList
<
QPair<MetaData, MetaData>
>& changedTracks);
62
63
private
:
64
void
addSoundfile(
const
QString& filename);
65
};
66
67
using
ImportCachePtr = std::shared_ptr<ImportCache>;
68
}
69
70
#endif
// IMPORTCACHE_H
Library::ImportCache
Definition
ImportCache.h:40
MetaDataList
Definition
MetaDataList.h:34
MetaData
Definition
MetaData.h:43
QList
Definition
EngineUtils.h:33
Tagging
The GUI_TagEdit class.
Definition
Engine.h:33
QPair
Definition
typedefs.h:33
Generated on Sat Jul 20 2024 00:00:00 for Sayonara Player by
1.12.0