From 2066e4911948d11cac5a234d2f7773dc5f06ba96 Mon Sep 17 00:00:00 2001 From: Aki Date: Mon, 18 Mar 2024 23:41:20 +0100 Subject: Added filesystem-only starshatter::data DataLoader replacement Step by step. The intent is to find a good spot between current data representations and the standard library and put the intermediate stage there. After it matures a bit, we can move further away. --- FoundationEx/src/reader/buffer.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'FoundationEx/src/reader/buffer.h') diff --git a/FoundationEx/src/reader/buffer.h b/FoundationEx/src/reader/buffer.h index c36310a..532a8f9 100644 --- a/FoundationEx/src/reader/buffer.h +++ b/FoundationEx/src/reader/buffer.h @@ -7,6 +7,7 @@ #pragma once #include +#include namespace starshatter @@ -35,12 +36,12 @@ struct BufferReader : public BaseReader Count read(char* dest, Count bytes) override; Count peek(char* dest) const override; Count peek(char* dest, Count bytes) const override; - const char* data() const override; + Text more() override; private: - Source buffer; - Count size; - Count position; + Source buffer = {}; + Count size = {}; + Count position = {}; }; -- cgit v1.1