digiKam
imageshackmpform.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 ImageShack 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_MPFORM_H
25 #define DIGIKAM_IMAGE_SHACK_MPFORM_H
26 
27 // Qt includes
28 
29 #include <QByteArray>
30 #include <QString>
31 
33 {
34 
36 {
37 
38 public:
39 
40  explicit ImageShackMPForm();
42 
43  void finish();
44  void reset();
45 
46  void addPair(const QString& name, const QString& value);
47  bool addFile(const QString& name, const QString& path);
48 
49  QString contentType() const;
50  QByteArray formData() const;
51  QString boundary() const;
52 
53 private:
54 
55  QByteArray m_buffer;
56  QByteArray m_boundary;
57 };
58 
59 } // namespace DigikamGenericImageShackPlugin
60 
61 #endif // DIGIKAM_IMAGE_SHACK_MPFORM_H
Definition: imageshackmpform.h:36
bool addFile(const QString &name, const QString &path)
Definition: imageshackmpform.cpp:92
ImageShackMPForm()
Definition: imageshackmpform.cpp:43
QString boundary() const
Definition: imageshackmpform.cpp:137
void finish()
Definition: imageshackmpform.cpp:61
QString contentType() const
Definition: imageshackmpform.cpp:132
QByteArray formData() const
Definition: imageshackmpform.cpp:142
void addPair(const QString &name, const QString &value)
Definition: imageshackmpform.cpp:70
void reset()
Definition: imageshackmpform.cpp:53
~ImageShackMPForm()
Definition: imageshackmpform.cpp:49
qulonglong value
Definition: itemviewutilities.cpp:592
Definition: imageshackitem.h:32