1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160 | /* ============================================================
*
* This file is a part of digiKam project
* https://www.digikam.org
*
* Date : 2008-12-01
* Description : a tool to export images to Smugmug web service
*
* SPDX-FileCopyrightText: 2008-2009 by Luka Renko <lure at kubuntu dot org>
* SPDX-FileCopyrightText: 2008-2024 by Gilles Caulier <caulier dot gilles at gmail dot com>
* SPDX-FileCopyrightText: 2018 by Thanh Trung Dinh <dinhthanhtrung1996 at gmail dot com>
*
* SPDX-License-Identifier: GPL-2.0-or-later
*
* ============================================================ */
#ifndef DIGIKAM_SMUG_ITEM_H
#define DIGIKAM_SMUG_ITEM_H
// Qt includes
#include <QString>
namespace DigikamGenericSmugPlugin
{
class SmugUser
{
public:
SmugUser() = default;
void clear()
{
email.clear();
nickName.clear();
displayName.clear();
accountType.clear();
userUri.clear();
nodeUri.clear();
folderUri.clear();
fileSizeLimit = 0;
}
public:
QString email;
QString nickName;
QString displayName;
QString accountType;
QString userUri;
QString nodeUri;
QString folderUri;
int fileSizeLimit = 0;
};
// ---------------------------------------------------------------------------------
class SmugAlbum
{
public:
SmugAlbum() = default;
public:
qint64 id = -1;
QString nodeID;
QString name;
QString key;
QString title;
QString description;
QString keywords;
qint64 categoryID = -1;
QString category;
qint64 subCategoryID = -1;
QString subCategory;
bool isPublic = true;
QString password;
bool canShare = true;
QString passwordHint;
int imageCount = 0;
/// below fields only used by createAlbum (and not by listAlbums)
qint64 tmplID = -1;
QString tmpl;
// cppcheck-suppress constParameterCallback
static bool lessThan(SmugAlbum& a, SmugAlbum& b)<--- Parameter 'a' can be declared as reference to const<--- Parameter 'b' can be declared as reference to const
{
return a.title.toLower() < b.title.toLower();
}
};
// ---------------------------------------------------------------------------------
class SmugPhoto
{
public:
SmugPhoto() = default;
public:
qint64 id = -1;
QString key;
QString caption;
QString keywords;
QString thumbURL;
QString originalURL;
};
// ---------------------------------------------------------------------------------
class SmugAlbumTmpl
{
public:
SmugAlbumTmpl() = default;
public:
qint64 id = -1;
QString name;
QString uri;
bool isPublic = true;
QString password;
QString passwordHint;
};
// ---------------------------------------------------------------------------------
class SmugCategory
{
public:
SmugCategory() = default;
public:
qint64 id = -1;
QString name;
};
} // namespace DigikamGenericSmugPlugin
#endif // DIGIKAM_SMUG_ITEM_H
|