From 5c1c672e018e41e5c87a0263a851684a52d9c1fb Mon Sep 17 00:00:00 2001 From: HampusM Date: Sun, 27 Mar 2022 19:21:22 +0200 Subject: refactor: replace string matrix with template matrix --- src/engine/graphics/string_matrix.hpp | 52 ----------------------------------- 1 file changed, 52 deletions(-) delete mode 100644 src/engine/graphics/string_matrix.hpp (limited to 'src/engine/graphics/string_matrix.hpp') diff --git a/src/engine/graphics/string_matrix.hpp b/src/engine/graphics/string_matrix.hpp deleted file mode 100644 index ff0939c..0000000 --- a/src/engine/graphics/string_matrix.hpp +++ /dev/null @@ -1,52 +0,0 @@ -#pragma once - -#include "interfaces/matrix.hpp" - -#include "engine/data/bounds.hpp" -#include "engine/data/vector2.hpp" -#include "engine/matrix_iterator.hpp" - -#include -#include -#include -#include - -class StringMatrix : public IMatrix -{ -public: - explicit StringMatrix(const Bounds &bounds) noexcept; - - StringMatrix(const StringMatrix &string_matrix) noexcept; - - StringMatrix(StringMatrix &&string_matrix) noexcept; - - ~StringMatrix() noexcept override; - - void fill(std::string_view element) noexcept override; - - [[nodiscard]] std::string_view get(const Vector2 &pos) const noexcept override; - - void set(const Vector2 &pos, std::string_view element) noexcept override; - - [[nodiscard]] uint32_t get_row_cnt() const noexcept override; - - [[nodiscard]] uint32_t get_column_cnt() const noexcept override; - - [[nodiscard]] MatrixIterator begin() const noexcept override; - - [[nodiscard]] MatrixIterator end() const noexcept override; - - StringMatrix &operator=(const StringMatrix &rhs) noexcept; - - StringMatrix &operator=(StringMatrix &&rhs) noexcept; - -private: - gsl::owner _matrix; - - uint32_t _row_cnt; - uint32_t _column_cnt; - - void _delete_matrix() noexcept; - - void _copy_matrix_from(const StringMatrix &source) noexcept; -}; -- cgit v1.2.3-18-g5258