From 7fe47a9d5b1727a61dc724523b530762f6d6ba19 Mon Sep 17 00:00:00 2001 From: rtk0c Date: Thu, 30 Jun 2022 21:38:53 -0700 Subject: Restructure project --- core/src/Utils/IO/StringIntegration.hpp | 37 --------------------------------- 1 file changed, 37 deletions(-) delete mode 100644 core/src/Utils/IO/StringIntegration.hpp (limited to 'core/src/Utils/IO/StringIntegration.hpp') diff --git a/core/src/Utils/IO/StringIntegration.hpp b/core/src/Utils/IO/StringIntegration.hpp deleted file mode 100644 index 536cb83..0000000 --- a/core/src/Utils/IO/StringIntegration.hpp +++ /dev/null @@ -1,37 +0,0 @@ -#pragma once - -#include "Utils/IO/DataStream.hpp" - -#include -#include -#include - -namespace DataStreamAdapters { -struct String -{ - static void ReadFromDataStream(InputDataStream& stream, std::string& str) - { - uint64_t size; - stream.Read(size); - - str = {}; - str.reserve(size); - stream.ReadBytes(size, std::back_inserter(str)); - } - - static void WriteToDataStream(OutputDataStream& stream, const std::string& str) - { - stream.Write((uint64_t)str.size()); - stream.WriteBytes(str.size(), str.data()); - } -}; - -struct StringView -{ - static void WriteToDataStream(OutputDataStream& stream, const std::string_view& str) - { - stream.Write((uint64_t)str.size()); - stream.WriteBytes(str.size(), str.data()); - } -}; -} // namespace DataStreamAdapters -- cgit v1.2.3-70-g09d2