Skip to content

Commit

Permalink
Remove IDataFileChecker & LoadAlgorithmFactory. Refs #7263
Browse files Browse the repository at this point in the history
  • Loading branch information
martyngigg committed Jul 4, 2013
1 parent a5c9c30 commit 39bfe42
Show file tree
Hide file tree
Showing 11 changed files with 3 additions and 296 deletions.
4 changes: 0 additions & 4 deletions Code/Mantid/Framework/API/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ set ( SRC_FILES
src/FunctionValues.cpp
src/GridDomain.cpp
src/GridDomain1D.cpp
src/IDataFileChecker.cpp
src/IDomainCreator.cpp
src/IEventList.cpp
src/IEventWorkspace.cpp
Expand Down Expand Up @@ -69,7 +68,6 @@ set ( SRC_FILES
src/JointDomain.cpp
src/LinearScale.cpp
src/LiveListenerFactory.cpp
src/LoadAlgorithmFactory.cpp
src/LocatedDataRef.cpp
src/LocatedDataValue.cpp
src/LogManager.cpp
Expand Down Expand Up @@ -172,7 +170,6 @@ set ( INC_FILES
inc/MantidAPI/ICatalog.h
inc/MantidAPI/IConstraint.h
inc/MantidAPI/ICostFunction.h
inc/MantidAPI/IDataFileChecker.h
inc/MantidAPI/IDataItem.h
inc/MantidAPI/IDomainCreator.h
inc/MantidAPI/IEventList.h
Expand Down Expand Up @@ -216,7 +213,6 @@ set ( INC_FILES
inc/MantidAPI/JointDomain.h
inc/MantidAPI/LinearScale.h
inc/MantidAPI/LiveListenerFactory.h
inc/MantidAPI/LoadAlgorithmFactory.h
inc/MantidAPI/LocatedDataRef.h
inc/MantidAPI/LocatedDataValue.h
inc/MantidAPI/LogManager.h
Expand Down
89 changes: 0 additions & 89 deletions Code/Mantid/Framework/API/inc/MantidAPI/IDataFileChecker.h

This file was deleted.

93 changes: 0 additions & 93 deletions Code/Mantid/Framework/API/inc/MantidAPI/LoadAlgorithmFactory.h

This file was deleted.

42 changes: 0 additions & 42 deletions Code/Mantid/Framework/API/src/IDataFileChecker.cpp

This file was deleted.

30 changes: 0 additions & 30 deletions Code/Mantid/Framework/API/src/LoadAlgorithmFactory.cpp

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,6 @@ namespace Mantid
virtual int version() const;
/// category
virtual const std::string category() const { return "Deprecated"; }

int fileCheck(const std::string& filePath);

};

} // namespace DataHandling
Expand Down
1 change: 0 additions & 1 deletion Code/Mantid/Framework/DataHandling/src/Load.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ Loading multiple files is also possible with <code>Load</code>, as well as works
#include "MantidAPI/IEventWorkspace.h"
#include "MantidAPI/IMDEventWorkspace.h"
#include "MantidAPI/IWorkspaceProperty.h"
#include "MantidAPI/LoadAlgorithmFactory.h"
#include "MantidAPI/MultipleFileProperty.h"
#include "MantidKernel/ArrayProperty.h"
#include "MantidKernel/FacilityInfo.h"
Expand Down
15 changes: 0 additions & 15 deletions Code/Mantid/Framework/DataHandling/src/LoadSNSEventNexus.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
// Includes
//----------------------------------------------------------------------
#include "MantidDataHandling/LoadSNSEventNexus.h"
#include "MantidAPI/LoadAlgorithmFactory.h" // For the DECLARE_LOADALGORITHM macro

using namespace ::NeXus;
using namespace Mantid::Geometry;
Expand All @@ -17,9 +16,6 @@ namespace Mantid
namespace DataHandling
{

DECLARE_ALGORITHM(LoadSNSEventNexus)
//DECLARE_LOADALGORITHM(LoadSNSEventNexus)

LoadSNSEventNexus::LoadSNSEventNexus()
{
this->useAlgorithm("LoadEventNexus");
Expand All @@ -36,16 +32,5 @@ const std::string LoadSNSEventNexus::name() const
return "LoadSNSEventNexus";
}

/**
* Checks the file by opening it and reading few lines
* @param filePath :: name of the file inluding its path
* @return an integer value how much this algorithm can load the file
*/
int LoadSNSEventNexus::fileCheck(const std::string& filePath)
{
UNUSED_ARG(filePath);
return 0;
}

} // namespace DataHandling
} // namespace Mantid
8 changes: 3 additions & 5 deletions Code/Mantid/Framework/DataHandling/src/LoadSpice2D.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
#include "MantidKernel/BoundedValidator.h"
#include "MantidKernel/Strings.h"
#include "MantidAPI/AlgorithmFactory.h"
#include "MantidAPI/LoadAlgorithmFactory.h"

#include <boost/regex.hpp>
#include <boost/shared_array.hpp>
Expand Down Expand Up @@ -44,6 +43,9 @@ namespace Mantid
{
namespace DataHandling
{
// Register the algorithm into the AlgorithmFactory
DECLARE_FILELOADER_ALGORITHM(LoadSpice2D);

// Parse string and convert to numeric type
template <class T>
bool from_string(T& t, const std::string& s, std::ios_base& (*f)(std::ios_base&))
Expand Down Expand Up @@ -94,10 +96,6 @@ namespace Mantid
ws->getSpectrum(specID)->setSpectrumNo(specID);
}


// Register the algorithm into the AlgorithmFactory
DECLARE_FILELOADER_ALGORITHM(LoadSpice2D);

/**
* Return the confidence with with this algorithm can load the file
* @param descriptor A descriptor for the file
Expand Down
13 changes: 0 additions & 13 deletions Code/Mantid/Framework/DataHandling/test/LoadSNSEventNexusTest.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,6 @@ class LoadSNSEventNexusTest : public CxxTest::TestSuite
{
public:

void test_fileCheck()
{
LoadSNSEventNexus ld;
ld.initialize();
ld.setPropertyValue("Filename","CNCS_7860_event.nxs"); // Only doing this to resolve the path to the file
TS_ASSERT_EQUALS(ld.fileCheck(ld.getPropertyValue("Filename")), 0);

//Try an ISIS nexus file
ld.setPropertyValue("Filename","LOQ49886.nxs");
TS_ASSERT_EQUALS(ld.fileCheck(ld.getPropertyValue("Filename")), 0);
}


void test_Simple()
{
Mantid::API::FrameworkManager::Instance();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
#include "MantidKernel/Matrix.h"
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/MatrixWorkspace.h"
#include "MantidAPI/LoadAlgorithmFactory.h"
#include "MantidGeometry/Crystal/OrientedLattice.h"
#include <iostream>
#include <fstream>
Expand Down

0 comments on commit 39bfe42

Please sign in to comment.