aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/matrix.hpp
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2022-04-10 17:20:49 +0200
committerHampusM <hampus@hampusmat.com>2022-06-13 17:56:58 +0200
commitb36d072ad7a7b9c6e30fcb25d6bbb001a8393468 (patch)
tree7749fc877652bb2cf7bbd2b7c1fed5e3abe397fc /src/interfaces/matrix.hpp
parentb828d4799a84beb1afbd889e5c4cb939a8b3df78 (diff)
refactor: add factory class & make DI container return unique ptrs
Diffstat (limited to 'src/interfaces/matrix.hpp')
-rw-r--r--src/interfaces/matrix.hpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/interfaces/matrix.hpp b/src/interfaces/matrix.hpp
index edcf935..7fea003 100644
--- a/src/interfaces/matrix.hpp
+++ b/src/interfaces/matrix.hpp
@@ -1,8 +1,8 @@
#pragma once
+#include "DI/factory.hpp"
#include "engine/data/bounds.hpp"
#include "engine/data/vector2.hpp"
-
#include "engine/matrix_iterator.hpp"
#include <memory>
@@ -39,4 +39,4 @@ public:
};
template <typename Element>
-using IMatrixFactory = std::shared_ptr<IMatrix<Element>> (*)(const Bounds &bounds);
+using IMatrixFactory = Factory<std::unique_ptr<IMatrix<Element>>(const Bounds &bounds)>;