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#include "../macros.hpp"
6#pragma once
7
8namespace hi::inline v1 {
9
11protected:
12 bool connecting = false;
13
16 packet_buffer readBuffer;
17
20 packet_buffer writeBuffer;
21
22public:
26
29 virtual bool needToRead();
30
33 virtual bool needToWrite();
34
38 [[nodiscard]] virtual void handleReadyToReadEvent();
39
43 [[nodiscard]] virtual void handleReadyToWriteEvent();
44}
45
46} // namespace hi::inline v1
DOXYGEN BUG.
Definition algorithm.hpp:16
constexpr Out narrow_cast(In const &rhs) noexcept
Cast numeric values without loss of precision.
Definition cast.hpp:377
Definition packet_buffer.hpp:10
Definition stream.hpp:10
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.