Attica

downloaddescription.cpp
1/*
2 This file is part of KDE.
3
4 SPDX-FileCopyrightText: 2009 Frederik Gladhorn <gladhorn@kde.org>
5
6 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
7*/
8
9#include "downloaddescription.h"
10
11#include <QStringList>
12
13namespace Attica
14{
15class Q_DECL_HIDDEN DownloadDescription::Private : public QSharedData
16{
17public:
18 int id = 0;
19 Attica::DownloadDescription::Type type = Attica::DownloadDescription::FileDownload;
20 bool hasPrice = false;
24 QString distributionType;
25 QString priceReason;
26 QString priceAmount;
27 QString gpgFingerprint;
28 QString gpgSignature;
29 QString packageName;
30 QString repository;
31 uint size = 0;
32 QStringList tags;
33};
34}
35
36using namespace Attica;
37
38DownloadDescription::DownloadDescription()
39 : d(new Private)
40{
41}
42
43DownloadDescription::DownloadDescription(const Attica::DownloadDescription &other)
44 : d(other.d)
45{
46}
47
48DownloadDescription &DownloadDescription::operator=(const Attica::DownloadDescription &other)
49{
50 d = other.d;
51 return *this;
52}
53
54DownloadDescription::~DownloadDescription()
55{
56}
57
58QString Attica::DownloadDescription::category() const
59{
60 return d->category;
61}
62
64{
65 return d->id;
66}
67
68void DownloadDescription::setId(int id)
69{
70 d->id = id;
71}
72
73void DownloadDescription::setCategory(const QString &category)
74{
75 d->category = category;
76}
77
78QString Attica::DownloadDescription::distributionType() const
79{
80 return d->distributionType;
81}
82
83void DownloadDescription::setDistributionType(const QString &distributionType)
84{
85 d->distributionType = distributionType;
86}
87
88bool Attica::DownloadDescription::hasPrice() const
89{
90 return d->hasPrice;
91}
92
93void DownloadDescription::setHasPrice(bool hasPrice)
94{
95 d->hasPrice = hasPrice;
96}
97
98Attica::DownloadDescription::Type DownloadDescription::type() const
99{
100 return d->type;
101}
102
103void DownloadDescription::setType(Attica::DownloadDescription::Type type)
104{
105 d->type = type;
106}
107
108QString Attica::DownloadDescription::link() const
109{
110 return d->link;
111}
112
113void DownloadDescription::setLink(const QString &link)
114{
115 d->link = link;
116}
117
118QString Attica::DownloadDescription::name() const
119{
120 return d->name;
121}
122
123void DownloadDescription::setName(const QString &name)
124{
125 d->name = name;
126}
127
128QString Attica::DownloadDescription::priceAmount() const
129{
130 return d->priceAmount;
131}
132
133void DownloadDescription::setPriceAmount(const QString &priceAmount)
134{
135 d->priceAmount = priceAmount;
136}
137
138QString Attica::DownloadDescription::priceReason() const
139{
140 return d->priceReason;
141}
142
143void Attica::DownloadDescription::setPriceReason(const QString &priceReason)
144{
145 d->priceReason = priceReason;
146}
147
148uint Attica::DownloadDescription::size() const
149{
150 return d->size;
151}
152
153void Attica::DownloadDescription::setSize(uint size)
154{
155 d->size = size;
156}
157
158QString Attica::DownloadDescription::gpgFingerprint() const
159{
160 return d->gpgFingerprint;
161}
162
163void Attica::DownloadDescription::setGpgFingerprint(const QString &fingerprint)
164{
165 d->gpgFingerprint = fingerprint;
166}
167
168QString Attica::DownloadDescription::gpgSignature() const
169{
170 return d->gpgSignature;
171}
172
173void Attica::DownloadDescription::setGpgSignature(const QString &signature)
174{
175 d->gpgSignature = signature;
176}
177
178QString Attica::DownloadDescription::packageName() const
179{
180 return d->packageName;
181}
182
183void Attica::DownloadDescription::setPackageName(const QString &packageName)
184{
185 d->packageName = packageName;
186}
187
188QString Attica::DownloadDescription::repository() const
189{
190 return d->repository;
191}
192
193void Attica::DownloadDescription::setRepository(const QString &repository)
194{
195 d->repository = repository;
196}
197
199{
200 return d->tags;
201}
202
204{
205 d->tags = tags;
206}
Represents a download description.
void setTags(const QStringList &tags)
Set the list of tags for this download description.
QStringList tags() const
Get the list of tags for this download description.
int id() const
The id of the description - as one Content can have multiple download descriptions associated.
The Attica namespace,.
QString name(GameStandardAction id)
KIOCORE_EXPORT CopyJob * link(const QList< QUrl > &src, const QUrl &destDir, JobFlags flags=DefaultFlags)
VehicleSection::Type type(QStringView coachNumber, QStringView coachClassification)
Category category(StandardShortcut id)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Jun 7 2024 11:58:14 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.