Deskflow 1.22.0.197
Keyboard and mouse sharing utility
Loading...
Searching...
No Matches
ClientProxyUnknown.h
Go to the documentation of this file.
1/*
2 * Deskflow -- mouse and keyboard sharing utility
3 * SPDX-FileCopyrightText: (C) 2025 Deskflow Developers
4 * SPDX-FileCopyrightText: (C) 2012 - 2016 Symless Ltd.
5 * SPDX-FileCopyrightText: (C) 2004 Chris Schoeneman
6 * SPDX-License-Identifier: GPL-2.0-only WITH LicenseRef-OpenSSL-Exception
7 */
8
9#pragma once
10
11#include "base/Event.h"
12#include "base/EventTypes.h"
14
15#include <string>
16
17class ClientProxy;
18class EventQueueTimer;
19namespace deskflow {
20class IStream;
21}
22class Server;
23class IEventQueue;
24
26{
27public:
28 ClientProxyUnknown(deskflow::IStream *stream, double timeout, Server *server, IEventQueue *events);
32
35
37
38
40
46
49 {
50 return m_stream;
51 }
52
54
55private:
56 void sendSuccess();
57 void sendFailure();
58 void addStreamHandlers();
59 void addProxyHandlers();
60 void removeHandlers();
61 void initProxy(const std::string &name, int major, int minor);
62 void removeTimer();
63 void handleData();
64 void handleWriteError();
65 void handleTimeout();
66 void handleDisconnect();
67
68private:
69 deskflow::IStream *m_stream = nullptr;
70 EventQueueTimer *m_timer = nullptr;
71 ClientProxy *m_proxy = nullptr;
72 bool m_ready = false;
73 Server *m_server = nullptr;
74 IEventQueue *m_events = nullptr;
75};
static const struct sockaddr FAR * name
Definition ArchNetworkWinsock.cpp:27
static fd_set FAR fd_set FAR fd_set FAR const struct timeval FAR * timeout
Definition ArchNetworkWinsock.cpp:39
ClientProxyUnknown(ClientProxyUnknown &&)=delete
ClientProxyUnknown & operator=(ClientProxyUnknown &&)=delete
deskflow::IStream * getStream()
Get the stream.
Definition ClientProxyUnknown.h:48
ClientProxy * orphanClientProxy()
Get the client proxy.
Definition ClientProxyUnknown.cpp:63
ClientProxyUnknown(ClientProxyUnknown const &)=delete
ClientProxyUnknown & operator=(ClientProxyUnknown const &)=delete
~ClientProxyUnknown()
Definition ClientProxyUnknown.cpp:55
ClientProxyUnknown(deskflow::IStream *stream, double timeout, Server *server, IEventQueue *events)
Definition ClientProxyUnknown.cpp:37
Generic proxy for client.
Definition ClientProxy.h:20
Definition SimpleEventQueueBuffer.cpp:13
Event queue interface.
Definition IEventQueue.h:32
Deskflow server.
Definition Server.h:44
Bidirectional stream interface.
Definition IStream.h:24
Definition EventTypes.h:11