Commit 33442a1b authored by Hahn, Steven's avatar Hahn, Steven
Browse files

Fix compilation errors.

parent 15119ae3
......@@ -110,7 +110,7 @@ public:
* @return a pointer to a new Peak object.
*/
virtual Mantid::Geometry::IPeak *
createPeak(Mantid::Kernel::V3D QLabFrame,
createPeak(const Mantid::Kernel::V3D &QLabFrame,
boost::optional<double> detectorDistance) const = 0;
/**
......@@ -119,7 +119,7 @@ public:
* @return a pointer to a new Peak object.
*/
virtual Mantid::Geometry::IPeak *
createPeakHKL(Mantid::Kernel::V3D HKL) const = 0;
createPeakHKL(const Mantid::Kernel::V3D &HKL) const = 0;
//---------------------------------------------------------------------------------------------
/** Determine if the workspace has been integrated using a peaks integration
......@@ -154,8 +154,8 @@ public:
getSpecialCoordinateSystem() const = 0;
virtual std::vector<std::pair<std::string, std::string>>
peakInfo(Kernel::V3D QFrame, bool labCoords) const = 0;
virtual int peakInfoNumber(Kernel::V3D qLabFrame, bool labCoords) const = 0;
peakInfo(const Kernel::V3D &QFrame, bool labCoords) const = 0;
virtual int peakInfoNumber(const Kernel::V3D &qLabFrame, bool labCoords) const = 0;
std::string convention;
......
......@@ -365,9 +365,7 @@ void SCDCalibratePanels::exec() {
PARALLEL_FOR3(ColWksp, RowWksp, TofWksp)
for (int i = 0; i < static_cast<int>(MyBankNames.size()); ++i) {
PARALLEL_START_INTERUPT_REGION
boost::container::flat_set<string>::iterator it = MyBankNames.begin();
advance(it, i);
std::string bankName = *it;
const std::string &bankName = *std::next(MyBankNames.begin(), i);
size_t k = bankName.find_last_not_of("0123456789");
int bank = 0;
if (k < bankName.length())
......
......@@ -119,7 +119,7 @@ public:
for (int i = 0; i < m_masterPeaks->getNumberPeaks(); i++) {
IPeak &peak = m_masterPeaks->getPeak(i);
Mantid::Kernel::V3D v(1, 0, 0);
peak.setQSampleFrame(v); // Overwrite all Q
peak.setQSampleFrame(v,boost::none); // Overwrite all Q
// samples to be
// co-linear.
}
......
......@@ -107,14 +107,14 @@ public:
const Peak &getPeak(int peakNum) const override;
Geometry::IPeak *createPeak(
Kernel::V3D QLabFrame,
const Kernel::V3D &QLabFrame,
boost::optional<double> detectorDistance = boost::none) const override;
std::vector<std::pair<std::string, std::string>>
peakInfo(Kernel::V3D qFrame, bool labCoords) const override;
peakInfo(const Kernel::V3D &qFrame, bool labCoords) const override;
Peak *createPeakHKL(Kernel::V3D HKL) const override;
Peak *createPeakHKL(const Kernel::V3D &HKL) const override;
int peakInfoNumber(Kernel::V3D qFrame, bool labCoords) const override;
int peakInfoNumber(const Kernel::V3D &qFrame, bool labCoords) const override;
std::vector<Peak> &getPeaks();
const std::vector<Peak> &getPeaks() const;
......
......@@ -190,7 +190,7 @@ const Peak &PeaksWorkspace::getPeak(const int peakNum) const {
* @return a pointer to a new Peak object.
*/
Geometry::IPeak *
PeaksWorkspace::createPeak(Kernel::V3D QLabFrame,
PeaksWorkspace::createPeak(const Kernel::V3D &QLabFrame,
boost::optional<double> detectorDistance) const {
Geometry::Goniometer goniometer = this->run().getGoniometer();
......@@ -222,7 +222,7 @@ PeaksWorkspace::createPeak(Kernel::V3D QLabFrame,
* value.
*/
std::vector<std::pair<std::string, std::string>>
PeaksWorkspace::peakInfo(Kernel::V3D qFrame, bool labCoords) const {
PeaksWorkspace::peakInfo(const Kernel::V3D &qFrame, bool labCoords) const {
std::vector<std::pair<std::string, std::string>> Result;
std::ostringstream oss;
oss << std::setw(12) << std::fixed << std::setprecision(3) << (qFrame.norm());
......@@ -393,7 +393,7 @@ PeaksWorkspace::peakInfo(Kernel::V3D qFrame, bool labCoords) const {
* @param HKL : reciprocal lattice vector coefficients
* @return Fully formed peak.
*/
Peak *PeaksWorkspace::createPeakHKL(V3D HKL) const {
Peak *PeaksWorkspace::createPeakHKL(const V3D &HKL) const {
/*
The following allows us to add peaks where we have a single UB to work from.
*/
......@@ -437,7 +437,8 @@ Peak *PeaksWorkspace::createPeakHKL(V3D HKL) const {
*form for the corresponding
* value.
*/
int PeaksWorkspace::peakInfoNumber(Kernel::V3D qFrame, bool labCoords) const {
int PeaksWorkspace::peakInfoNumber(const Kernel::V3D &qFrame,
bool labCoords) const {
std::vector<std::pair<std::string, std::string>> Result;
std::ostringstream oss;
oss << std::setw(12) << std::fixed << std::setprecision(3) << (qFrame.norm());
......
......@@ -76,13 +76,13 @@ public:
MOCK_METHOD1(setK, void(double m_K));
MOCK_METHOD1(setL, void(double m_L));
MOCK_METHOD3(setHKL, void(double H, double K, double L));
MOCK_METHOD1(setHKL, void(Mantid::Kernel::V3D HKL));
MOCK_METHOD1(setHKL, void(const Mantid::Kernel::V3D &HKL));
MOCK_CONST_METHOD0(getQLabFrame, Mantid::Kernel::V3D());
MOCK_CONST_METHOD0(getQSampleFrame, Mantid::Kernel::V3D());
MOCK_METHOD0(findDetector, bool());
MOCK_METHOD2(setQSampleFrame, void(Mantid::Kernel::V3D QSampleFrame,
MOCK_METHOD2(setQSampleFrame, void(const Mantid::Kernel::V3D &QSampleFrame,
boost::optional<double> detectorDistance));
MOCK_METHOD2(setQLabFrame, void(Mantid::Kernel::V3D QLabFrame,
MOCK_METHOD2(setQLabFrame, void(const Mantid::Kernel::V3D &QLabFrame,
boost::optional<double> detectorDistance));
MOCK_METHOD1(setWavelength, void(double wavelength));
MOCK_CONST_METHOD0(getWavelength, double());
......@@ -101,7 +101,7 @@ public:
MOCK_METHOD1(setBinCount, void(double m_BinCount));
MOCK_CONST_METHOD0(getGoniometerMatrix, Mantid::Kernel::Matrix<double>());
MOCK_METHOD1(setGoniometerMatrix,
void(Mantid::Kernel::Matrix<double> m_GoniometerMatrix));
void(const Mantid::Kernel::Matrix<double> &m_GoniometerMatrix));
MOCK_CONST_METHOD0(getBankName, std::string());
MOCK_CONST_METHOD0(getRow, int());
MOCK_CONST_METHOD0(getCol, int());
......
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