1// Copyright (C) 2019 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
3
4#ifndef QABSTRACTHTTPSERVER_P_H
5#define QABSTRACTHTTPSERVER_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists for the convenience
12// of QHttpServer. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16
17#include <QtHttpServer/qabstracthttpserver.h>
18#include <QtHttpServer/qthttpserverglobal.h>
19
20#include <private/qobject_p.h>
21
22#include <QtCore/qcoreapplication.h>
23
24#if defined(QT_WEBSOCKETS_LIB)
25#include <QtWebSockets/qwebsocketserver.h>
26#endif // defined(QT_WEBSOCKETS_LIB)
27
28#if QT_CONFIG(ssl)
29#include <QtNetwork/qsslconfiguration.h>
30#endif
31
32QT_BEGIN_NAMESPACE
33
34class QHttpServerRequest;
35
36class QAbstractHttpServerPrivate: public QObjectPrivate
37{
38public:
39 Q_DECLARE_PUBLIC(QAbstractHttpServer)
40
41 QAbstractHttpServerPrivate();
42
43#if defined(QT_WEBSOCKETS_LIB)
44 QWebSocketServer websocketServer {
45 QCoreApplication::applicationName() + QLatin1Char('/') + QCoreApplication::applicationVersion(),
46 QWebSocketServer::NonSecureMode
47 };
48#endif // defined(QT_WEBSOCKETS_LIB)
49
50 void handleNewConnections();
51
52#if QT_CONFIG(ssl)
53 QSslConfiguration sslConfiguration;
54 bool sslEnabled = false;
55#endif
56};
57
58QT_END_NAMESPACE
59
60#endif // QABSTRACTHTTPSERVER_P_H
61

source code of qthttpserver/src/httpserver/qabstracthttpserver_p.h