Mantid
Loading...
Searching...
No Matches
ExponentialMD.cpp
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
4// NScD Oak Ridge National Laboratory, European Spallation Source,
5// Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
6// SPDX - License - Identifier: GPL - 3.0 +
8
9using namespace Mantid::Kernel;
10using namespace Mantid::API;
11
12namespace Mantid::MDAlgorithms {
13
14// Register the algorithm into the AlgorithmFactory
15DECLARE_ALGORITHM(ExponentialMD)
16
17//----------------------------------------------------------------------------------------------
19const std::string ExponentialMD::name() const { return "ExponentialMD"; }
20
22int ExponentialMD::version() const { return 1; }
23
24//----------------------------------------------------------------------------------------------
25
26//----------------------------------------------------------------------------------------------
29 if (!m_in_histo)
30 throw std::runtime_error(this->name() + " can only be run on a MDHistoWorkspace.");
31}
32
33//----------------------------------------------------------------------------------------------
36 throw std::runtime_error(this->name() + " can only be run on a MDHistoWorkspace.");
37}
38
39//----------------------------------------------------------------------------------------------
42
43} // namespace Mantid::MDAlgorithms
std::string name
Definition Run.cpp:60
#define DECLARE_ALGORITHM(classname)
Definition Algorithm.h:538
ExponentialMD : exponential function on MDHistoWorkspace.
int version() const override
Algorithm's version for identification.
const std::string name() const override
Algorithm's name for identification.
void checkInputs() override
Check the inputs and throw if the algorithm cannot be run.
void execEvent(Mantid::API::IMDEventWorkspace_sptr out) override
Run the algorithm on a MDEventWorkspace.
void execHisto(Mantid::DataObjects::MDHistoWorkspace_sptr out) override
Run the algorithm with a MDHistoWorkspace.
Mantid::DataObjects::MDHistoWorkspace_sptr m_in_histo
Input workspace (MDHisto)
std::shared_ptr< IMDEventWorkspace > IMDEventWorkspace_sptr
Shared pointer to Mantid::API::IMDEventWorkspace.
std::shared_ptr< MDHistoWorkspace > MDHistoWorkspace_sptr
A shared pointer to a MDHistoWorkspace.
STL namespace.