KD SOAP API Documentation: KDSoapDelayedResponseHandle.cpp Source File

| KD SOAP API Documentation 2.2

Loading...
Searching...
No Matches
KDSoapDelayedResponseHandle.cpp
Go to the documentation of this file.
1/****************************************************************************
2**
3** This file is part of the KD Soap project.
4**
5** SPDX-FileCopyrightText: 2010 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.com>
6**
7** SPDX-License-Identifier: MIT
8**
9****************************************************************************/
10
11#include "KDSoapDelayedResponseHandle.h"
12#include "KDSoapServerSocket_p.h"
13#include <QPointer>
14#include <QSharedData>
15
16class KDSoapDelayedResponseHandleData : public QSharedData
17{
18public:
19 KDSoapDelayedResponseHandleData(KDSoapServerSocket *s)
20 : socket(s)
21 {
22 }
23 // QPointer in case the client disconnects during a delayed response
24 QPointer<KDSoapServerSocket> socket;
25};
26
27KDSoapDelayedResponseHandle::KDSoapDelayedResponseHandle()
28 : data(new KDSoapDelayedResponseHandleData(nullptr))
29{
30}
31
32 KDSoapDelayedResponseHandle::KDSoapDelayedResponseHandle(const KDSoapDelayedResponseHandle &rhs)
33 : data(rhs.data)
34{
35}
36
37 KDSoapDelayedResponseHandle &KDSoapDelayedResponseHandle::operator=(const KDSoapDelayedResponseHandle &rhs)
38{
39 if (this != &rhs) {
40 data.operator=(rhs.data);
41 }
42 return *this;
43}
44
45KDSoapDelayedResponseHandle::~KDSoapDelayedResponseHandle()
46{
47}
48
49 KDSoapDelayedResponseHandle::KDSoapDelayedResponseHandle(KDSoapServerSocket *socket)
50 : data(new KDSoapDelayedResponseHandleData(socket))
51{
52 socket->setResponseDelayed();
53}
54
55 KDSoapServerSocket *KDSoapDelayedResponseHandle::serverSocket() const
56{
57 return data->socket;
58}
KDSoapDelayedResponseHandle.h
KDSoapServerSocket_p.h
KDSoapDelayedResponseHandle
Definition KDSoapDelayedResponseHandle.h:27
KDSoapDelayedResponseHandle::KDSoapDelayedResponseHandle
KDSoapDelayedResponseHandle()
Definition KDSoapDelayedResponseHandle.cpp:27
KDSoapDelayedResponseHandle::~KDSoapDelayedResponseHandle
~KDSoapDelayedResponseHandle()
Definition KDSoapDelayedResponseHandle.cpp:45
KDSoapDelayedResponseHandle::operator=
KDSoapDelayedResponseHandle & operator=(const KDSoapDelayedResponseHandle &)
Definition KDSoapDelayedResponseHandle.cpp:37
KDSoapServerSocket
Definition KDSoapServerSocket_p.h:35
KDSoapServerSocket::setResponseDelayed
void setResponseDelayed()
Definition KDSoapServerSocket.cpp:522
QPointer
QSharedData

© 2010-2024 Klarälvdalens Datakonsult AB (KDAB)
"The Qt, C++ and OpenGL Experts"
https://www.kdab.com/
https://www.kdab.com/development-resources/qt-tools/kd-soap/
Generated on Sun Jan 7 2024 11:47:36 for KD SOAP API Documentation by doxygen 1.9.8