| 1 | /* |
| 2 | SPDX-FileCopyrightText: 2010 Frederik Gladhorn <gladhorn@kde.org> |
| 3 | |
| 4 | SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL |
| 5 | */ |
| 6 | |
| 7 | #ifndef ATTICA_LICENSE_H |
| 8 | #define ATTICA_LICENSE_H |
| 9 | |
| 10 | #include <QSharedDataPointer> |
| 11 | #include <QUrl> |
| 12 | |
| 13 | #include "attica_export.h" |
| 14 | |
| 15 | namespace Attica |
| 16 | { |
| 17 | /*! |
| 18 | \class Attica::License |
| 19 | \inheaderfile Attica/License |
| 20 | \inmodule Attica |
| 21 | |
| 22 | \brief The License class contains information about one license that the server offers. |
| 23 | |
| 24 | It consists of an integer id, a name and a link to a webpage describing the license. |
| 25 | */ |
| 26 | class ATTICA_EXPORT License |
| 27 | { |
| 28 | public: |
| 29 | /*! |
| 30 | * |
| 31 | */ |
| 32 | typedef QList<License> List; |
| 33 | class Parser; |
| 34 | |
| 35 | /*! |
| 36 | * Creates an empty License |
| 37 | */ |
| 38 | License(); |
| 39 | |
| 40 | License(const License &other); |
| 41 | |
| 42 | License &operator=(const License &other); |
| 43 | |
| 44 | ~License(); |
| 45 | |
| 46 | /* |
| 47 | <id>3</id> |
| 48 | <name>Artistic 2.0</name> |
| 49 | <link>http://dev.perl.org/perl6/rfc/346.html</link> |
| 50 | */ |
| 51 | |
| 52 | /*! |
| 53 | * |
| 54 | */ |
| 55 | uint id() const; |
| 56 | |
| 57 | /*! |
| 58 | * |
| 59 | */ |
| 60 | void setId(uint id); |
| 61 | |
| 62 | /*! |
| 63 | * |
| 64 | */ |
| 65 | QString name() const; |
| 66 | |
| 67 | /*! |
| 68 | * |
| 69 | */ |
| 70 | void setName(const QString &name); |
| 71 | |
| 72 | /*! |
| 73 | * |
| 74 | */ |
| 75 | QUrl url() const; |
| 76 | |
| 77 | /*! |
| 78 | * |
| 79 | */ |
| 80 | void setUrl(const QUrl &url); |
| 81 | |
| 82 | private: |
| 83 | class Private; |
| 84 | QSharedDataPointer<Private> d; |
| 85 | }; |
| 86 | |
| 87 | } |
| 88 | |
| 89 | #endif |
| 90 | |