diff options
author | Claudius "keldu" Holeksa <mail@keldu.de> | 2024-01-23 13:12:11 +0100 |
---|---|---|
committer | Claudius "keldu" Holeksa <mail@keldu.de> | 2024-01-23 13:12:11 +0100 |
commit | 8dad985328e2183b224300aa992951131956fdb3 (patch) | |
tree | ceda3d9805335f36f571fb36585444ebdb421a02 /modules/io/io_helpers.h | |
parent | a9d2025030d0a7641f4b0701bd4aff7d2db5aeb4 (diff) |
core,codec-json,codec-minecraft,codec-netcdf,codec,io-tls,io,io_codec,window,window-opengl:
Renamed file endings and changed includes
Diffstat (limited to 'modules/io/io_helpers.h')
-rw-r--r-- | modules/io/io_helpers.h | 53 |
1 files changed, 0 insertions, 53 deletions
diff --git a/modules/io/io_helpers.h b/modules/io/io_helpers.h deleted file mode 100644 index 761ee35..0000000 --- a/modules/io/io_helpers.h +++ /dev/null @@ -1,53 +0,0 @@ -#pragma once - -#include <forstio/async/async.h> -#include <forstio/common.h> - -#include <cstdint> -#include <optional> - -namespace saw { -/* - * Helper classes for the specific driver implementations - */ - -/* - * Since I don't want to repeat these implementations for tls on unix systems - * and gnutls doesn't let me write or read into buffers I have to have this kind - * of strange abstraction. This may also be reusable for windows/macOS though. - */ -class input_stream; - -class read_task_and_step_helper { -public: - struct read_io_task { - void *buffer; - size_t min_length; - size_t max_length; - size_t already_read = 0; - }; - std::optional<read_io_task> read_task; - own<conveyor_feeder<size_t>> read_done = nullptr; - - own<conveyor_feeder<void>> on_read_disconnect = nullptr; - -public: - void read_step(input_stream &reader); -}; - -class output_stream; - -class write_task_and_step_helper { -public: - struct write_io_task { - const void *buffer; - size_t length; - size_t already_written = 0; - }; - std::optional<write_io_task> write_task; - own<conveyor_feeder<size_t>> write_done = nullptr; - -public: - void write_step(output_stream &writer); -}; -} // namespace saw |