From 561214347d175ee881aadba4e8796c51f8c359e5 Mon Sep 17 00:00:00 2001 From: Owen Arnold Date: Mon, 9 Feb 2015 10:13:48 +0000 Subject: [PATCH] refs #10904 SpecialCoords API->Kernel Since we have put PeakShape in Geometry, SpecialCoordinateSystem must be moved to the Kernel package out of API. --- Code/Mantid/Framework/API/CMakeLists.txt | 2 -- .../API/inc/MantidAPI/IMDEventWorkspace.h | 2 +- .../API/inc/MantidAPI/IMDHistoWorkspace.h | 2 +- .../API/inc/MantidAPI/IMDWorkspace.h | 4 ++-- .../API/inc/MantidAPI/IPeaksWorkspace.h | 6 ++--- .../API/inc/MantidAPI/MatrixWorkspace.h | 2 +- .../API/inc/MantidAPI/PeakTransform.h | 4 ++-- .../API/inc/MantidAPI/PeakTransformHKL.h | 2 +- .../API/inc/MantidAPI/PeakTransformQLab.h | 2 +- .../API/inc/MantidAPI/PeakTransformQSample.h | 2 +- .../Framework/API/src/MatrixWorkspace.cpp | 4 ++-- .../Framework/API/src/PeakTransformHKL.cpp | 4 ++-- .../Framework/API/src/PeakTransformQLab.cpp | 4 ++-- .../API/src/PeakTransformQSample.cpp | 4 ++-- .../Framework/API/test/MatrixWorkspaceTest.h | 2 +- Code/Mantid/Framework/API/test/MockObjects.h | 2 +- .../Framework/API/test/PeakTransformHKLTest.h | 2 +- .../API/test/PeakTransformQLabTest.h | 2 +- .../API/test/PeakTransformQSampleTest.h | 2 +- .../Algorithms/test/RebinByTimeBaseTest.h | 2 +- .../inc/MantidCrystal/PeakBackground.h | 4 ++-- .../inc/MantidCrystal/SetSpecialCoordinates.h | 8 +++---- .../Framework/Crystal/src/PeakBackground.cpp | 2 +- .../Crystal/src/PeakClusterProjection.cpp | 2 +- .../Crystal/src/SetSpecialCoordinates.cpp | 6 ++--- .../Crystal/test/FindClusterFacesTest.h | 2 +- .../Crystal/test/PeakBackgroundTest.h | 8 +++---- .../Crystal/test/PeakClusterProjectionTest.h | 6 ++--- .../Crystal/test/SetSpecialCoordinatesTest.h | 6 ++--- .../inc/MantidDataObjects/NoShape.h | 2 +- .../inc/MantidDataObjects/PeakShapeBase.h | 8 +++---- .../MantidDataObjects/PeakShapeEllipsoid.h | 2 +- .../MantidDataObjects/PeakShapeSpherical.h | 6 ++--- .../inc/MantidDataObjects/PeaksWorkspace.h | 4 ++-- .../Framework/DataObjects/src/NoShape.cpp | 4 ++-- .../DataObjects/src/PeakShapeBase.cpp | 6 ++--- .../DataObjects/src/PeakShapeEllipsoid.cpp | 2 +- .../src/PeakShapeEllipsoidFactory.cpp | 3 +-- .../DataObjects/src/PeakShapeSpherical.cpp | 4 ++-- .../src/PeakShapeSphericalFactory.cpp | 4 ++-- .../DataObjects/src/PeaksWorkspace.cpp | 6 ++--- .../Framework/DataObjects/test/MockObjects.h | 3 ++- .../Framework/DataObjects/test/NoShapeTest.h | 5 ++--- .../test/PeakShapeEllipsoidFactoryTest.h | 3 +-- .../DataObjects/test/PeakShapeEllipsoidTest.h | 1 - .../test/PeakShapeSphericalFactoryTest.h | 3 +-- .../DataObjects/test/PeakShapeSphericalTest.h | 3 +-- .../DataObjects/test/PeaksWorkspaceTest.h | 2 +- .../inc/MantidGeometry/Crystal/PeakShape.h | 4 ++-- Code/Mantid/Framework/Kernel/CMakeLists.txt | 4 +++- .../MantidKernel}/SpecialCoordinateSystem.h | 6 ++--- .../test/SpecialCoordinateSystemTest.h | 8 +++---- .../MantidMDAlgorithms/IntegratePeaksMD2.h | 2 +- .../src/ConvertToDiffractionMDWorkspace.cpp | 6 ++--- .../MDAlgorithms/src/IntegratePeaksMD.cpp | 14 ++++++------ .../MDAlgorithms/src/IntegratePeaksMD2.cpp | 22 +++++++++---------- .../MDAlgorithms/test/CentroidPeaksMD2Test.h | 6 ++--- .../MDAlgorithms/test/CentroidPeaksMDTest.h | 6 ++--- .../ConvertToDiffractionMDWorkspace2Test.h | 6 ++--- .../ConvertToDiffractionMDWorkspaceTest.h | 6 ++--- .../MDAlgorithms/test/ConvertToMDTest.h | 6 ++--- .../MDAlgorithms/test/IntegratePeaksMD2Test.h | 4 ++-- .../MDAlgorithms/test/IntegratePeaksMDTest.h | 4 ++-- .../inc/MantidMDEvents/ConvToMDBase.h | 2 +- .../inc/MantidMDEvents/MDEventWorkspace.h | 4 ++-- .../inc/MantidMDEvents/MDHistoWorkspace.h | 4 ++-- .../inc/MantidMDEvents/MDWSDescription.h | 6 ++--- .../Framework/MDEvents/src/ConvToMDBase.cpp | 2 +- .../MDEvents/src/Integrate3DEvents.cpp | 2 +- .../MDEvents/src/MDEventWorkspace.cpp | 6 ++--- .../MDEvents/src/MDHistoWorkspace.cpp | 6 ++--- .../MDEvents/src/MDWSDescription.cpp | 6 ++--- .../Framework/MDEvents/src/MDWSTransform.cpp | 6 ++--- .../MDEvents/test/MDEventWorkspaceTest.h | 8 +++---- .../test/MDHistoWorkspaceIteratorTest.h | 1 + .../MDEvents/test/MDHistoWorkspaceTest.h | 8 +++---- .../MDEvents/test/MDWSDescriptionTest.h | 5 +++-- .../mantid/api/src/Exports/IMDWorkspace.cpp | 10 ++++----- .../inc/MantidTestHelpers/FakeObjects.h | 4 ++-- .../MantidQt/API/test/SignalRangeTest.h | 2 +- .../ConcretePeaksPresenter.h | 4 ++-- .../src/ConcretePeaksPresenter.cpp | 9 ++++---- .../test/ConcretePeaksPresenterTest.h | 8 +++---- .../MantidQt/SliceViewer/test/MockObjects.h | 2 +- .../inc/MantidVatesAPI/MDLoadingPresenter.h | 2 +- .../vtkDataSetToNonOrthogonalDataSet.h | 4 ++-- .../src/vtkDataSetToNonOrthogonalDataSet.cpp | 6 ++--- Code/Mantid/Vates/VatesAPI/test/MockObjects.h | 2 +- .../vtkDataSetToNonOrthogonalDataSetTest.h | 2 +- 89 files changed, 197 insertions(+), 199 deletions(-) rename Code/Mantid/Framework/{API/inc/MantidAPI => Kernel/inc/MantidKernel}/SpecialCoordinateSystem.h (59%) rename Code/Mantid/Framework/{API => Kernel}/test/SpecialCoordinateSystemTest.h (88%) diff --git a/Code/Mantid/Framework/API/CMakeLists.txt b/Code/Mantid/Framework/API/CMakeLists.txt index e5c265295913..c17ec59ac694 100644 --- a/Code/Mantid/Framework/API/CMakeLists.txt +++ b/Code/Mantid/Framework/API/CMakeLists.txt @@ -272,7 +272,6 @@ set ( INC_FILES inc/MantidAPI/ScriptRepositoryFactory.h inc/MantidAPI/SingleValueParameter.h inc/MantidAPI/SingleValueParameterParser.h - inc/MantidAPI/SpecialCoordinateSystem.h inc/MantidAPI/SpectraAxis.h inc/MantidAPI/SpectrumDetectorMapping.h inc/MantidAPI/TableRow.h @@ -361,7 +360,6 @@ set ( TEST_FILES SampleTest.h ScopedWorkspaceTest.h ScriptBuilderTest.h - SpecialCoordinateSystemTest.h SpectraAxisTest.h SpectrumDetectorMappingTest.h TextAxisTest.h diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/IMDEventWorkspace.h b/Code/Mantid/Framework/API/inc/MantidAPI/IMDEventWorkspace.h index b27ea58065c8..723ce3d7a8f8 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/IMDEventWorkspace.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/IMDEventWorkspace.h @@ -83,7 +83,7 @@ class MANTID_API_DLL IMDEventWorkspace : public API::IMDWorkspace, virtual bool threadSafe() const; virtual void setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem) = 0; + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem) = 0; protected: virtual const std::string toString() const; diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/IMDHistoWorkspace.h b/Code/Mantid/Framework/API/inc/MantidAPI/IMDHistoWorkspace.h index dfb436796e5b..942e14af6ee2 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/IMDHistoWorkspace.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/IMDHistoWorkspace.h @@ -89,7 +89,7 @@ class DLLExport IMDHistoWorkspace : public IMDWorkspace, virtual double &operator[](const size_t &index) = 0; virtual void setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem) = 0; + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem) = 0; virtual boost::shared_ptr clone() const = 0; diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/IMDWorkspace.h b/Code/Mantid/Framework/API/inc/MantidAPI/IMDWorkspace.h index 2fa06b49ce66..c3bebd3e4f1d 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/IMDWorkspace.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/IMDWorkspace.h @@ -12,7 +12,7 @@ #include "MantidAPI/MDGeometry.h" #include "MantidGeometry/MDGeometry/MDImplicitFunction.h" #include "MantidAPI/IMDWorkspace.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include "MantidAPI/ITableWorkspace.h" namespace Mantid { @@ -119,7 +119,7 @@ class MANTID_API_DLL IMDWorkspace : public Workspace, /// Clear existing masks virtual void clearMDMasking() = 0; /// - virtual Mantid::API::SpecialCoordinateSystem + virtual Mantid::Kernel::SpecialCoordinateSystem getSpecialCoordinateSystem() const = 0; /// if a workspace was filebacked, this should clear file-based status, delete /// file-based information and close related files. diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/IPeaksWorkspace.h b/Code/Mantid/Framework/API/inc/MantidAPI/IPeaksWorkspace.h index 66e74fae17ff..7282be8542cc 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/IPeaksWorkspace.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/IPeaksWorkspace.h @@ -6,7 +6,7 @@ //---------------------------------------------------------------------- #include "MantidAPI/ITableWorkspace.h" #include "MantidAPI/ExperimentInfo.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" namespace Mantid { @@ -127,7 +127,7 @@ class MANTID_API_DLL IPeaksWorkspace : public ITableWorkspace, * @param coordinateSystem : Special Q3D coordinate system to use. */ virtual void setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem) = 0; + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem) = 0; //--------------------------------------------------------------------------------------------- /** @@ -135,7 +135,7 @@ class MANTID_API_DLL IPeaksWorkspace : public ITableWorkspace, * @returns special Q3D coordinate system to use being used by this * PeaksWorkspace object. Probably the one the workspace was generated with. */ - virtual Mantid::API::SpecialCoordinateSystem + virtual Mantid::Kernel::SpecialCoordinateSystem getSpecialCoordinateSystem() const = 0; virtual std::vector> peakInfo(Kernel::V3D QFrame, bool labCoords) const = 0; diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/MatrixWorkspace.h b/Code/Mantid/Framework/API/inc/MantidAPI/MatrixWorkspace.h index 1db5c7abd335..bd7788aa956b 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/MatrixWorkspace.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/MatrixWorkspace.h @@ -392,7 +392,7 @@ class MANTID_API_DLL MatrixWorkspace : public IMDWorkspace, void clearMDMasking(); /// @return the special coordinate system used if any. - virtual Mantid::API::SpecialCoordinateSystem + virtual Mantid::Kernel::SpecialCoordinateSystem getSpecialCoordinateSystem() const; //===================================================================================== diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransform.h b/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransform.h index 7facdd96ba66..2866ddabcc9f 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransform.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransform.h @@ -5,7 +5,7 @@ #include "MantidAPI/IPeak.h" #include #include -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" namespace Mantid { namespace API { @@ -35,7 +35,7 @@ class DLLExport PeakTransform { /// Getter for a friendly name to describe the transform type. virtual std::string getFriendlyName() const = 0; /// Getter for the special coordinate representation of this transform type. - virtual Mantid::API::SpecialCoordinateSystem getCoordinateSystem() const = 0; + virtual Mantid::Kernel::SpecialCoordinateSystem getCoordinateSystem() const = 0; protected: PeakTransform(const PeakTransform &other); diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformHKL.h b/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformHKL.h index 44a17b23d9d5..0b68e71e446e 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformHKL.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformHKL.h @@ -31,7 +31,7 @@ class DLLExport PeakTransformHKL : public PeakTransform { /// Getter for a friendly name to describe the transform type. virtual std::string getFriendlyName() const { return name(); } /// Getter for the special coordinate representation of this transform type. - Mantid::API::SpecialCoordinateSystem getCoordinateSystem() const; + Mantid::Kernel::SpecialCoordinateSystem getCoordinateSystem() const; }; /// Typedef a factory for type of PeaksTransform. diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformQLab.h b/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformQLab.h index 275142c5f7a5..fd72890a93ef 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformQLab.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformQLab.h @@ -31,7 +31,7 @@ class DLLExport PeakTransformQLab : public PeakTransform { /// Get the transform friendly name. virtual std::string getFriendlyName() const { return name(); } /// Getter for the special coordinate representation of this transform type. - Mantid::API::SpecialCoordinateSystem getCoordinateSystem() const; + Mantid::Kernel::SpecialCoordinateSystem getCoordinateSystem() const; }; /// Typedef a factory for type of PeaksTransform. diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformQSample.h b/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformQSample.h index c7ea612447e3..ecc0d581d6be 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformQSample.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/PeakTransformQSample.h @@ -32,7 +32,7 @@ class DLLExport PeakTransformQSample : public PeakTransform { /// Getter for the transform name. virtual std::string getFriendlyName() const { return name(); } /// Getter for the special coordinate representation of this transform type. - Mantid::API::SpecialCoordinateSystem getCoordinateSystem() const; + Mantid::Kernel::SpecialCoordinateSystem getCoordinateSystem() const; }; /// Typedef a factory for type of PeaksTransform. diff --git a/Code/Mantid/Framework/API/src/MatrixWorkspace.cpp b/Code/Mantid/Framework/API/src/MatrixWorkspace.cpp index 2d7e481e871a..c326c152d60c 100644 --- a/Code/Mantid/Framework/API/src/MatrixWorkspace.cpp +++ b/Code/Mantid/Framework/API/src/MatrixWorkspace.cpp @@ -1704,9 +1704,9 @@ void MatrixWorkspace::clearMDMasking() { /** @return the special coordinate system used if any. */ -Mantid::API::SpecialCoordinateSystem +Mantid::Kernel::SpecialCoordinateSystem MatrixWorkspace::getSpecialCoordinateSystem() const { - return Mantid::API::None; + return Mantid::Kernel::None; } /** diff --git a/Code/Mantid/Framework/API/src/PeakTransformHKL.cpp b/Code/Mantid/Framework/API/src/PeakTransformHKL.cpp index 729122e0e161..969de08b0b57 100644 --- a/Code/Mantid/Framework/API/src/PeakTransformHKL.cpp +++ b/Code/Mantid/Framework/API/src/PeakTransformHKL.cpp @@ -55,9 +55,9 @@ PeakTransformHKL::transformPeak(const Mantid::API::IPeak &peak) const { /** * @return Special coordinate system associated with this type of transform. */ -Mantid::API::SpecialCoordinateSystem +Mantid::Kernel::SpecialCoordinateSystem PeakTransformHKL::getCoordinateSystem() const { - return Mantid::API::HKL; + return Mantid::Kernel::HKL; } } } diff --git a/Code/Mantid/Framework/API/src/PeakTransformQLab.cpp b/Code/Mantid/Framework/API/src/PeakTransformQLab.cpp index cb9ae038f4dd..7bd49d640b5e 100644 --- a/Code/Mantid/Framework/API/src/PeakTransformQLab.cpp +++ b/Code/Mantid/Framework/API/src/PeakTransformQLab.cpp @@ -54,9 +54,9 @@ PeakTransformQLab::transformPeak(const Mantid::API::IPeak &peak) const { /** * @return Special coordinate system associated with this type of transform. */ -Mantid::API::SpecialCoordinateSystem +Mantid::Kernel::SpecialCoordinateSystem PeakTransformQLab::getCoordinateSystem() const { - return Mantid::API::QLab; + return Mantid::Kernel::QLab; } } } diff --git a/Code/Mantid/Framework/API/src/PeakTransformQSample.cpp b/Code/Mantid/Framework/API/src/PeakTransformQSample.cpp index e7c9565a986e..6173aff47bc2 100644 --- a/Code/Mantid/Framework/API/src/PeakTransformQSample.cpp +++ b/Code/Mantid/Framework/API/src/PeakTransformQSample.cpp @@ -54,9 +54,9 @@ PeakTransformQSample::transformPeak(const Mantid::API::IPeak &peak) const { /** * @return Special coordinate system associated with this type of transform. */ -Mantid::API::SpecialCoordinateSystem +Mantid::Kernel::SpecialCoordinateSystem PeakTransformQSample::getCoordinateSystem() const { - return Mantid::API::QSample; + return Mantid::Kernel::QSample; } } } diff --git a/Code/Mantid/Framework/API/test/MatrixWorkspaceTest.h b/Code/Mantid/Framework/API/test/MatrixWorkspaceTest.h index 7adbce1fc6d1..38aedd753411 100644 --- a/Code/Mantid/Framework/API/test/MatrixWorkspaceTest.h +++ b/Code/Mantid/Framework/API/test/MatrixWorkspaceTest.h @@ -760,7 +760,7 @@ class MatrixWorkspaceTest : public CxxTest::TestSuite void test_getSpecialCoordinateSystem_default() { WorkspaceTester ws; - TSM_ASSERT_EQUALS("Should default to no special coordinate system.", Mantid::API::None, ws.getSpecialCoordinateSystem()); + TSM_ASSERT_EQUALS("Should default to no special coordinate system.", Mantid::Kernel::None, ws.getSpecialCoordinateSystem()); } void test_getFirstPulseTime_getLastPulseTime() diff --git a/Code/Mantid/Framework/API/test/MockObjects.h b/Code/Mantid/Framework/API/test/MockObjects.h index b2bf6c65312a..ed5d1d698e8c 100644 --- a/Code/Mantid/Framework/API/test/MockObjects.h +++ b/Code/Mantid/Framework/API/test/MockObjects.h @@ -39,7 +39,7 @@ namespace MOCK_CONST_METHOD1(transform, Mantid::Kernel::V3D(const Mantid::Kernel::V3D&)); MOCK_CONST_METHOD1(transformPeak, Mantid::Kernel::V3D(const Mantid::API::IPeak&)); MOCK_CONST_METHOD0(getFriendlyName, std::string()); - MOCK_CONST_METHOD0(getCoordinateSystem, Mantid::API::SpecialCoordinateSystem()); + MOCK_CONST_METHOD0(getCoordinateSystem, Mantid::Kernel::SpecialCoordinateSystem()); }; /*------------------------------------------------------------ diff --git a/Code/Mantid/Framework/API/test/PeakTransformHKLTest.h b/Code/Mantid/Framework/API/test/PeakTransformHKLTest.h index 2fa52be43c96..f726f3355326 100644 --- a/Code/Mantid/Framework/API/test/PeakTransformHKLTest.h +++ b/Code/Mantid/Framework/API/test/PeakTransformHKLTest.h @@ -273,7 +273,7 @@ void test_getFriendlyName() void test_getCoordinateSystem() { PeakTransformHKL transform; - TS_ASSERT_EQUALS(Mantid::API::HKL, transform.getCoordinateSystem()) + TS_ASSERT_EQUALS(Mantid::Kernel::HKL, transform.getCoordinateSystem()) } }; diff --git a/Code/Mantid/Framework/API/test/PeakTransformQLabTest.h b/Code/Mantid/Framework/API/test/PeakTransformQLabTest.h index 58cc9e5501da..b3184387f832 100644 --- a/Code/Mantid/Framework/API/test/PeakTransformQLabTest.h +++ b/Code/Mantid/Framework/API/test/PeakTransformQLabTest.h @@ -207,7 +207,7 @@ void test_getFriendlyName() void test_getCoordinateSystem() { PeakTransformQLab transform; - TS_ASSERT_EQUALS(Mantid::API::QLab, transform.getCoordinateSystem()) + TS_ASSERT_EQUALS(Mantid::Kernel::QLab, transform.getCoordinateSystem()) } diff --git a/Code/Mantid/Framework/API/test/PeakTransformQSampleTest.h b/Code/Mantid/Framework/API/test/PeakTransformQSampleTest.h index 8ef656966bcd..f3d01c140557 100644 --- a/Code/Mantid/Framework/API/test/PeakTransformQSampleTest.h +++ b/Code/Mantid/Framework/API/test/PeakTransformQSampleTest.h @@ -207,7 +207,7 @@ void test_getFriendlyName() void test_getCoordinateSystem() { PeakTransformQSample transform; - TS_ASSERT_EQUALS(Mantid::API::QSample, transform.getCoordinateSystem()) + TS_ASSERT_EQUALS(Mantid::Kernel::QSample, transform.getCoordinateSystem()) } }; diff --git a/Code/Mantid/Framework/Algorithms/test/RebinByTimeBaseTest.h b/Code/Mantid/Framework/Algorithms/test/RebinByTimeBaseTest.h index e3c1c3e6d030..30d2835542d2 100644 --- a/Code/Mantid/Framework/Algorithms/test/RebinByTimeBaseTest.h +++ b/Code/Mantid/Framework/Algorithms/test/RebinByTimeBaseTest.h @@ -88,7 +88,7 @@ namespace MOCK_METHOD1(getSpectrum, Mantid::API::ISpectrum*(const std::size_t)); MOCK_CONST_METHOD1(getSpectrum, const Mantid::API::ISpectrum*(const std::size_t)); MOCK_METHOD3(init, void(const size_t&, const size_t&, const size_t&)); - MOCK_CONST_METHOD0(getSpecialCoordinateSystem, Mantid::API::SpecialCoordinateSystem()); + MOCK_CONST_METHOD0(getSpecialCoordinateSystem, Mantid::Kernel::SpecialCoordinateSystem()); virtual ~MockIEventWorkspace() {} };} diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakBackground.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakBackground.h index 3e83cfb51185..c25e7dcc33fb 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakBackground.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakBackground.h @@ -49,7 +49,7 @@ class DLLExport PeakBackground : public HardThresholdBackground { /// Radius estimate double m_radiusEstimate; /// MD coordinates to use - Mantid::API::SpecialCoordinateSystem m_mdCoordinates; + Mantid::Kernel::SpecialCoordinateSystem m_mdCoordinates; /// Pointer to member function used for coordinate determination. boost::function m_coordFunction; @@ -59,7 +59,7 @@ class DLLExport PeakBackground : public HardThresholdBackground { PeakBackground(Mantid::API::IPeaksWorkspace_const_sptr peaksWS, const double &radiusEstimate, const double &thresholdSignal, const Mantid::API::MDNormalization normalisation, - const Mantid::API::SpecialCoordinateSystem coordinates); + const Mantid::Kernel::SpecialCoordinateSystem coordinates); /// Copy constructor PeakBackground(const PeakBackground &other); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetSpecialCoordinates.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetSpecialCoordinates.h index 96222c13cfa7..0755e6e343a8 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetSpecialCoordinates.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetSpecialCoordinates.h @@ -55,7 +55,7 @@ class DLLExport SetSpecialCoordinates : public API::Algorithm { void init(); void exec(); std::vector m_specialCoordinatesNames; - typedef std::map + typedef std::map SpecialCoordinatesNameMap; SpecialCoordinatesNameMap m_specialCoordinatesMap; static const std::string QLabOption(); @@ -63,13 +63,13 @@ class DLLExport SetSpecialCoordinates : public API::Algorithm { static const std::string HKLOption(); bool writeCoordinatesToMDEventWorkspace( Mantid::API::Workspace_sptr inWS, - Mantid::API::SpecialCoordinateSystem coordinateSystem); + Mantid::Kernel::SpecialCoordinateSystem coordinateSystem); bool writeCoordinatesToMDHistoWorkspace( Mantid::API::Workspace_sptr inWS, - Mantid::API::SpecialCoordinateSystem coordinateSystem); + Mantid::Kernel::SpecialCoordinateSystem coordinateSystem); bool writeCoordinatesToPeaksWorkspace( Mantid::API::Workspace_sptr inWS, - Mantid::API::SpecialCoordinateSystem coordinateSystem); + Mantid::Kernel::SpecialCoordinateSystem coordinateSystem); }; } // namespace Crystal diff --git a/Code/Mantid/Framework/Crystal/src/PeakBackground.cpp b/Code/Mantid/Framework/Crystal/src/PeakBackground.cpp index e6bacbcaa161..725e99110066 100644 --- a/Code/Mantid/Framework/Crystal/src/PeakBackground.cpp +++ b/Code/Mantid/Framework/Crystal/src/PeakBackground.cpp @@ -26,7 +26,7 @@ PeakBackground::PeakBackground(IPeaksWorkspace_const_sptr peaksWS, m_coordFunction = &IPeak::getQLabFrame; } else if (m_mdCoordinates == QSample) { m_coordFunction = &IPeak::getQSampleFrame; - } else if (m_mdCoordinates == Mantid::API::HKL) { + } else if (m_mdCoordinates == Mantid::Kernel::HKL) { m_coordFunction = &IPeak::getHKL; } else { throw std::invalid_argument( diff --git a/Code/Mantid/Framework/Crystal/src/PeakClusterProjection.cpp b/Code/Mantid/Framework/Crystal/src/PeakClusterProjection.cpp index b83bb5b27ea1..ddc8c2cc7e55 100644 --- a/Code/Mantid/Framework/Crystal/src/PeakClusterProjection.cpp +++ b/Code/Mantid/Framework/Crystal/src/PeakClusterProjection.cpp @@ -28,7 +28,7 @@ PeakTransform_sptr makePeakTransform(IMDWorkspace const *const mdWS) { peakTransformFactory = boost::make_shared(); } else if (mdCoordinates == QSample) { peakTransformFactory = boost::make_shared(); - } else if (mdCoordinates == Mantid::API::HKL) { + } else if (mdCoordinates == Mantid::Kernel::HKL) { peakTransformFactory = boost::make_shared(); } const std::string xDim = mdWS->getDimension(0)->getName(); diff --git a/Code/Mantid/Framework/Crystal/src/SetSpecialCoordinates.cpp b/Code/Mantid/Framework/Crystal/src/SetSpecialCoordinates.cpp index 7e4e3288490b..784d7244d529 100644 --- a/Code/Mantid/Framework/Crystal/src/SetSpecialCoordinates.cpp +++ b/Code/Mantid/Framework/Crystal/src/SetSpecialCoordinates.cpp @@ -40,11 +40,11 @@ SetSpecialCoordinates::SetSpecialCoordinates() { m_specialCoordinatesNames.push_back(SetSpecialCoordinates::HKLOption()); m_specialCoordinatesMap.insert( - std::make_pair(SetSpecialCoordinates::QLabOption(), Mantid::API::QLab)); + std::make_pair(SetSpecialCoordinates::QLabOption(), Mantid::Kernel::QLab)); m_specialCoordinatesMap.insert(std::make_pair( - SetSpecialCoordinates::QSampleOption(), Mantid::API::QSample)); + SetSpecialCoordinates::QSampleOption(), Mantid::Kernel::QSample)); m_specialCoordinatesMap.insert( - std::make_pair(SetSpecialCoordinates::HKLOption(), Mantid::API::HKL)); + std::make_pair(SetSpecialCoordinates::HKLOption(), Mantid::Kernel::HKL)); } //---------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/Crystal/test/FindClusterFacesTest.h b/Code/Mantid/Framework/Crystal/test/FindClusterFacesTest.h index 3a1685ebab2b..a009c35ea4b3 100644 --- a/Code/Mantid/Framework/Crystal/test/FindClusterFacesTest.h +++ b/Code/Mantid/Framework/Crystal/test/FindClusterFacesTest.h @@ -25,7 +25,7 @@ namespace IPeaksWorkspace_sptr create_peaks_WS(Instrument_sptr inst) { PeaksWorkspace* pPeaksWS = new PeaksWorkspace(); - pPeaksWS->setCoordinateSystem(Mantid::API::HKL); + pPeaksWS->setCoordinateSystem(Mantid::Kernel::HKL); IPeaksWorkspace_sptr peakWS(pPeaksWS); peakWS->setInstrument(inst); return peakWS; diff --git a/Code/Mantid/Framework/Crystal/test/PeakBackgroundTest.h b/Code/Mantid/Framework/Crystal/test/PeakBackgroundTest.h index 0ac2b7bb5acc..4d81d55d1210 100644 --- a/Code/Mantid/Framework/Crystal/test/PeakBackgroundTest.h +++ b/Code/Mantid/Framework/Crystal/test/PeakBackgroundTest.h @@ -98,7 +98,7 @@ class PeakBackgroundTest : public CxxTest::TestSuite IPeaksWorkspace_const_sptr peaksWS = make_peaks_workspace(hklPeak); const double radius = 1; const double threshold = 100; - PeakBackground strategy(peaksWS, radius, threshold, NoNormalization, Mantid::API::HKL); + PeakBackground strategy(peaksWS, radius, threshold, NoNormalization, Mantid::Kernel::HKL); MockIMDIterator mockIterator; EXPECT_CALL(mockIterator, getNormalizedSignal()).WillOnce(Return(threshold+1)); // Returns above the threshold. @@ -115,7 +115,7 @@ class PeakBackgroundTest : public CxxTest::TestSuite IPeaksWorkspace_const_sptr peaksWS = make_peaks_workspace(hklPeak); const double radius = 1; const double threshold = 100; - PeakBackground strategy(peaksWS, radius, threshold, NoNormalization, Mantid::API::HKL); + PeakBackground strategy(peaksWS, radius, threshold, NoNormalization, Mantid::Kernel::HKL); MockIMDIterator mockIterator; V3D iteratorCenter(hklPeak[0] + radius, hklPeak[1], hklPeak[2]); // Offset so to be outside of peak radius. @@ -133,7 +133,7 @@ class PeakBackgroundTest : public CxxTest::TestSuite IPeaksWorkspace_const_sptr peaksWS = make_peaks_workspace(hklPeak); const double radius = 1; const double threshold = 100; - PeakBackground strategy(peaksWS, radius, threshold, NoNormalization, Mantid::API::HKL); + PeakBackground strategy(peaksWS, radius, threshold, NoNormalization, Mantid::Kernel::HKL); MockIMDIterator mockIterator; V3D iteratorCenter(hklPeak[0] + radius - 1e-4, hklPeak[1], hklPeak[2]); // Offset so to be outside of peak radius. @@ -151,7 +151,7 @@ class PeakBackgroundTest : public CxxTest::TestSuite IPeaksWorkspace_const_sptr peaksWS = make_peaks_workspace(hklPeak); const double radius = 1; const double threshold = 100; - PeakBackground strategy(peaksWS, radius, threshold, NoNormalization, Mantid::API::HKL); + PeakBackground strategy(peaksWS, radius, threshold, NoNormalization, Mantid::Kernel::HKL); MockIMDIterator mockIterator; EXPECT_CALL(mockIterator, getNormalizedSignal()).WillOnce(Return(threshold)); // Returns equal to the threshold. Exclusive checking. diff --git a/Code/Mantid/Framework/Crystal/test/PeakClusterProjectionTest.h b/Code/Mantid/Framework/Crystal/test/PeakClusterProjectionTest.h index 0b3d7ac7108b..999e7d5e2075 100644 --- a/Code/Mantid/Framework/Crystal/test/PeakClusterProjectionTest.h +++ b/Code/Mantid/Framework/Crystal/test/PeakClusterProjectionTest.h @@ -33,7 +33,7 @@ class PeakClusterProjectionTest: public CxxTest::TestSuite IPeaksWorkspace_sptr create_peaks_WS(Instrument_sptr inst) const { PeaksWorkspace* pPeaksWS = new PeaksWorkspace(); - pPeaksWS->setCoordinateSystem(Mantid::API::HKL); + pPeaksWS->setCoordinateSystem(Mantid::Kernel::HKL); IPeaksWorkspace_sptr peakWS(pPeaksWS); peakWS->setInstrument(inst); return peakWS; @@ -98,7 +98,7 @@ class PeakClusterProjectionTest: public CxxTest::TestSuite void test_throws_if_mdws_has_no_coordinate_system() { IMDHistoWorkspace_sptr inWS = MDEventsTestHelper::makeFakeMDHistoWorkspace(1, 3, 1); - inWS->setCoordinateSystem(None); + inWS->setCoordinateSystem(Mantid::Kernel::None); TSM_ASSERT_THROWS("Must have a known coordinate system", PeakClusterProjection object(inWS), std::invalid_argument&); @@ -107,7 +107,7 @@ class PeakClusterProjectionTest: public CxxTest::TestSuite void test_throws_if_mdws_is_less_than_three_dimensional() { IMDHistoWorkspace_sptr inWS = MDEventsTestHelper::makeFakeMDHistoWorkspace(1, 2, 1); - inWS->setCoordinateSystem(Mantid::API::HKL); + inWS->setCoordinateSystem(Mantid::Kernel::HKL); TSM_ASSERT_THROWS("Must be +3 dimensional", PeakClusterProjection object(inWS), std::invalid_argument&); diff --git a/Code/Mantid/Framework/Crystal/test/SetSpecialCoordinatesTest.h b/Code/Mantid/Framework/Crystal/test/SetSpecialCoordinatesTest.h index 2d45736233fa..5f459b72303e 100644 --- a/Code/Mantid/Framework/Crystal/test/SetSpecialCoordinatesTest.h +++ b/Code/Mantid/Framework/Crystal/test/SetSpecialCoordinatesTest.h @@ -95,7 +95,7 @@ class SetSpecialCoordinatesTest: public CxxTest::TestSuite alg.execute(); auto outWS = AnalysisDataService::Instance().retrieveWS("inWS"); - TS_ASSERT_EQUALS(QSample, outWS->getSpecialCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::QSample, outWS->getSpecialCoordinateSystem()); AnalysisDataService::Instance().remove("inWS"); } @@ -112,7 +112,7 @@ class SetSpecialCoordinatesTest: public CxxTest::TestSuite alg.execute(); auto outWS = AnalysisDataService::Instance().retrieveWS("inWS"); - TS_ASSERT_EQUALS(QSample, outWS->getSpecialCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::QSample, outWS->getSpecialCoordinateSystem()); AnalysisDataService::Instance().remove("inWS"); } @@ -129,7 +129,7 @@ class SetSpecialCoordinatesTest: public CxxTest::TestSuite alg.execute(); auto outWS = AnalysisDataService::Instance().retrieveWS("inWS"); - TS_ASSERT_EQUALS(QSample, outWS->getSpecialCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::QSample, outWS->getSpecialCoordinateSystem()); AnalysisDataService::Instance().remove("inWS"); } diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/NoShape.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/NoShape.h index 98bde26c31d5..469661175dfc 100644 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/NoShape.h +++ b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/NoShape.h @@ -48,7 +48,7 @@ class DLLExport NoShape : public Mantid::Geometry::PeakShape { /// Return the shape name std::string shapeName() const; /// Get the coordinate frame - API::SpecialCoordinateSystem frame() const; + Kernel::SpecialCoordinateSystem frame() const; }; } // namespace DataObjects diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeBase.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeBase.h index ae8c0348970f..74a520487759 100644 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeBase.h +++ b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeBase.h @@ -3,7 +3,7 @@ #include "MantidKernel/System.h" #include "MantidGeometry/Crystal/PeakShape.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include namespace Json { @@ -41,13 +41,13 @@ class DLLExport PeakShapeBase : public Mantid::Geometry::PeakShape { public: /// Constructor - PeakShapeBase(API::SpecialCoordinateSystem frame, + PeakShapeBase(Kernel::SpecialCoordinateSystem frame, std::string algorithmName = std::string(), int algorithmVersion = -1); /// Destructor virtual ~PeakShapeBase(); /// Get the coordinate frame - API::SpecialCoordinateSystem frame() const; + Kernel::SpecialCoordinateSystem frame() const; /// Get the name of the algorithm used to make this shape std::string algorithmName() const; /// Get the version of the algorithm used to make this shape @@ -61,7 +61,7 @@ class DLLExport PeakShapeBase : public Mantid::Geometry::PeakShape { PeakShapeBase &operator=(const PeakShapeBase &other); /// Special coordinate system - Mantid::API::SpecialCoordinateSystem m_frame; + Mantid::Kernel::SpecialCoordinateSystem m_frame; /// Generating algorithm name std::string m_algorithmName; diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeEllipsoid.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeEllipsoid.h index 92b78662869f..f9d769181bc3 100644 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeEllipsoid.h +++ b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeEllipsoid.h @@ -37,7 +37,7 @@ namespace DataObjects { public: /// Constructor - PeakShapeEllipsoid(std::vector directions, std::vector abcRadius, std::vector abcBackgroundInnerRadius, std::vector abcBackgroundOuterRadius, API::SpecialCoordinateSystem frame, + PeakShapeEllipsoid(std::vector directions, std::vector abcRadius, std::vector abcBackgroundInnerRadius, std::vector abcBackgroundOuterRadius, Kernel::SpecialCoordinateSystem frame, std::string algorithmName = std::string(), int algorithmVersion = -1); /// Copy constructor diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeSpherical.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeSpherical.h index e09de9de58e7..fc9ce577a2e1 100644 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeSpherical.h +++ b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeakShapeSpherical.h @@ -3,7 +3,7 @@ #include "MantidKernel/System.h" #include "MantidDataObjects/PeakShapeBase.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include #include @@ -37,12 +37,12 @@ class DLLExport PeakShapeSpherical : public PeakShapeBase { public: /// Constructor PeakShapeSpherical(const double &peakRadius, - API::SpecialCoordinateSystem frame, + Kernel::SpecialCoordinateSystem frame, std::string algorithmName = std::string(), int algorithmVersion = -1); /// Constructor PeakShapeSpherical(const double &peakRadius, const double& peakInnerRadius, const double& peakOuterRadius, - API::SpecialCoordinateSystem frame, + Kernel::SpecialCoordinateSystem frame, std::string algorithmName = std::string(), int algorithmVersion = -1); /// Destructor diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeaksWorkspace.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeaksWorkspace.h index b42daa01547b..42cc58043f1b 100644 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeaksWorkspace.h +++ b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/PeaksWorkspace.h @@ -125,10 +125,10 @@ class DLLExport PeaksWorkspace : public Mantid::API::IPeaksWorkspace { /// Set the special coordinate system. virtual void setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem); + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem); /// Get the special coordinate system. - virtual Mantid::API::SpecialCoordinateSystem + virtual Mantid::Kernel::SpecialCoordinateSystem getSpecialCoordinateSystem() const; // ====================================== ITableWorkspace Methods diff --git a/Code/Mantid/Framework/DataObjects/src/NoShape.cpp b/Code/Mantid/Framework/DataObjects/src/NoShape.cpp index 4d9bccee692d..7250ffebbaa9 100644 --- a/Code/Mantid/Framework/DataObjects/src/NoShape.cpp +++ b/Code/Mantid/Framework/DataObjects/src/NoShape.cpp @@ -51,9 +51,9 @@ int NoShape::algorithmVersion() const */ std::string NoShape::shapeName() const { return "none"; } -API::SpecialCoordinateSystem NoShape::frame() const +Kernel::SpecialCoordinateSystem NoShape::frame() const { - return API::None; + return Kernel::None; } diff --git a/Code/Mantid/Framework/DataObjects/src/PeakShapeBase.cpp b/Code/Mantid/Framework/DataObjects/src/PeakShapeBase.cpp index eaf0a97a0681..c42c6efbe7ea 100644 --- a/Code/Mantid/Framework/DataObjects/src/PeakShapeBase.cpp +++ b/Code/Mantid/Framework/DataObjects/src/PeakShapeBase.cpp @@ -1,11 +1,11 @@ #include "MantidDataObjects/PeakShapeBase.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include namespace Mantid { namespace DataObjects { -PeakShapeBase::PeakShapeBase(API::SpecialCoordinateSystem frame, +PeakShapeBase::PeakShapeBase(Kernel::SpecialCoordinateSystem frame, std::string algorithmName, int algorithmVersion) : m_frame(frame), m_algorithmName(algorithmName), m_algorithmVersion(algorithmVersion) {} @@ -41,7 +41,7 @@ PeakShapeBase &PeakShapeBase::operator=(const PeakShapeBase &other) { * @brief PeakShapeBase::frame * @return The coordinate frame used */ -API::SpecialCoordinateSystem PeakShapeBase::frame() const { return m_frame; } +Kernel::SpecialCoordinateSystem PeakShapeBase::frame() const { return m_frame; } /** * @brief PeakShapeBase::buildCommon. Serialize to JSON object and return the diff --git a/Code/Mantid/Framework/DataObjects/src/PeakShapeEllipsoid.cpp b/Code/Mantid/Framework/DataObjects/src/PeakShapeEllipsoid.cpp index f3382e3cbbdd..6a3db09207e5 100644 --- a/Code/Mantid/Framework/DataObjects/src/PeakShapeEllipsoid.cpp +++ b/Code/Mantid/Framework/DataObjects/src/PeakShapeEllipsoid.cpp @@ -9,7 +9,7 @@ PeakShapeEllipsoid::PeakShapeEllipsoid( std::vector directions, std::vector abcRadii, std::vector abcRadiiBackgroundInner, std::vector abcRadiiBackgroundOuter, - API::SpecialCoordinateSystem frame, std::string algorithmName, + Kernel::SpecialCoordinateSystem frame, std::string algorithmName, int algorithmVersion) : PeakShapeBase(frame, algorithmName, algorithmVersion), m_directions(directions), m_abc_radii(abcRadii), diff --git a/Code/Mantid/Framework/DataObjects/src/PeakShapeEllipsoidFactory.cpp b/Code/Mantid/Framework/DataObjects/src/PeakShapeEllipsoidFactory.cpp index 367dc266885d..2d487feee536 100644 --- a/Code/Mantid/Framework/DataObjects/src/PeakShapeEllipsoidFactory.cpp +++ b/Code/Mantid/Framework/DataObjects/src/PeakShapeEllipsoidFactory.cpp @@ -1,12 +1,11 @@ #include "MantidDataObjects/PeakShapeEllipsoidFactory.h" #include "MantidDataObjects/PeakShapeEllipsoid.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include #include using namespace Mantid::Kernel; -using namespace Mantid::API; namespace Mantid { namespace DataObjects { diff --git a/Code/Mantid/Framework/DataObjects/src/PeakShapeSpherical.cpp b/Code/Mantid/Framework/DataObjects/src/PeakShapeSpherical.cpp index 84dfea6c7089..e483f4795f0e 100644 --- a/Code/Mantid/Framework/DataObjects/src/PeakShapeSpherical.cpp +++ b/Code/Mantid/Framework/DataObjects/src/PeakShapeSpherical.cpp @@ -13,7 +13,7 @@ namespace DataObjects { * @param algorithmVersion : Algorithm version used for the integration */ PeakShapeSpherical::PeakShapeSpherical(const double &peakRadius, - API::SpecialCoordinateSystem frame, + Kernel::SpecialCoordinateSystem frame, std::string algorithmName, int algorithmVersion) : PeakShapeBase(frame, algorithmName, algorithmVersion), @@ -31,7 +31,7 @@ PeakShapeSpherical::PeakShapeSpherical(const double &peakRadius, PeakShapeSpherical::PeakShapeSpherical(const double &peakRadius, const double &peakInnerRadius, const double &peakOuterRadius, - API::SpecialCoordinateSystem frame, + Kernel::SpecialCoordinateSystem frame, std::string algorithmName, int algorithmVersion) : PeakShapeBase(frame, algorithmName, algorithmVersion), diff --git a/Code/Mantid/Framework/DataObjects/src/PeakShapeSphericalFactory.cpp b/Code/Mantid/Framework/DataObjects/src/PeakShapeSphericalFactory.cpp index 410d0047c331..90793d601660 100644 --- a/Code/Mantid/Framework/DataObjects/src/PeakShapeSphericalFactory.cpp +++ b/Code/Mantid/Framework/DataObjects/src/PeakShapeSphericalFactory.cpp @@ -1,13 +1,13 @@ #include "MantidDataObjects/PeakShapeSphericalFactory.h" #include "MantidDataObjects/PeakShapeSpherical.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include #include namespace Mantid { namespace DataObjects { -using namespace Mantid::API; +using namespace Mantid::Kernel; //---------------------------------------------------------------------------------------------- /** Constructor diff --git a/Code/Mantid/Framework/DataObjects/src/PeaksWorkspace.cpp b/Code/Mantid/Framework/DataObjects/src/PeaksWorkspace.cpp index b21b887bed76..5258f57751e4 100644 --- a/Code/Mantid/Framework/DataObjects/src/PeaksWorkspace.cpp +++ b/Code/Mantid/Framework/DataObjects/src/PeaksWorkspace.cpp @@ -789,7 +789,7 @@ void PeaksWorkspace::saveNexus(::NeXus::File *file) const { * @param coordinateSystem : Option to set. */ void PeaksWorkspace::setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem) { + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem) { this->mutableRun().addProperty("CoordinateSystem", (int)coordinateSystem, true); } @@ -797,9 +797,9 @@ void PeaksWorkspace::setCoordinateSystem( /** * @return the special Q3D coordinate system. */ -Mantid::API::SpecialCoordinateSystem +Mantid::Kernel::SpecialCoordinateSystem PeaksWorkspace::getSpecialCoordinateSystem() const { - Mantid::API::SpecialCoordinateSystem result = None; + Mantid::Kernel::SpecialCoordinateSystem result = None; try { Property *prop = this->run().getProperty("CoordinateSystem"); PropertyWithValue *p = dynamic_cast *>(prop); diff --git a/Code/Mantid/Framework/DataObjects/test/MockObjects.h b/Code/Mantid/Framework/DataObjects/test/MockObjects.h index 7196112a3554..5c0f15917e65 100644 --- a/Code/Mantid/Framework/DataObjects/test/MockObjects.h +++ b/Code/Mantid/Framework/DataObjects/test/MockObjects.h @@ -2,6 +2,7 @@ #define MOCKOBJECTS_H_ #include +#include "MantidKernel/SpecialCoordinateSystem.h" #include "MantidDataObjects/PeakShapeFactory.h" #include "MantidGeometry/Crystal/PeakShape.h" @@ -22,7 +23,7 @@ class MockPeakShape : public Mantid::Geometry::PeakShape { public: - MOCK_CONST_METHOD0(frame, Mantid::API::SpecialCoordinateSystem() ); + MOCK_CONST_METHOD0(frame, Mantid::Kernel::SpecialCoordinateSystem() ); MOCK_CONST_METHOD0(toJSON, std::string() ); MOCK_CONST_METHOD0(clone, Mantid::Geometry::PeakShape*() ); MOCK_CONST_METHOD0(algorithmName, std::string() ); diff --git a/Code/Mantid/Framework/DataObjects/test/NoShapeTest.h b/Code/Mantid/Framework/DataObjects/test/NoShapeTest.h index d91fee99a950..e005dd877aef 100644 --- a/Code/Mantid/Framework/DataObjects/test/NoShapeTest.h +++ b/Code/Mantid/Framework/DataObjects/test/NoShapeTest.h @@ -9,9 +9,8 @@ #include #include "MantidDataObjects/NoShape.h" #include "MantidKernel/V3D.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" -using namespace Mantid::API; using namespace Mantid::Kernel; using Mantid::DataObjects::NoShape; @@ -28,7 +27,7 @@ class NoShapeTest : public CxxTest::TestSuite { NoShape shape; - TS_ASSERT_EQUALS(Mantid::API::None, shape.frame()); + TS_ASSERT_EQUALS(Mantid::Kernel::None, shape.frame()); TS_ASSERT_EQUALS(std::string(), shape.algorithmName()); TS_ASSERT_EQUALS(-1, shape.algorithmVersion()); } diff --git a/Code/Mantid/Framework/DataObjects/test/PeakShapeEllipsoidFactoryTest.h b/Code/Mantid/Framework/DataObjects/test/PeakShapeEllipsoidFactoryTest.h index 01fb151e500e..6f47715e5bac 100644 --- a/Code/Mantid/Framework/DataObjects/test/PeakShapeEllipsoidFactoryTest.h +++ b/Code/Mantid/Framework/DataObjects/test/PeakShapeEllipsoidFactoryTest.h @@ -13,7 +13,7 @@ #include "MantidDataObjects/PeakShapeEllipsoid.h" #include "MantidKernel/VMD.h" #include "MantidKernel/cow_ptr.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include "MockObjects.h" #include "MantidDataObjects/PeakShapeEllipsoidFactory.h" @@ -21,7 +21,6 @@ using namespace Mantid; using namespace Mantid::DataObjects; using namespace Mantid::Kernel; -using namespace Mantid::API; using namespace boost::assign; class PeakShapeEllipsoidFactoryTest : public CxxTest::TestSuite { diff --git a/Code/Mantid/Framework/DataObjects/test/PeakShapeEllipsoidTest.h b/Code/Mantid/Framework/DataObjects/test/PeakShapeEllipsoidTest.h index c5516525b4ff..fd54e13854a6 100644 --- a/Code/Mantid/Framework/DataObjects/test/PeakShapeEllipsoidTest.h +++ b/Code/Mantid/Framework/DataObjects/test/PeakShapeEllipsoidTest.h @@ -13,7 +13,6 @@ using Mantid::DataObjects::PeakShapeEllipsoid; using namespace Mantid; using namespace Mantid::Kernel; -using namespace Mantid::API; using namespace boost::assign; class PeakShapeEllipsoidTest : public CxxTest::TestSuite { diff --git a/Code/Mantid/Framework/DataObjects/test/PeakShapeSphericalFactoryTest.h b/Code/Mantid/Framework/DataObjects/test/PeakShapeSphericalFactoryTest.h index 003e6b724bf2..6b7a809f17bd 100644 --- a/Code/Mantid/Framework/DataObjects/test/PeakShapeSphericalFactoryTest.h +++ b/Code/Mantid/Framework/DataObjects/test/PeakShapeSphericalFactoryTest.h @@ -12,12 +12,11 @@ #include "MantidDataObjects/PeakShapeSphericalFactory.h" #include "MantidDataObjects/PeakShapeSpherical.h" #include "MantidKernel/VMD.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include "MockObjects.h" using namespace Mantid::DataObjects; using namespace Mantid::Kernel; -using namespace Mantid::API; class PeakShapeSphericalFactoryTest : public CxxTest::TestSuite { public: diff --git a/Code/Mantid/Framework/DataObjects/test/PeakShapeSphericalTest.h b/Code/Mantid/Framework/DataObjects/test/PeakShapeSphericalTest.h index cf2ea54759d6..ebf45627104a 100644 --- a/Code/Mantid/Framework/DataObjects/test/PeakShapeSphericalTest.h +++ b/Code/Mantid/Framework/DataObjects/test/PeakShapeSphericalTest.h @@ -10,10 +10,9 @@ #include "MantidDataObjects/PeakShapeSpherical.h" #include "MantidKernel/V3D.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" using Mantid::DataObjects::PeakShapeSpherical; -using namespace Mantid::API; using namespace Mantid::Kernel; class PeakShapeSphericalTest : public CxxTest::TestSuite { diff --git a/Code/Mantid/Framework/DataObjects/test/PeaksWorkspaceTest.h b/Code/Mantid/Framework/DataObjects/test/PeaksWorkspaceTest.h index d92630128b78..20d627c7d99e 100644 --- a/Code/Mantid/Framework/DataObjects/test/PeaksWorkspaceTest.h +++ b/Code/Mantid/Framework/DataObjects/test/PeaksWorkspaceTest.h @@ -355,7 +355,7 @@ class PeaksWorkspaceTest : public CxxTest::TestSuite void test_setSpecialCoordinates() { auto pw = PeaksWorkspace_sptr(new PeaksWorkspace); - SpecialCoordinateSystem coordSystem = Mantid::API::HKL; + SpecialCoordinateSystem coordSystem = Mantid::Kernel::HKL; pw->setCoordinateSystem(coordSystem); TS_ASSERT_EQUALS(coordSystem, pw->getSpecialCoordinateSystem()); } diff --git a/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Crystal/PeakShape.h b/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Crystal/PeakShape.h index 9f6d2470dea5..ab01fc0f6716 100644 --- a/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Crystal/PeakShape.h +++ b/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Crystal/PeakShape.h @@ -2,7 +2,7 @@ #define MANTID_GEOMETRY_PEAKSHAPE_H_ #include "MantidKernel/System.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include #include @@ -35,7 +35,7 @@ namespace Geometry { class DLLExport PeakShape { public: /// Coordinte frame used upon creation - virtual Mantid::API::SpecialCoordinateSystem frame() const = 0; + virtual Mantid::Kernel::SpecialCoordinateSystem frame() const = 0; /// Serialize virtual std::string toJSON() const = 0; /// Deep copy this diff --git a/Code/Mantid/Framework/Kernel/CMakeLists.txt b/Code/Mantid/Framework/Kernel/CMakeLists.txt index c9e242db1844..ae039d2ed796 100644 --- a/Code/Mantid/Framework/Kernel/CMakeLists.txt +++ b/Code/Mantid/Framework/Kernel/CMakeLists.txt @@ -214,6 +214,7 @@ set ( INC_FILES inc/MantidKernel/RemoteJobManager.h inc/MantidKernel/SingletonHolder.h inc/MantidKernel/SobolSequence.h + inc/MantidKernel/SpecialCoordinateSystem.h inc/MantidKernel/StartsWithValidator.h inc/MantidKernel/Statistics.h inc/MantidKernel/StdoutChannel.h @@ -327,7 +328,8 @@ set ( TEST_FILES RegexStringsTest.h SLSQPMinimizerTest.h SobolSequenceTest.h - StartsWithValidatorTest.h + SpecialCoordinateSystemTest.h + StartsWithValidatorTest.h StatisticsTest.h StdoutChannelTest.h StringsTest.h diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/SpecialCoordinateSystem.h b/Code/Mantid/Framework/Kernel/inc/MantidKernel/SpecialCoordinateSystem.h similarity index 59% rename from Code/Mantid/Framework/API/inc/MantidAPI/SpecialCoordinateSystem.h rename to Code/Mantid/Framework/Kernel/inc/MantidKernel/SpecialCoordinateSystem.h index ec7d1c9b83c6..74cc798b15f0 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/SpecialCoordinateSystem.h +++ b/Code/Mantid/Framework/Kernel/inc/MantidKernel/SpecialCoordinateSystem.h @@ -1,8 +1,8 @@ -#ifndef MANTID_MDALGORITHMS_SpecialCoordinateSystem_H_ -#define MANTID_MDALGORITHMS_SpecialCoordinateSystem_H_ +#ifndef MANTID_KERNEL_SpecialCoordinateSystem_H_ +#define MANTID_KERNEL_SpecialCoordinateSystem_H_ namespace Mantid { -namespace API { +namespace Kernel { /** * Special coordinate systems for Q3D. */ diff --git a/Code/Mantid/Framework/API/test/SpecialCoordinateSystemTest.h b/Code/Mantid/Framework/Kernel/test/SpecialCoordinateSystemTest.h similarity index 88% rename from Code/Mantid/Framework/API/test/SpecialCoordinateSystemTest.h rename to Code/Mantid/Framework/Kernel/test/SpecialCoordinateSystemTest.h index d6f315645392..fb53a62b1a62 100644 --- a/Code/Mantid/Framework/API/test/SpecialCoordinateSystemTest.h +++ b/Code/Mantid/Framework/Kernel/test/SpecialCoordinateSystemTest.h @@ -1,10 +1,10 @@ -#ifndef MANTID_API_SPECIALCOORDINATESYSTEMTEST -#define MANTID_API_SPECIALCOORDINATESYSTEMTEST +#ifndef MANTID_KERNEL_SPECIALCOORDINATESYSTEMTEST +#define MANTID_KERNEL_SPECIALCOORDINATESYSTEMTEST #include -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" -using namespace Mantid::API; +using namespace Mantid::Kernel; /* * We are testing the enum because the order of the elements in the enum is critical. There are various places in the codebase where the diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD2.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD2.h index 1bd10f52c63d..016900ec1469 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD2.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD2.h @@ -56,7 +56,7 @@ class DLLExport IntegratePeaksMD2 : public API::Algorithm { /// Check if peaks overlap void checkOverlap(int i, Mantid::DataObjects::PeaksWorkspace_sptr peakWS, - Mantid::API::SpecialCoordinateSystem CoordinatesToUse, double radius); + Mantid::Kernel::SpecialCoordinateSystem CoordinatesToUse, double radius); }; } // namespace Mantid diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp index 59144712a384..20fafa6debfb 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp @@ -364,7 +364,7 @@ void ConvertToDiffractionMDWorkspace::exec() { std::string dimensionNames[3] = {"Q_lab_x", "Q_lab_y", "Q_lab_z"}; std::string dimensionUnits = "Angstroms^-1"; - Mantid::API::SpecialCoordinateSystem coordinateSystem = Mantid::API::QLab; + Mantid::Kernel::SpecialCoordinateSystem coordinateSystem = Mantid::Kernel::QLab; if (OutputDimensions == "Q (sample frame)") { // Set the matrix based on goniometer angles mat = m_inWS->mutableRun().getGoniometerMatrix(); @@ -374,7 +374,7 @@ void ConvertToDiffractionMDWorkspace::exec() { dimensionNames[0] = "Q_sample_x"; dimensionNames[1] = "Q_sample_y"; dimensionNames[2] = "Q_sample_z"; - coordinateSystem = Mantid::API::QSample; + coordinateSystem = Mantid::Kernel::QSample; } else if (OutputDimensions == "HKL") { // Set the matrix based on UB etc. Kernel::Matrix ub = @@ -391,7 +391,7 @@ void ConvertToDiffractionMDWorkspace::exec() { dimensionNames[1] = "K"; dimensionNames[2] = "L"; dimensionUnits = "lattice"; - coordinateSystem = Mantid::API::HKL; + coordinateSystem = Mantid::Kernel::HKL; } // Q in the lab frame is the default, so nothing special to do. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp index be6af459f453..e1980adb910d 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp @@ -168,17 +168,17 @@ void IntegratePeaksMD::integrate(typename MDEventWorkspace::sptr ws) { /// Value of the CoordinatesToUse property. std::string CoordinatesToUseStr = getPropertyValue("CoordinatesToUse"); - API::SpecialCoordinateSystem CoordinatesToUse = ws->getSpecialCoordinateSystem(); + Kernel::SpecialCoordinateSystem CoordinatesToUse = ws->getSpecialCoordinateSystem(); g_log.warning() << " Warning" << CoordinatesToUse << std::endl; - if (CoordinatesToUse == API::QLab && CoordinatesToUseStr != "Q (lab frame)") + if (CoordinatesToUse == Kernel::QLab && CoordinatesToUseStr != "Q (lab frame)") g_log.warning() << "Warning: used Q (lab frame) coordinates for MD " "workspace, not CoordinatesToUse from input " << std::endl; - else if (CoordinatesToUse == API::QSample && CoordinatesToUseStr != "Q (sample frame)") + else if (CoordinatesToUse == Kernel::QSample && CoordinatesToUseStr != "Q (sample frame)") g_log.warning() << "Warning: used Q (sample frame) coordinates for MD " "workspace, not CoordinatesToUse from input " << std::endl; - else if (CoordinatesToUse == API::HKL && CoordinatesToUseStr != "HKL") + else if (CoordinatesToUse == Kernel::HKL && CoordinatesToUseStr != "HKL") g_log.warning() << "Warning: used HKL coordinates for MD workspace, not " "CoordinatesToUse from input " << std::endl; @@ -277,11 +277,11 @@ void IntegratePeaksMD::integrate(typename MDEventWorkspace::sptr ws) { // Get the peak center as a position in the dimensions of the workspace V3D pos; - if (CoordinatesToUse == API::QLab) //"Q (lab frame)" + if (CoordinatesToUse == Kernel::QLab) //"Q (lab frame)" pos = p.getQLabFrame(); - else if (CoordinatesToUse == API::QSample) //"Q (sample frame)" + else if (CoordinatesToUse == Kernel::QSample) //"Q (sample frame)" pos = p.getQSampleFrame(); - else if (CoordinatesToUse == API::HKL) //"HKL" + else if (CoordinatesToUse == Kernel::HKL) //"HKL" pos = p.getHKL(); // Get the instrument and its detectors diff --git a/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD2.cpp b/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD2.cpp index dd963ded0e7c..f0b7abc0f378 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD2.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD2.cpp @@ -174,7 +174,7 @@ void IntegratePeaksMD2::integrate(typename MDEventWorkspace::sptr ws) { // Get the instrument and its detectors inst = peakWS->getInstrument(); - Mantid::API::SpecialCoordinateSystem CoordinatesToUse = ws->getSpecialCoordinateSystem(); + Mantid::Kernel::SpecialCoordinateSystem CoordinatesToUse = ws->getSpecialCoordinateSystem(); /// Radius to use around peaks double PeakRadius = getProperty("PeakRadius"); @@ -271,11 +271,11 @@ void IntegratePeaksMD2::integrate(typename MDEventWorkspace::sptr ws) { // Get the peak center as a position in the dimensions of the workspace V3D pos; - if (CoordinatesToUse == Mantid::API::QLab) //"Q (lab frame)" + if (CoordinatesToUse == Mantid::Kernel::QLab) //"Q (lab frame)" pos = p.getQLabFrame(); - else if (CoordinatesToUse == Mantid::API::QSample) //"Q (sample frame)" + else if (CoordinatesToUse == Mantid::Kernel::QSample) //"Q (sample frame)" pos = p.getQSampleFrame(); - else if (CoordinatesToUse == Mantid::API::HKL) //"HKL" + else if (CoordinatesToUse == Mantid::Kernel::HKL) //"HKL" pos = p.getHKL(); // Do not integrate if sphere is off edge of detector @@ -686,25 +686,25 @@ void IntegratePeaksMD2::runMaskDetectors( void IntegratePeaksMD2::checkOverlap(int i, Mantid::DataObjects::PeaksWorkspace_sptr peakWS, - Mantid::API::SpecialCoordinateSystem CoordinatesToUse, double radius) { + Mantid::Kernel::SpecialCoordinateSystem CoordinatesToUse, double radius) { // Get a direct ref to that peak. IPeak &p1 = peakWS->getPeak(i); V3D pos1; - if (CoordinatesToUse == API::QLab) //"Q (lab frame)" + if (CoordinatesToUse == Kernel::QLab) //"Q (lab frame)" pos1 = p1.getQLabFrame(); - else if (CoordinatesToUse == API::QSample) //"Q (sample frame)" + else if (CoordinatesToUse == Kernel::QSample) //"Q (sample frame)" pos1 = p1.getQSampleFrame(); - else if (CoordinatesToUse == API::HKL) //"HKL" + else if (CoordinatesToUse == Kernel::HKL) //"HKL" pos1 = p1.getHKL(); for (int j = i + 1; j < peakWS->getNumberPeaks(); ++j) { // Get a direct ref to rest of peaks peak. IPeak &p2 = peakWS->getPeak(j); V3D pos2; - if (CoordinatesToUse == API::QLab) //"Q (lab frame)" + if (CoordinatesToUse == Kernel::QLab) //"Q (lab frame)" pos2 = p2.getQLabFrame(); - else if (CoordinatesToUse == API::QSample) //"Q (sample frame)" + else if (CoordinatesToUse == Kernel::QSample) //"Q (sample frame)" pos2 = p2.getQSampleFrame(); - else if (CoordinatesToUse == API::HKL) //"HKL" + else if (CoordinatesToUse == Kernel::HKL) //"HKL" pos2 = p2.getHKL(); if (pos1.distance(pos2) < radius) { g_log.warning() << " Warning: Peak integration spheres for peaks " << i diff --git a/Code/Mantid/Framework/MDAlgorithms/test/CentroidPeaksMD2Test.h b/Code/Mantid/Framework/MDAlgorithms/test/CentroidPeaksMD2Test.h index ada885d65317..31584d4caf27 100644 --- a/Code/Mantid/Framework/MDAlgorithms/test/CentroidPeaksMD2Test.h +++ b/Code/Mantid/Framework/MDAlgorithms/test/CentroidPeaksMD2Test.h @@ -158,18 +158,18 @@ class CentroidPeaksMD2Test : public CxxTest::TestSuite if (CoordinatesToUse == "HKL") { - mdews->setCoordinateSystem(Mantid::API::HKL); + mdews->setCoordinateSystem(Mantid::Kernel::HKL); doRun(V3D( 0.,0.,0.), 1.0, V3D( 0.,0.,0.), "Start at the center, get the center"); doRun(V3D( 0.2,0.2,0.2), 1.8, V3D( 0.,0.,0.), "Somewhat off center"); } else if (CoordinatesToUse == "Q (lab frame)") { - mdews->setCoordinateSystem(Mantid::API::QLab); + mdews->setCoordinateSystem(Mantid::Kernel::QLab); } else if (CoordinatesToUse == "Q (sample frame)") { - mdews->setCoordinateSystem(Mantid::API::QSample); + mdews->setCoordinateSystem(Mantid::Kernel::QSample); } doRun(V3D( 2.,3.,4.), 1.0, V3D( 2.,3.,4.), "Start at the center, get the center"); diff --git a/Code/Mantid/Framework/MDAlgorithms/test/CentroidPeaksMDTest.h b/Code/Mantid/Framework/MDAlgorithms/test/CentroidPeaksMDTest.h index 44e18fd89119..4e7338b07bdd 100644 --- a/Code/Mantid/Framework/MDAlgorithms/test/CentroidPeaksMDTest.h +++ b/Code/Mantid/Framework/MDAlgorithms/test/CentroidPeaksMDTest.h @@ -158,18 +158,18 @@ class CentroidPeaksMDTest : public CxxTest::TestSuite if (CoordinatesToUse == "HKL") { - mdews->setCoordinateSystem(Mantid::API::HKL); + mdews->setCoordinateSystem(Mantid::Kernel::HKL); doRun(V3D( 0.,0.,0.), 1.0, V3D( 0.,0.,0.), "Start at the center, get the center"); doRun(V3D( 0.2,0.2,0.2), 1.8, V3D( 0.,0.,0.), "Somewhat off center"); } else if (CoordinatesToUse == "Q (lab frame)") { - mdews->setCoordinateSystem(Mantid::API::QLab); + mdews->setCoordinateSystem(Mantid::Kernel::QLab); } else if (CoordinatesToUse == "Q (sample frame)") { - mdews->setCoordinateSystem(Mantid::API::QSample); + mdews->setCoordinateSystem(Mantid::Kernel::QSample); } doRun(V3D( 2.,3.,4.), 1.0, V3D( 2.,3.,4.), "Start at the center, get the center"); diff --git a/Code/Mantid/Framework/MDAlgorithms/test/ConvertToDiffractionMDWorkspace2Test.h b/Code/Mantid/Framework/MDAlgorithms/test/ConvertToDiffractionMDWorkspace2Test.h index 200c32167f8d..0a4ddc7f678d 100644 --- a/Code/Mantid/Framework/MDAlgorithms/test/ConvertToDiffractionMDWorkspace2Test.h +++ b/Code/Mantid/Framework/MDAlgorithms/test/ConvertToDiffractionMDWorkspace2Test.h @@ -52,7 +52,7 @@ class ConvertToDiffractionMDWorkspace2Test : public CxxTest::TestSuite TS_ASSERT(ws); if (!ws) return; TS_ASSERT_EQUALS( ws->getDimension(0)->getName(), "Q_lab_x"); - TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::API::QLab); + TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::Kernel::QLab); //TODO: Now you can add differenc dimension types to each other, but this should be fixed alg = FrameworkManager::Instance().exec("ConvertToDiffractionMDWorkspace", 8, @@ -83,7 +83,7 @@ class ConvertToDiffractionMDWorkspace2Test : public CxxTest::TestSuite TS_ASSERT(ws); if (!ws) return; TS_ASSERT_EQUALS( ws->getDimension(0)->getName(), "[H,0,0]"); - TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::API::HKL); + TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::Kernel::HKL); AnalysisDataService::Instance().remove("testOutMD"); alg = FrameworkManager::Instance().exec("ConvertToDiffractionMDWorkspace", 6, @@ -97,7 +97,7 @@ class ConvertToDiffractionMDWorkspace2Test : public CxxTest::TestSuite TS_ASSERT(ws); if (!ws) return; TS_ASSERT_EQUALS( ws->getDimension(0)->getName(), "Q_sample_x"); - TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::API::QSample); + TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::Kernel::QSample); } void do_test_MINITOPAZ(EventType type, size_t numTimesToAdd = 1, diff --git a/Code/Mantid/Framework/MDAlgorithms/test/ConvertToDiffractionMDWorkspaceTest.h b/Code/Mantid/Framework/MDAlgorithms/test/ConvertToDiffractionMDWorkspaceTest.h index ec208fa77466..99103b2d68fd 100644 --- a/Code/Mantid/Framework/MDAlgorithms/test/ConvertToDiffractionMDWorkspaceTest.h +++ b/Code/Mantid/Framework/MDAlgorithms/test/ConvertToDiffractionMDWorkspaceTest.h @@ -50,7 +50,7 @@ class ConvertToDiffractionMDWorkspaceTest : public CxxTest::TestSuite TS_ASSERT(ws); if (!ws) return; TS_ASSERT_EQUALS( ws->getDimension(0)->getName(), "Q_lab_x"); - TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::API::QLab); + TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::Kernel::QLab); // But you can't add to an existing one of the wrong dimensions type, if you choose Append alg = FrameworkManager::Instance().exec("ConvertToDiffractionMDWorkspace", @@ -81,7 +81,7 @@ class ConvertToDiffractionMDWorkspaceTest : public CxxTest::TestSuite TS_ASSERT(ws); if (!ws) return; TS_ASSERT_EQUALS( ws->getDimension(0)->getName(), "H"); - TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::API::HKL); + TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::Kernel::HKL); AnalysisDataService::Instance().remove("testOutMD"); alg = FrameworkManager::Instance().exec("ConvertToDiffractionMDWorkspace", @@ -95,7 +95,7 @@ class ConvertToDiffractionMDWorkspaceTest : public CxxTest::TestSuite TS_ASSERT(ws); if (!ws) return; TS_ASSERT_EQUALS( ws->getDimension(0)->getName(), "Q_sample_x"); - TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::API::QSample); + TS_ASSERT_EQUALS( ws->getSpecialCoordinateSystem(), Mantid::Kernel::QSample); } void do_test_MINITOPAZ(EventType type, size_t numTimesToAdd = 1, diff --git a/Code/Mantid/Framework/MDAlgorithms/test/ConvertToMDTest.h b/Code/Mantid/Framework/MDAlgorithms/test/ConvertToMDTest.h index 85a3fc70baeb..672f8bf1ba3e 100644 --- a/Code/Mantid/Framework/MDAlgorithms/test/ConvertToMDTest.h +++ b/Code/Mantid/Framework/MDAlgorithms/test/ConvertToMDTest.h @@ -109,7 +109,7 @@ void testExecNoQ() checkHistogramsHaveBeenStored("WS3DNoQ"); auto outWS = AnalysisDataService::Instance().retrieveWS("WS3DNoQ"); - TS_ASSERT_EQUALS(Mantid::API::None, outWS->getSpecialCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::None, outWS->getSpecialCoordinateSystem()); AnalysisDataService::Instance().remove("WS3DNoQ"); } @@ -137,7 +137,7 @@ void testExecModQ() checkHistogramsHaveBeenStored("WS3DmodQ",7000,6489.5591101441796,7300.7539989122024); auto outWS = AnalysisDataService::Instance().retrieveWS("WS3DmodQ"); - TS_ASSERT_EQUALS(Mantid::API::None, outWS->getSpecialCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::None, outWS->getSpecialCoordinateSystem()); AnalysisDataService::Instance().remove("WS3DmodQ"); } @@ -166,7 +166,7 @@ void testExecQ3D() checkHistogramsHaveBeenStored("WS5DQ3D"); auto outWS = AnalysisDataService::Instance().retrieveWS("WS5DQ3D"); - TS_ASSERT_EQUALS(Mantid::API::HKL, outWS->getSpecialCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::HKL, outWS->getSpecialCoordinateSystem()); AnalysisDataService::Instance().remove("WS5DQ3D"); } diff --git a/Code/Mantid/Framework/MDAlgorithms/test/IntegratePeaksMD2Test.h b/Code/Mantid/Framework/MDAlgorithms/test/IntegratePeaksMD2Test.h index 5f4dd4555d5a..fa6a6d32befc 100644 --- a/Code/Mantid/Framework/MDAlgorithms/test/IntegratePeaksMD2Test.h +++ b/Code/Mantid/Framework/MDAlgorithms/test/IntegratePeaksMD2Test.h @@ -133,7 +133,7 @@ class IntegratePeaksMD2Test : public CxxTest::TestSuite MDEventWorkspace3Lean::sptr mdews = AnalysisDataService::Instance().retrieveWS("IntegratePeaksMD2Test_MDEWS"); - mdews->setCoordinateSystem(Mantid::API::HKL); + mdews->setCoordinateSystem(Mantid::Kernel::HKL); TS_ASSERT_EQUALS( mdews->getNPoints(), 3000); TS_ASSERT_DELTA( mdews->getBox()->getSignal(), 3000.0, 1e-2); @@ -429,7 +429,7 @@ class IntegratePeaksMD2TestPerformance : public CxxTest::TestSuite MDEventWorkspace3Lean::sptr mdews = AnalysisDataService::Instance().retrieveWS("IntegratePeaksMD2Test_MDEWS"); - mdews->setCoordinateSystem(Mantid::API::HKL); + mdews->setCoordinateSystem(Mantid::Kernel::HKL); // Make a fake instrument - doesn't matter, we won't use it really diff --git a/Code/Mantid/Framework/MDAlgorithms/test/IntegratePeaksMDTest.h b/Code/Mantid/Framework/MDAlgorithms/test/IntegratePeaksMDTest.h index ff7c903353fc..d9fb8208c5fa 100644 --- a/Code/Mantid/Framework/MDAlgorithms/test/IntegratePeaksMDTest.h +++ b/Code/Mantid/Framework/MDAlgorithms/test/IntegratePeaksMDTest.h @@ -132,7 +132,7 @@ class IntegratePeaksMDTest : public CxxTest::TestSuite MDEventWorkspace3Lean::sptr mdews = AnalysisDataService::Instance().retrieveWS("IntegratePeaksMDTest_MDEWS"); - mdews->setCoordinateSystem(Mantid::API::HKL); + mdews->setCoordinateSystem(Mantid::Kernel::HKL); TS_ASSERT_EQUALS( mdews->getNPoints(), 3000); TS_ASSERT_DELTA( mdews->getBox()->getSignal(), 3000.0, 1e-2); @@ -417,7 +417,7 @@ class IntegratePeaksMDTestPerformance : public CxxTest::TestSuite MDEventWorkspace3Lean::sptr mdews = AnalysisDataService::Instance().retrieveWS("IntegratePeaksMDTest_MDEWS"); - mdews->setCoordinateSystem(Mantid::API::HKL); + mdews->setCoordinateSystem(Mantid::Kernel::HKL); // Make a fake instrument - doesn't matter, we won't use it really diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ConvToMDBase.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ConvToMDBase.h index f5a460acf87f..eb8328a5f534 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ConvToMDBase.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ConvToMDBase.h @@ -107,7 +107,7 @@ class DLLExport ConvToMDBase { // Flag which indicates that data with 0 signal should be ignored bool m_ignoreZeros; /// Any special coordinate system used. - Mantid::API::SpecialCoordinateSystem m_coordinateSystem; + Mantid::Kernel::SpecialCoordinateSystem m_coordinateSystem; private: /** internal function which do one peace of work, which should be performed by diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDEventWorkspace.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDEventWorkspace.h index 0a0564001aac..4aaa6769320a 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDEventWorkspace.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDEventWorkspace.h @@ -150,12 +150,12 @@ class DLLExport MDEventWorkspace : public API::IMDEventWorkspace { void clearMDMasking(); /// Get the special coordinate system. - virtual Mantid::API::SpecialCoordinateSystem + virtual Mantid::Kernel::SpecialCoordinateSystem getSpecialCoordinateSystem() const; /// Set the special coordinate system. void setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem); + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem); /// make the workspace file backed if it has not been already file backed; virtual void setFileBacked(const std::string &fileName); /// if workspace was file-backed, this should clear file-backed information diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDHistoWorkspace.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDHistoWorkspace.h index 1d57ee5cf58a..1bc89a29dc24 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDHistoWorkspace.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDHistoWorkspace.h @@ -147,12 +147,12 @@ class DLLExport MDHistoWorkspace : public API::IMDHistoWorkspace { const coord_t *getBinWidths() const { return m_boxLength; } /// Get the special coordinate system. - virtual Mantid::API::SpecialCoordinateSystem + virtual Mantid::Kernel::SpecialCoordinateSystem getSpecialCoordinateSystem() const; /// Set the special coordinate system. void setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem); + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem); void setTo(signal_t signal, signal_t errorSquared, signal_t numEvents); diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDWSDescription.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDWSDescription.h index 204b8dfd3d3d..5487c91648ce 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDWSDescription.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/MDWSDescription.h @@ -149,9 +149,9 @@ class DLLExport MDWSDescription : public API::LogManager { getOrientedLattice(Mantid::API::MatrixWorkspace_const_sptr inWS2D); /// Set the special coordinate system if any. - void setCoordinateSystem(const Mantid::API::SpecialCoordinateSystem system); + void setCoordinateSystem(const Mantid::Kernel::SpecialCoordinateSystem system); /// @return the special coordinate system if any. - Mantid::API::SpecialCoordinateSystem getCoordinateSystem() const; + Mantid::Kernel::SpecialCoordinateSystem getCoordinateSystem() const; /// sets number of bins each dimension is split void setNumBins(const std::vector &nBins); @@ -191,7 +191,7 @@ class DLLExport MDWSDescription : public API::LogManager { private: /// Coordinate system. - Mantid::API::SpecialCoordinateSystem m_coordinateSystem; + Mantid::Kernel::SpecialCoordinateSystem m_coordinateSystem; }; } } diff --git a/Code/Mantid/Framework/MDEvents/src/ConvToMDBase.cpp b/Code/Mantid/Framework/MDEvents/src/ConvToMDBase.cpp index 6a1c86d6f1ba..2bb6898f1a07 100644 --- a/Code/Mantid/Framework/MDEvents/src/ConvToMDBase.cpp +++ b/Code/Mantid/Framework/MDEvents/src/ConvToMDBase.cpp @@ -103,7 +103,7 @@ ConvToMDBase::ConvToMDBase() m_NSpectra(0), // no valid spectra by default. m_NumThreads(-1), // run with all cores availible m_ignoreZeros(false), // 0-s added to workspace - m_coordinateSystem(Mantid::API::None) {} + m_coordinateSystem(Mantid::Kernel::None) {} } // endNamespace MDAlgorithms } diff --git a/Code/Mantid/Framework/MDEvents/src/Integrate3DEvents.cpp b/Code/Mantid/Framework/MDEvents/src/Integrate3DEvents.cpp index 523cebc1b7ca..87f05f5b8377 100644 --- a/Code/Mantid/Framework/MDEvents/src/Integrate3DEvents.cpp +++ b/Code/Mantid/Framework/MDEvents/src/Integrate3DEvents.cpp @@ -455,7 +455,7 @@ PeakShapeEllipsoid_const_sptr Integrate3DEvents::ellipseIntegrateEvents( sigi = sqrt(peak_w_back + ratio * ratio * backgrd); // Make the shape and return it. - return boost::make_shared(directions, abcRadii, abcBackgroundInnerRadii, abcBackgroundOuterRadii, Mantid::API::QLab, "IntegrateEllipsoids"); + return boost::make_shared(directions, abcRadii, abcBackgroundInnerRadii, abcBackgroundOuterRadii, Mantid::Kernel::QLab, "IntegrateEllipsoids"); } } // namespace MDEvents diff --git a/Code/Mantid/Framework/MDEvents/src/MDEventWorkspace.cpp b/Code/Mantid/Framework/MDEvents/src/MDEventWorkspace.cpp index 3ad36ac02023..e4c9d582dcbb 100644 --- a/Code/Mantid/Framework/MDEvents/src/MDEventWorkspace.cpp +++ b/Code/Mantid/Framework/MDEvents/src/MDEventWorkspace.cpp @@ -786,7 +786,7 @@ Set the special coordinate system (if any) to use. @param coordinateSystem : Special coordinate system to use. */ TMDE(void MDEventWorkspace)::setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem) { + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem) { // If there isn't an experiment info, create one. if (this->getNumExperimentInfo() == 0) { ExperimentInfo_sptr expInfo = @@ -801,9 +801,9 @@ TMDE(void MDEventWorkspace)::setCoordinateSystem( Get the special coordinate system (if any) to use. @return Special coordinate system if any. */ -TMDE(Mantid::API::SpecialCoordinateSystem +TMDE(Mantid::Kernel::SpecialCoordinateSystem MDEventWorkspace)::getSpecialCoordinateSystem() const { - Mantid::API::SpecialCoordinateSystem result = None; + Mantid::Kernel::SpecialCoordinateSystem result = None; try { auto nInfos = this->getNumExperimentInfo(); if (nInfos > 0) { diff --git a/Code/Mantid/Framework/MDEvents/src/MDHistoWorkspace.cpp b/Code/Mantid/Framework/MDEvents/src/MDHistoWorkspace.cpp index 2cfc6d5ea5d4..6bda2b2a2d1f 100644 --- a/Code/Mantid/Framework/MDEvents/src/MDHistoWorkspace.cpp +++ b/Code/Mantid/Framework/MDEvents/src/MDHistoWorkspace.cpp @@ -1187,7 +1187,7 @@ Set the special coordinate system (if any) to use. @param coordinateSystem : Special coordinate system to use. */ void MDHistoWorkspace::setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem coordinateSystem) { + const Mantid::Kernel::SpecialCoordinateSystem coordinateSystem) { // If there isn't an experiment info, create one. if (this->getNumExperimentInfo() == 0) { ExperimentInfo_sptr expInfo = @@ -1201,9 +1201,9 @@ void MDHistoWorkspace::setCoordinateSystem( /** Get the special coordinate system (if any) to use. */ -Mantid::API::SpecialCoordinateSystem +Mantid::Kernel::SpecialCoordinateSystem MDHistoWorkspace::getSpecialCoordinateSystem() const { - Mantid::API::SpecialCoordinateSystem result = None; + Mantid::Kernel::SpecialCoordinateSystem result = None; try { auto nInfos = this->getNumExperimentInfo(); if (nInfos > 0) { diff --git a/Code/Mantid/Framework/MDEvents/src/MDWSDescription.cpp b/Code/Mantid/Framework/MDEvents/src/MDWSDescription.cpp index 13d33dbecb14..10b30e0d7135 100644 --- a/Code/Mantid/Framework/MDEvents/src/MDWSDescription.cpp +++ b/Code/Mantid/Framework/MDEvents/src/MDWSDescription.cpp @@ -246,7 +246,7 @@ void MDWSDescription::checkWSCorresponsMDWorkspace( MDWSDescription::MDWSDescription(unsigned int nDimensions) : m_Wtransf(3, 3, true), m_RotMatrix(9, 0), m_buildingNewWorkspace(true), m_Emode(Kernel::DeltaEMode::Undefined), m_LorentzCorr(false), - m_coordinateSystem(Mantid::API::None) { + m_coordinateSystem(Mantid::Kernel::None) { this->resizeDimDescriptions(nDimensions); m_DimMin.assign(m_NDims, std::numeric_limits::quiet_NaN()); @@ -425,12 +425,12 @@ MDWSDescription::getOrientedLattice( @param system : coordinate system. */ void MDWSDescription::setCoordinateSystem( - const Mantid::API::SpecialCoordinateSystem system) { + const Mantid::Kernel::SpecialCoordinateSystem system) { m_coordinateSystem = system; } /// @return the special coordinate system if any. -Mantid::API::SpecialCoordinateSystem +Mantid::Kernel::SpecialCoordinateSystem MDWSDescription::getCoordinateSystem() const { return m_coordinateSystem; } diff --git a/Code/Mantid/Framework/MDEvents/src/MDWSTransform.cpp b/Code/Mantid/Framework/MDEvents/src/MDWSTransform.cpp index d35245613859..15dbab13aef5 100644 --- a/Code/Mantid/Framework/MDEvents/src/MDWSTransform.cpp +++ b/Code/Mantid/Framework/MDEvents/src/MDWSTransform.cpp @@ -320,21 +320,21 @@ void MDWSTransform::setQ3DDimensionsNames( dimNames[0] = "Q_lab_x"; dimNames[1] = "Q_lab_y"; dimNames[2] = "Q_lab_z"; - TargWSDescription.setCoordinateSystem(Mantid::API::QLab); + TargWSDescription.setCoordinateSystem(Mantid::Kernel::QLab); break; } case (CnvrtToMD::SampleFrame): { dimNames[0] = "Q_sample_x"; dimNames[1] = "Q_sample_y"; dimNames[2] = "Q_sample_z"; - TargWSDescription.setCoordinateSystem(Mantid::API::QSample); + TargWSDescription.setCoordinateSystem(Mantid::Kernel::QSample); break; } case (CnvrtToMD::HKLFrame): { dimNames[0] = "H"; dimNames[1] = "K"; dimNames[2] = "L"; - TargWSDescription.setCoordinateSystem(Mantid::API::HKL); + TargWSDescription.setCoordinateSystem(Mantid::Kernel::HKL); break; } default: diff --git a/Code/Mantid/Framework/MDEvents/test/MDEventWorkspaceTest.h b/Code/Mantid/Framework/MDEvents/test/MDEventWorkspaceTest.h index 100281d7d464..b4af4acd1a7f 100644 --- a/Code/Mantid/Framework/MDEvents/test/MDEventWorkspaceTest.h +++ b/Code/Mantid/Framework/MDEvents/test/MDEventWorkspaceTest.h @@ -597,16 +597,16 @@ class MDEventWorkspaceTest : public CxxTest::TestSuite void test_getSpecialCoordinateSystem_default() { MDEventWorkspace1Lean::sptr ws = MDEventsTestHelper::makeMDEW<1>(10, 0.0, 10.0, 1 /*event per box*/); - TSM_ASSERT_EQUALS("Should default to no special coordinate system.", Mantid::API::None, ws->getSpecialCoordinateSystem()); + TSM_ASSERT_EQUALS("Should default to no special coordinate system.", Mantid::Kernel::None, ws->getSpecialCoordinateSystem()); } void test_setSpecialCoordinateSystem_default() { MDEventWorkspace1Lean::sptr ws = MDEventsTestHelper::makeMDEW<1>(10, 0.0, 10.0, 1 /*event per box*/); - TS_ASSERT_EQUALS(Mantid::API::None, ws->getSpecialCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::None, ws->getSpecialCoordinateSystem()); - ws->setCoordinateSystem(Mantid::API::QLab); - TS_ASSERT_EQUALS(Mantid::API::QLab, ws->getSpecialCoordinateSystem()); + ws->setCoordinateSystem(Mantid::Kernel::QLab); + TS_ASSERT_EQUALS(Mantid::Kernel::QLab, ws->getSpecialCoordinateSystem()); } }; diff --git a/Code/Mantid/Framework/MDEvents/test/MDHistoWorkspaceIteratorTest.h b/Code/Mantid/Framework/MDEvents/test/MDHistoWorkspaceIteratorTest.h index 397fc31e892e..64a45ac4d24b 100644 --- a/Code/Mantid/Framework/MDEvents/test/MDHistoWorkspaceIteratorTest.h +++ b/Code/Mantid/Framework/MDEvents/test/MDHistoWorkspaceIteratorTest.h @@ -19,6 +19,7 @@ using namespace Mantid; using namespace Mantid::MDEvents; using namespace Mantid::API; +using namespace Mantid::Kernel; using Mantid::Kernel::VMD; using Mantid::Geometry::MDHistoDimension; using Mantid::Geometry::MDImplicitFunction; diff --git a/Code/Mantid/Framework/MDEvents/test/MDHistoWorkspaceTest.h b/Code/Mantid/Framework/MDEvents/test/MDHistoWorkspaceTest.h index 89644c241c81..4c3ce0f39484 100644 --- a/Code/Mantid/Framework/MDEvents/test/MDHistoWorkspaceTest.h +++ b/Code/Mantid/Framework/MDEvents/test/MDHistoWorkspaceTest.h @@ -958,16 +958,16 @@ class MDHistoWorkspaceTest : public CxxTest::TestSuite void test_getSpecialCoordinateSystem_default() { MDHistoWorkspace_sptr ws = MDEventsTestHelper::makeFakeMDHistoWorkspace(1, 1); - TSM_ASSERT_EQUALS("Should default to no special coordinate system.", Mantid::API::None, ws->getSpecialCoordinateSystem()); + TSM_ASSERT_EQUALS("Should default to no special coordinate system.", Mantid::Kernel::None, ws->getSpecialCoordinateSystem()); } void test_setSpecialCoordinateSystem_default() { MDHistoWorkspace_sptr ws = MDEventsTestHelper::makeFakeMDHistoWorkspace(1, 1); - TS_ASSERT_EQUALS(Mantid::API::None, ws->getSpecialCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::None, ws->getSpecialCoordinateSystem()); - ws->setCoordinateSystem(Mantid::API::QLab); - TS_ASSERT_EQUALS(Mantid::API::QLab, ws->getSpecialCoordinateSystem()); + ws->setCoordinateSystem(Mantid::Kernel::QLab); + TS_ASSERT_EQUALS(Mantid::Kernel::QLab, ws->getSpecialCoordinateSystem()); } diff --git a/Code/Mantid/Framework/MDEvents/test/MDWSDescriptionTest.h b/Code/Mantid/Framework/MDEvents/test/MDWSDescriptionTest.h index 2cc23ac8f542..9ac56a7215bb 100644 --- a/Code/Mantid/Framework/MDEvents/test/MDWSDescriptionTest.h +++ b/Code/Mantid/Framework/MDEvents/test/MDWSDescriptionTest.h @@ -3,6 +3,7 @@ #include "MantidMDEvents/MDWSDescription.h" #include "MantidTestHelpers/WorkspaceCreationHelper.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include "MantidKernel/Exception.h" #include @@ -129,12 +130,12 @@ class MDWSDescriptionTest : public CxxTest::TestSuite void test_defaultCoordinateSystem() { MDWSDescription description; - TS_ASSERT_EQUALS(Mantid::API::None, description.getCoordinateSystem()); + TS_ASSERT_EQUALS(Mantid::Kernel::None, description.getCoordinateSystem()); } void test_setCoordinateSystem() { - using namespace Mantid::API; + using namespace Mantid::Kernel; const SpecialCoordinateSystem expectedResult = QSample; MDWSDescription description; diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/IMDWorkspace.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/IMDWorkspace.cpp index 602eb47f6a7b..5c728e614f83 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/IMDWorkspace.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/IMDWorkspace.cpp @@ -16,11 +16,11 @@ void export_IMDWorkspace() .value("VolumeNormalization", Mantid::API::VolumeNormalization) .value("NumEventsNormalization", Mantid::API::NumEventsNormalization); - boost::python::enum_("SpecialCoordinateSystem") - .value("None", Mantid::API::None) - .value("QLab", Mantid::API::QLab) - .value("QSample", Mantid::API::QSample) - .value("HKL", Mantid::API::HKL); + boost::python::enum_("SpecialCoordinateSystem") + .value("None", Mantid::Kernel::None) + .value("QLab", Mantid::Kernel::QLab) + .value("QSample", Mantid::Kernel::QSample) + .value("HKL", Mantid::Kernel::HKL); // EventWorkspace class class_< IMDWorkspace, bases, boost::noncopyable >("IMDWorkspace", no_init) diff --git a/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/FakeObjects.h b/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/FakeObjects.h index c29643bd20ee..e7ad81689081 100644 --- a/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/FakeObjects.h +++ b/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/FakeObjects.h @@ -124,9 +124,9 @@ class WorkspaceTester : public MatrixWorkspace { } void generateHistogram(const std::size_t, const MantidVec &, MantidVec &, MantidVec &, bool) const {} - virtual Mantid::API::SpecialCoordinateSystem + virtual Mantid::Kernel::SpecialCoordinateSystem getSpecialCoordinateSystem() const { - return Mantid::API::None; + return Mantid::Kernel::None; } private: diff --git a/Code/Mantid/MantidQt/API/test/SignalRangeTest.h b/Code/Mantid/MantidQt/API/test/SignalRangeTest.h index 11f4dbd84dea..6504c82af32d 100644 --- a/Code/Mantid/MantidQt/API/test/SignalRangeTest.h +++ b/Code/Mantid/MantidQt/API/test/SignalRangeTest.h @@ -32,7 +32,7 @@ class SignalRangeTest : public CxxTest::TestSuite const Mantid::API::MDNormalization &)); MOCK_METHOD1(setMDMasking, void(Mantid::Geometry::MDImplicitFunction*)); MOCK_METHOD0(clearMDMasking, void()); - MOCK_CONST_METHOD0(getSpecialCoordinateSystem, Mantid::API::SpecialCoordinateSystem()); + MOCK_CONST_METHOD0(getSpecialCoordinateSystem, Mantid::Kernel::SpecialCoordinateSystem()); }; class MockMDIterator : public Mantid::API::IMDIterator diff --git a/Code/Mantid/MantidQt/SliceViewer/inc/MantidQtSliceViewer/ConcretePeaksPresenter.h b/Code/Mantid/MantidQt/SliceViewer/inc/MantidQtSliceViewer/ConcretePeaksPresenter.h index 928a8a6eac53..bea7b3cc90fc 100644 --- a/Code/Mantid/MantidQt/SliceViewer/inc/MantidQtSliceViewer/ConcretePeaksPresenter.h +++ b/Code/Mantid/MantidQt/SliceViewer/inc/MantidQtSliceViewer/ConcretePeaksPresenter.h @@ -6,7 +6,7 @@ #include "MantidQtSliceViewer/PeakOverlayViewFactory.h" #include "MantidAPI/MDGeometry.h" #include "MantidAPI/IPeaksWorkspace.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include "MantidKernel/V3D.h" #include #include @@ -18,7 +18,7 @@ typedef std::vector> VecPeakOverlayView; /// Coordinate System Enum to String. std::string DLLExport - coordinateToString(Mantid::API::SpecialCoordinateSystem coordSystem); + coordinateToString(Mantid::Kernel::SpecialCoordinateSystem coordSystem); /*--------------------------------------------------------- ConcretePeaksPresenter diff --git a/Code/Mantid/MantidQt/SliceViewer/src/ConcretePeaksPresenter.cpp b/Code/Mantid/MantidQt/SliceViewer/src/ConcretePeaksPresenter.cpp index 3f87e490f72d..aa5929add3b7 100644 --- a/Code/Mantid/MantidQt/SliceViewer/src/ConcretePeaksPresenter.cpp +++ b/Code/Mantid/MantidQt/SliceViewer/src/ConcretePeaksPresenter.cpp @@ -12,6 +12,7 @@ #include using namespace Mantid::API; +using namespace Mantid::Kernel; using Mantid::Geometry::IMDDimension_const_sptr; namespace MantidQt { @@ -27,13 +28,13 @@ Mantid::Kernel::Logger g_log("PeaksPresenter"); * @return coordinate system as a string */ std::string -coordinateToString(Mantid::API::SpecialCoordinateSystem coordSystem) { +coordinateToString(Mantid::Kernel::SpecialCoordinateSystem coordSystem) { switch (coordSystem) { - case Mantid::API::QLab: + case Mantid::Kernel::QLab: return "QLab"; - case Mantid::API::QSample: + case Mantid::Kernel::QSample: return "QSample"; - case Mantid::API::HKL: + case Mantid::Kernel::HKL: return "HKL"; default: return "Unknown"; diff --git a/Code/Mantid/MantidQt/SliceViewer/test/ConcretePeaksPresenterTest.h b/Code/Mantid/MantidQt/SliceViewer/test/ConcretePeaksPresenterTest.h index 800dcb3ea0a5..1ae0b2ebc7bc 100644 --- a/Code/Mantid/MantidQt/SliceViewer/test/ConcretePeaksPresenterTest.h +++ b/Code/Mantid/MantidQt/SliceViewer/test/ConcretePeaksPresenterTest.h @@ -5,7 +5,7 @@ #include "MantidAPI/ExperimentInfo.h" #include "MantidAPI/IPeak.h" #include "MantidAPI/FrameworkManager.h" -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include "MantidAPI/PeakTransformFactory.h" #include "MantidQtSliceViewer/ConcretePeaksPresenter.h" #include "MantidQtSliceViewer/PeakOverlayViewFactory.h" @@ -588,9 +588,9 @@ class ConcretePeaksPresenterTest : public CxxTest::TestSuite void test_coordinateToString() { - TS_ASSERT_EQUALS("HKL", coordinateToString(Mantid::API::HKL)); - TS_ASSERT_EQUALS("QLab", coordinateToString(Mantid::API::QLab)); - TS_ASSERT_EQUALS("QSample", coordinateToString(Mantid::API::QSample)); + TS_ASSERT_EQUALS("HKL", coordinateToString(Mantid::Kernel::HKL)); + TS_ASSERT_EQUALS("QLab", coordinateToString(Mantid::Kernel::QLab)); + TS_ASSERT_EQUALS("QSample", coordinateToString(Mantid::Kernel::QSample)); } void test_getPeaksSizeOnProjection() diff --git a/Code/Mantid/MantidQt/SliceViewer/test/MockObjects.h b/Code/Mantid/MantidQt/SliceViewer/test/MockObjects.h index d856c4e68323..5180a02fca33 100644 --- a/Code/Mantid/MantidQt/SliceViewer/test/MockObjects.h +++ b/Code/Mantid/MantidQt/SliceViewer/test/MockObjects.h @@ -95,7 +95,7 @@ namespace MOCK_CONST_METHOD1(transform, Mantid::Kernel::V3D(const Mantid::Kernel::V3D&)); MOCK_CONST_METHOD1(transformPeak, Mantid::Kernel::V3D(const Mantid::API::IPeak&)); MOCK_CONST_METHOD0(getFriendlyName, std::string()); - MOCK_CONST_METHOD0(getCoordinateSystem, Mantid::API::SpecialCoordinateSystem()); + MOCK_CONST_METHOD0(getCoordinateSystem, Mantid::Kernel::SpecialCoordinateSystem()); }; /*------------------------------------------------------------ diff --git a/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/MDLoadingPresenter.h b/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/MDLoadingPresenter.h index ba96a23e793e..b1b9b6ccb933 100644 --- a/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/MDLoadingPresenter.h +++ b/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/MDLoadingPresenter.h @@ -63,7 +63,7 @@ namespace Mantid } virtual int getSpecialCoordinates() { - return API::None; + return Kernel::None; } }; diff --git a/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/vtkDataSetToNonOrthogonalDataSet.h b/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/vtkDataSetToNonOrthogonalDataSet.h index b933cb7c3a0d..ae7c45346faa 100644 --- a/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/vtkDataSetToNonOrthogonalDataSet.h +++ b/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/vtkDataSetToNonOrthogonalDataSet.h @@ -1,7 +1,7 @@ #ifndef MANTID_VATES_VTKDATASETTONONORTHOGONALDATASET_H_ #define MANTID_VATES_VTKDATASETTONONORTHOGONALDATASET_H_ -#include "MantidAPI/SpecialCoordinateSystem.h" +#include "MantidKernel/SpecialCoordinateSystem.h" #include "MantidKernel/System.h" #include "MantidKernel/cow_ptr.h" #include "MantidKernel/Matrix.h" @@ -86,7 +86,7 @@ namespace VATES Kernel::V3D m_basisX; ///< The X direction basis vector Kernel::V3D m_basisY; ///< The Y direction basis vector Kernel::V3D m_basisZ; ///< The Z direction basis vector - API::SpecialCoordinateSystem m_coordType; ///< The coordinate system for the workspace + Kernel::SpecialCoordinateSystem m_coordType; ///< The coordinate system for the workspace }; diff --git a/Code/Mantid/Vates/VatesAPI/src/vtkDataSetToNonOrthogonalDataSet.cpp b/Code/Mantid/Vates/VatesAPI/src/vtkDataSetToNonOrthogonalDataSet.cpp index 49003e749691..eb769d1ed4de 100644 --- a/Code/Mantid/Vates/VatesAPI/src/vtkDataSetToNonOrthogonalDataSet.cpp +++ b/Code/Mantid/Vates/VatesAPI/src/vtkDataSetToNonOrthogonalDataSet.cpp @@ -51,7 +51,7 @@ vtkDataSetToNonOrthogonalDataSet::vtkDataSetToNonOrthogonalDataSet(vtkDataSet *d m_basisX(1, 0, 0), m_basisY(0, 1, 0), m_basisZ(0, 0, 1), - m_coordType(API::HKL) + m_coordType(Kernel::HKL) { if (NULL == m_dataSet) { @@ -96,7 +96,7 @@ void vtkDataSetToNonOrthogonalDataSet::execute() API::IMDHistoWorkspace_const_sptr infoWs = boost::dynamic_pointer_cast(ws); m_numDims = infoWs->getNumDims(); m_coordType = infoWs->getSpecialCoordinateSystem(); - if (API::HKL != m_coordType) + if (Kernel::HKL != m_coordType) { throw std::invalid_argument("Cannot create non-orthogonal view for non-HKL coordinates"); } @@ -131,7 +131,7 @@ void vtkDataSetToNonOrthogonalDataSet::execute() API::IMDEventWorkspace_const_sptr infoWs = boost::dynamic_pointer_cast(ws); m_numDims = infoWs->getNumDims(); m_coordType = infoWs->getSpecialCoordinateSystem(); - if (API::HKL != m_coordType) + if (Kernel::HKL != m_coordType) { throw std::invalid_argument("Cannot create non-orthogonal view for non-HKL coordinates"); } diff --git a/Code/Mantid/Vates/VatesAPI/test/MockObjects.h b/Code/Mantid/Vates/VatesAPI/test/MockObjects.h index 0e68c9966ad4..46fd81113642 100644 --- a/Code/Mantid/Vates/VatesAPI/test/MockObjects.h +++ b/Code/Mantid/Vates/VatesAPI/test/MockObjects.h @@ -86,7 +86,7 @@ class MockIMDWorkspace: public Mantid::API::IMDWorkspace MOCK_CONST_METHOD0(getNonIntegratedDimensions, Mantid::Geometry::VecIMDDimension_const_sptr()); MOCK_METHOD1(setMDMasking, void(Mantid::Geometry::MDImplicitFunction*)); MOCK_METHOD0(clearMDMasking,void()); - MOCK_CONST_METHOD0(getSpecialCoordinateSystem, Mantid::API::SpecialCoordinateSystem()); + MOCK_CONST_METHOD0(getSpecialCoordinateSystem, Mantid::Kernel::SpecialCoordinateSystem()); virtual void getLinePlot(const Mantid::Kernel::VMD & , const Mantid::Kernel::VMD & , Mantid::API::MDNormalization , std::vector & , std::vector & , std::vector & ) const diff --git a/Code/Mantid/Vates/VatesAPI/test/vtkDataSetToNonOrthogonalDataSetTest.h b/Code/Mantid/Vates/VatesAPI/test/vtkDataSetToNonOrthogonalDataSetTest.h index edab016cd784..7bdafe9ce686 100644 --- a/Code/Mantid/Vates/VatesAPI/test/vtkDataSetToNonOrthogonalDataSetTest.h +++ b/Code/Mantid/Vates/VatesAPI/test/vtkDataSetToNonOrthogonalDataSetTest.h @@ -43,7 +43,7 @@ class vtkDataSetToNonOrthogonalDataSetTest : public CxxTest::TestSuite // Set the coordinate system if (!wrongCoords) { - ws->setCoordinateSystem(Mantid::API::HKL); + ws->setCoordinateSystem(Mantid::Kernel::HKL); } else {