Commit 304b8748 authored by Martyn Gigg's avatar Martyn Gigg
Browse files

Fix include ordering to give self-contained units

parent aee494d8
......@@ -3,8 +3,10 @@
#include <sstream>
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
namespace Mantid {
namespace API {
......
......@@ -22,8 +22,10 @@
#include "MantidTestHelpers/NexusTestHelper.h"
#include "PropertyManagerHelper.h"
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#include <cxxtest/TestSuite.h>
#include <boost/regex.hpp>
......
......@@ -12,29 +12,6 @@ namespace Crystal {
* @author Vickie Lynch, SNS
* @date 2012-01-20
*/
const double pc[4][19] = {
{1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000,
1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000,
1.0000},
{1.9368, 1.8653, 1.6908, 1.4981, 1.3532, 1.2746, 1.2530, 1.2714, 1.3093,
1.3559, 1.4019, 1.4434, 1.4794, 1.5088, 1.5317, 1.5489, 1.5608, 1.5677,
1.5700},
{0.0145, 0.1596, 0.5175, 0.9237, 1.2436, 1.4308, 1.4944, 1.4635, 1.3770,
1.2585, 1.1297, 1.0026, 0.8828, 0.7768, 0.6875, 0.6159, 0.5637, 0.5320,
0.5216},
{1.1386, 1.0604, 0.8598, 0.6111, 0.3798, 0.1962, 0.0652, -0.0198, -0.0716,
-0.0993, -0.1176, -0.1153, -0.1125, -0.1073, -0.1016, -0.0962, -0.0922,
-0.0898, -0.0892}};
const double MAX_WAVELENGTH = 50.0; // max in lamda_weight table
const double STEPS_PER_ANGSTROM = 100; // resolution of lamda table
const int NUM_WAVELENGTHS =
static_cast<int>(std::ceil(MAX_WAVELENGTH * STEPS_PER_ANGSTROM));
const double radtodeg_half = 180.0 / M_PI / 2.;
class DLLExport TOFExtinction : public API::Algorithm {
public:
TOFExtinction();
......
......@@ -17,6 +17,31 @@ using namespace Mantid::Kernel;
using namespace Mantid::API;
using namespace Mantid::PhysicalConstants;
namespace {
const double pc[4][19] = {
{1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000,
1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000,
1.0000},
{1.9368, 1.8653, 1.6908, 1.4981, 1.3532, 1.2746, 1.2530, 1.2714, 1.3093,
1.3559, 1.4019, 1.4434, 1.4794, 1.5088, 1.5317, 1.5489, 1.5608, 1.5677,
1.5700},
{0.0145, 0.1596, 0.5175, 0.9237, 1.2436, 1.4308, 1.4944, 1.4635, 1.3770,
1.2585, 1.1297, 1.0026, 0.8828, 0.7768, 0.6875, 0.6159, 0.5637, 0.5320,
0.5216},
{1.1386, 1.0604, 0.8598, 0.6111, 0.3798, 0.1962, 0.0652, -0.0198, -0.0716,
-0.0993, -0.1176, -0.1153, -0.1125, -0.1073, -0.1016, -0.0962, -0.0922,
-0.0898, -0.0892}};
const double MAX_WAVELENGTH = 50.0; // max in lamda_weight table
const double STEPS_PER_ANGSTROM = 100; // resolution of lamda table
const int NUM_WAVELENGTHS =
static_cast<int>(std::ceil(MAX_WAVELENGTH * STEPS_PER_ANGSTROM));
const double radtodeg_half = 180.0 / M_PI / 2.;
}
namespace Mantid {
namespace Crystal {
......
......@@ -17,8 +17,10 @@
#undef CHAR
#endif
#include <nexus/NeXusException.hpp>
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#include <boost/lexical_cast.hpp>
#include <boost/scoped_array.hpp>
......
......@@ -5,8 +5,10 @@
#include "MantidAPI/MatrixWorkspace_fwd.h"
#include "MantidGeometry/IDTypes.h"
#include <boost/scoped_array.hpp>
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
namespace Mantid {
......
......@@ -5,7 +5,9 @@
#include "MantidAPI/Algorithm.h"
// NeXus
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#endif // MANTID_DATAHANDLING_PRECOMPILEDHEADER_H_
\ No newline at end of file
......@@ -9,6 +9,9 @@
#include <boost/shared_array.hpp>
namespace Mantid {
namespace API {
class Progress;
}
namespace DataHandling {
class DefaultEventLoader;
......
#ifndef MANTID_DATAHANDLING_SAVEISAWDETCAL_H_
#define MANTID_DATAHANDLING_SAVEISAWDETCAL_H_
#include "MantidKernel/System.h"
#include "MantidAPI/Algorithm.h"
#include "MantidGeometry/Instrument_fwd.h"
namespace Mantid {
namespace Kernel {
class V3D;
}
namespace DataHandling {
/** Saves an instrument with RectangularDetectors to an ISAW .DetCal file.
......@@ -36,7 +39,7 @@ namespace DataHandling {
class DLLExport SaveIsawDetCal : public API::Algorithm {
public:
/// Algorithm's name for identification
const std::string name() const override { return "SaveIsawDetCal"; };
const std::string name() const override { return "SaveIsawDetCal"; }
/// Summary of algorithms purpose
const std::string summary() const override {
return "Saves an instrument with RectangularDetectors to an ISAW .DetCal "
......@@ -44,7 +47,7 @@ public:
}
/// Algorithm's version for identification
int version() const override { return 1; };
int version() const override { return 1; }
const std::vector<std::string> seeAlso() const override {
return {"LoadIsawDetCal"};
}
......
......@@ -9,8 +9,10 @@
#include "MantidDataObjects/Workspace2D.h"
#include "MantidGeometry/Instrument/RectangularDetector.h"
#include <climits>
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
namespace Mantid {
namespace DataHandling {
......
......@@ -3,7 +3,10 @@
#include "MantidAPI/Algorithm.h"
#include "MantidGeometry/IDetector.h"
#include <nexus/NeXusFile.hpp>
namespace NeXus {
class File;
}
namespace Mantid {
namespace Geometry {
......
......@@ -6,8 +6,10 @@
#include "MantidKernel/OptionalBool.h"
#include "MantidKernel/System.h"
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#include <Poco/File.h>
#include <Poco/Path.h>
......
......@@ -11,8 +11,10 @@
#include "MantidKernel/ListValidator.h"
#include "MantidKernel/StringTokenizer.h"
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
namespace Mantid {
namespace DataHandling {
......
......@@ -16,8 +16,10 @@
#include "MantidKernel/VectorHelper.h"
#include "LoadRaw/isisraw2.h"
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#include <Poco/File.h>
......
......@@ -23,8 +23,10 @@
#include <boost/lexical_cast.hpp>
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#include <Poco/Path.h>
#include <Poco/DateTimeFormatter.h>
......
......@@ -14,8 +14,10 @@
#include "MantidGeometry/Instrument/InstrumentDefinitionParser.h"
#include <boost/algorithm/string.hpp>
#include <nexus/NeXusException.hpp>
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
namespace Mantid {
namespace DataHandling {
......
......@@ -6,8 +6,10 @@
#include "MantidAPI/WorkspaceFactory.h"
#include "MantidAPI/WorkspaceGroup.h"
#include "MantidKernel/Unit.h"
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#include <boost/algorithm/string.hpp>
......
......@@ -22,8 +22,10 @@
#include <boost/shared_ptr.hpp>
#include "MantidNexus/MuonNexusReader.h"
#include "MantidNexus/NexusClasses.h"
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
namespace Mantid {
namespace DataHandling {
......
......@@ -23,8 +23,10 @@
#include "MantidKernel/UnitLabelTypes.h"
#include "MantidNexus/MuonNexusReader.h"
#include "MantidNexus/NexusClasses.h"
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#include <boost/iterator/counting_iterator.hpp>
#include <boost/shared_ptr.hpp>
......
......@@ -20,8 +20,10 @@
#include <Poco/Path.h>
#include <boost/lexical_cast.hpp>
#include <boost/shared_ptr.hpp>
// clang-format off
#include <nexus/NeXusFile.hpp>
#include <nexus/NeXusException.hpp>
// clang-format on
#include <cmath>
#include <numeric>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment