From 1bfdb3ad0d09c89a87d27348d8c4898379d44381 Mon Sep 17 00:00:00 2001
From: "Joachim Wuttke (h)" <j.wuttke@fz-juelich.de>
Date: Tue, 4 Jul 2023 20:46:22 +0200
Subject: [PATCH] mv fct to Frame

---
 Base/Axis/Frame.cpp           | 5 +++++
 Base/Axis/Frame.h             | 4 ++++
 Device/Coord/ICoordSystem.cpp | 5 -----
 Device/Coord/ICoordSystem.h   | 2 --
 4 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/Base/Axis/Frame.cpp b/Base/Axis/Frame.cpp
index db0d75253d3..891e9d749aa 100644
--- a/Base/Axis/Frame.cpp
+++ b/Base/Axis/Frame.cpp
@@ -109,6 +109,11 @@ bool Frame::operator==(const Frame& o) const
     return true;
 }
 
+std::vector<const Scale*> Frame::clonedAxes() const
+{
+    return m_axes.cloned_vector();
+}
+
 bool Frame::hasSameSizes(const Frame& o) const
 {
     if (rank() != o.rank())
diff --git a/Base/Axis/Frame.h b/Base/Axis/Frame.h
index f6eb2e9c693..d478bd1d530 100644
--- a/Base/Axis/Frame.h
+++ b/Base/Axis/Frame.h
@@ -75,6 +75,10 @@ public:
     //! Returns true if both Frame%s have same rank, and all axes are equal.
     bool operator==(const Frame&) const;
 
+#ifndef SWIG
+    std::vector<const Scale*> clonedAxes() const;
+#endif // SWIG
+
 protected:
     OwningVector<const Scale> m_axes;
 
diff --git a/Device/Coord/ICoordSystem.cpp b/Device/Coord/ICoordSystem.cpp
index c8a6b491ca9..6aa4fddf541 100644
--- a/Device/Coord/ICoordSystem.cpp
+++ b/Device/Coord/ICoordSystem.cpp
@@ -23,8 +23,3 @@ ICoordSystem::ICoordSystem(std::vector<const Scale*>&& axes)
 }
 
 ICoordSystem::~ICoordSystem() = default;
-
-std::vector<const Scale*> ICoordSystem::clonedAxes() const
-{
-    return m_axes.cloned_vector();
-}
diff --git a/Device/Coord/ICoordSystem.h b/Device/Coord/ICoordSystem.h
index ce016d7ba88..02a8e31930f 100644
--- a/Device/Coord/ICoordSystem.h
+++ b/Device/Coord/ICoordSystem.h
@@ -31,8 +31,6 @@ public:
     ICoordSystem* clone() const override = 0;
 
     virtual std::string nameOfAxis(size_t i_axis) const = 0;
-
-    std::vector<const Scale*> clonedAxes() const;
 };
 
 #endif // BORNAGAIN_DEVICE_COORD_ICOORDSYSTEM_H
-- 
GitLab