digiKam
imageshacksession.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2012-02-02
7  * Description : a tool to export items to ImageShackSession web service
8  *
9  * Copyright (C) 2012 by Dodon Victor <dodonvictor at gmail dot com>
10  * Copyright (C) 2013-2018 by Caulier Gilles <caulier dot gilles at gmail dot com>
11  *
12  * This program is free software; you can redistribute it
13  * and/or modify it under the terms of the GNU General
14  * Public License as published by the Free Software Foundation;
15  * either version 2, or (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * ============================================================ */
23 
24 #ifndef DIGIKAM_IMAGE_SHACK_SESSION_H
25 #define DIGIKAM_IMAGE_SHACK_SESSION_H
26 
27 // Qt includes
28 
29 #include <QString>
30 
32 {
33 
35 {
36 
37 public:
38 
39  explicit ImageShackSession();
41 
42 public:
43 
44  bool loggedIn() const;
45  QString username() const;
46  QString email() const;
47  QString password() const;
48  QString credits() const;
49  QString authToken() const;
50 
51  void setLoggedIn(bool b);
52  void setUsername(const QString& username);
53  void setEmail(const QString& email);
54  void setPassword(const QString& pass);
55  void setCredits(const QString& credits);
56  void setAuthToken(const QString& token);
57 
58  void readSettings();
59  void saveSettings();
60 
61  void logOut();
62 
63 private:
64 
65  // Disable
66  ImageShackSession(const ImageShackSession&) = delete;
67  ImageShackSession& operator=(const ImageShackSession&) = delete;
68 
69 private:
70 
71  class Private;
72  Private* const d;
73 };
74 
75 } // namespace DigikamGenericImageShackPlugin
76 
77 #endif // DIGIKAM_IMAGE_SHACK_SESSION_H
Definition: imageshacksession.h:35
bool loggedIn() const
Definition: imageshacksession.cpp:73
void setUsername(const QString &username)
Definition: imageshacksession.cpp:108
void setLoggedIn(bool b)
Definition: imageshacksession.cpp:103
void setEmail(const QString &email)
Definition: imageshacksession.cpp:113
~ImageShackSession()
Definition: imageshacksession.cpp:68
void logOut()
Definition: imageshacksession.cpp:133
void readSettings()
Definition: imageshacksession.cpp:142
QString authToken() const
Definition: imageshacksession.cpp:93
void setCredits(const QString &credits)
Definition: imageshacksession.cpp:128
void setAuthToken(const QString &token)
Definition: imageshacksession.cpp:118
void setPassword(const QString &pass)
Definition: imageshacksession.cpp:123
QString password() const
Definition: imageshacksession.cpp:88
QString credits() const
Definition: imageshacksession.cpp:98
QString email() const
Definition: imageshacksession.cpp:83
void saveSettings()
Definition: imageshacksession.cpp:155
ImageShackSession()
Definition: imageshacksession.cpp:62
QString username() const
Definition: imageshacksession.cpp:78
Definition: imageshackitem.h:32