HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
stream.hpp
1// Copyright Take Vos 2020.
2// Distributed under the Boost Software License, Version 1.0.
3// (See accompanying file LICENSE_1_0.txt or copy at https://www.boost.org/LICENSE_1_0.txt)
4
5#pragma once
6
7#include "../macros.hpp"
8
9hi_export_module(hikogui.net.stream);
10
11hi_export namespace hi::inline v1 {
12
14protected:
15 bool connecting = false;
16
19 packet_buffer readBuffer;
20
23 packet_buffer writeBuffer;
24
25public:
29
32 virtual bool needToRead();
33
36 virtual bool needToWrite();
37
41 [[nodiscard]] virtual void handleReadyToReadEvent();
42
46 [[nodiscard]] virtual void handleReadyToWriteEvent();
47}
48
49} // namespace hi::inline v1
DOXYGEN BUG.
Definition algorithm_misc.hpp:20
Definition packet_buffer.hpp:13
Definition stream.hpp:13
virtual bool needToWrite()
Check if the socket-stream needs to read.
virtual void handleReadyToReadEvent()
Handle ready-to-read event.
virtual bool needToRead()
Check if the socket-stream needs to read.
virtual void handleReadyToWriteEvent()
Handle ready-to-write event.
void handleConnect()
Handle connected event.