1/*
2 This file is part of the KDE libraries
3 SPDX-FileCopyrightText: 2007 Thiago Macieira <thiago@kde.org>
4 SPDX-FileCopyrightText: 2007 Andreas Hartmetz <ahartmetz@gmail.com>
5
6 SPDX-License-Identifier: LGPL-2.0-or-later
7*/
8
9#ifndef KSSLERRORUIDATA_H
10#define KSSLERRORUIDATA_H
11
12#include <kiocore_export.h>
13
14#include <memory>
15
16template<typename T>
17class QList;
18class QNetworkReply;
19class QSslError;
20class QSslSocket;
21
22/*!
23 * \class KSslErrorUiData
24 * \inmodule KIOCore
25 *
26 * This class can hold all the necessary data from a QSslSocket or QNetworkReply to ask the user
27 * to continue connecting in the face of SSL errors.
28 * It can be used to carry the data for the UI over time or over thread boundaries.
29 *
30 * \sa KIO::SslUi::askIgnoreSslErrors()
31 */
32class KIOCORE_EXPORT KSslErrorUiData
33{
34public:
35 /*!
36 * Default construct an instance with no useful data.
37 */
38 KSslErrorUiData();
39 /*!
40 * Create an instance and initialize it with SSL error data from \a socket.
41 */
42 KSslErrorUiData(const QSslSocket *socket);
43 /*!
44 * Create an instance and initialize it with SSL error data from \a reply.
45 * \since 5.62
46 */
47 KSslErrorUiData(const QNetworkReply *reply, const QList<QSslError> &sslErrors);
48
49 KSslErrorUiData(const KSslErrorUiData &other);
50 KSslErrorUiData &operator=(const KSslErrorUiData &);
51 ~KSslErrorUiData();
52
53 class Private;
54
55private:
56 friend class Private;
57 std::unique_ptr<Private> const d;
58};
59
60#endif // KSSLERRORUIDATA_H
61

source code of kio/src/core/ksslerroruidata.h