Commit 2e6e5515 authored by Gigg, Martyn Anthony's avatar Gigg, Martyn Anthony
Browse files

Convert to summary method in MDEvent/MDAlgorithms

Refs #9523
parent ca9b3bf9
......@@ -41,14 +41,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "BinMD";}
///Summary of algorithms purpose
virtual const std::string summary() const {return "Take a MDEventWorkspace and bin into into a dense, multi-dimensional histogram workspace (MDHistoWorkspace).";}
/// Algorithm's version for identification
virtual int version() const { return 1;}
/// Algorithm's category for identification
virtual const std::string category() const { return "MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
/// Initialise the properties
void init();
/// Run the algorithm
......
......@@ -41,6 +41,9 @@ namespace MDAlgorithms
virtual ~BooleanBinaryOperationMD();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const;
virtual int version() const;
protected:
......@@ -48,8 +51,6 @@ namespace MDAlgorithms
virtual bool acceptScalar() const
{ return true; }
virtual bool commutative() const;
virtual void initDocs();
void checkInputs();
void execEvent();
virtual void execHistoScalar(Mantid::MDEvents::MDHistoWorkspace_sptr out, Mantid::DataObjects::WorkspaceSingleValue_const_sptr scalar);
......
......@@ -25,14 +25,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "CentroidPeaksMD";};
///Summary of algorithms purpose
virtual const std::string summary() const {return "Find the centroid of single-crystal peaks in a MDEventWorkspace, in order to refine their positions.";}
/// Algorithm's version for identification
virtual int version() const { return 1;};
/// Algorithm's category for identification
virtual const std::string category() const { return "MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
/// Initialise the properties
void init();
/// Run the algorithm
......
......@@ -25,14 +25,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "CentroidPeaksMD";};
///Summary of algorithms purpose
virtual const std::string summary() const {return "Find the centroid of single-crystal peaks in a MDEventWorkspace, in order to refine their positions.";}
/// Algorithm's version for identification
virtual int version() const { return 2;};
/// Algorithm's category for identification
virtual const std::string category() const { return "MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
/// Initialise the properties
void init();
/// Run the algorithm
......
......@@ -44,14 +44,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "CloneMDWorkspace";};
///Summary of algorithms purpose
virtual const std::string summary() const {return "Clones (copies) an existing MDEventWorkspace or MDHistoWorkspace into a new one.";}
/// Algorithm's version for identification
virtual int version() const { return 1;};
/// Algorithm's category for identification
virtual const std::string category() const { return "MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
/// Initialise the properties
void init();
/// Run the algorithm
......
......@@ -43,11 +43,13 @@ namespace MDAlgorithms
virtual ~CompareMDWorkspaces();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Compare two MDWorkspaces for equality.";}
virtual int version() const;
virtual const std::string category() const;
private:
virtual void initDocs();
void init();
void exec();
void doComparison();
......
......@@ -47,11 +47,13 @@ namespace MDAlgorithms
virtual ~ConvertToDetectorFaceMD();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Convert a MatrixWorkspace containing to a MD workspace for viewing the detector face.";}
virtual int version() const;
virtual const std::string category() const;
private:
virtual void initDocs();
void init();
void exec();
......
......@@ -33,14 +33,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "ConvertToDiffractionMDWorkspace";};
///Summary of algorithms purpose
virtual const std::string summary() const {return "Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) for an elastic diffraction experiment.";}
/// Algorithm's version for identification
virtual int version() const { return 1;};
/// Algorithm's category for identification
virtual const std::string category() const { return "MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
void init();
void exec();
......
......@@ -38,14 +38,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "ConvertToDiffractionMDWorkspace";};
///Summary of algorithms purpose
virtual const std::string summary() const {return "Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) for an elastic diffraction experiment.";}
/// Algorithm's version for identification
virtual int version() const { return 2;};
/// Algorithm's category for identification
virtual const std::string category() const { return "MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
void init();
void exec();
......
......@@ -57,6 +57,9 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Create a MDEventWorkspace with selected dimensions, e.g. the reciprocal space of momentums (Qx, Qy, Qz) or momentums modules |Q|, energy transfer dE if availible and any other user specified log values which can be treated as dimensions.";}
/// Algorithm's version for identification
virtual int version() const;
......@@ -65,8 +68,6 @@ namespace MDAlgorithms
std::map<std::string, std::string> validateInputs();
void exec();
void init();
/// Sets documentation strings for this algorithm
virtual void initDocs();
/// progress reporter
boost::scoped_ptr<API::Progress > m_Progress;
......
......@@ -39,11 +39,13 @@ namespace MDAlgorithms
virtual ~ConvertToMDMinMaxGlobal();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Calculate limits required for ConvertToMD";}
virtual int version() const;
virtual const std::string category() const;
private:
virtual void initDocs();
void init();
void exec();
......
......@@ -39,13 +39,15 @@ namespace MDAlgorithms
virtual ~ConvertToMDMinMaxLocal();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Calculate limits required for ConvertToMD";}
virtual int version() const{return 1;}
protected: // for testing
void findMinMaxValues(MDEvents::MDWSDescription &targWSDescr,
MDEvents::MDTransfInterface *const qTransf,Kernel::DeltaEMode::Type dEMode,
std::vector<double> &MinValues,std::vector<double> &MaxValues);
private:
virtual void initDocs();
void exec();
void init();
/// pointer to the input workspace;
......
......@@ -58,11 +58,6 @@ namespace MDAlgorithms
/// Algorithm's category for identification
virtual const std::string category() const;
private:
virtual void exec()=0;
/// Sets documentation strings for this algorithm
virtual void initDocs()=0;
//------------------------------------------------------------------------------------------------------------------------------------------
protected:
void init();
//
......
......@@ -40,11 +40,13 @@ namespace MDAlgorithms
virtual ~CreateMDHistoWorkspace();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Creates an MDHistoWorkspace from supplied lists of signal and error values.";}
virtual int version() const;
virtual const std::string category() const;
private:
virtual void initDocs();
void init();
void exec();
......
......@@ -28,14 +28,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "CreateMDWorkspace";};
///Summary of algorithms purpose
virtual const std::string summary() const {return "Creates an empty MDEventWorkspace with a given number of dimensions.";}
/// Algorithm's version for identification
virtual int version() const { return 1;};
/// Algorithm's category for identification
virtual const std::string category() const { return "MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
void init();
void exec();
......
......@@ -41,10 +41,12 @@ namespace MDAlgorithms
virtual ~DivideMD();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Divide MDHistoWorkspace's";}
virtual int version() const;
private:
virtual void initDocs();
/// Is the operation commutative?
bool commutative() const;
......
......@@ -41,10 +41,12 @@ namespace MDAlgorithms
virtual ~ExponentialMD();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Applies the exponential function on a MDHistoWorkspace.";}
virtual int version() const;
private:
virtual void initDocs();
/// Check the inputs and throw if the algorithm cannot be run
void checkInputs();
......
......@@ -31,14 +31,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "FakeMDEventData";};
///Summary of algorithms purpose
virtual const std::string summary() const {return "Adds fake multi-dimensional event data to an existing MDEventWorkspace, for use in testing.\nYou can create a blank MDEventWorkspace with CreateMDWorkspace.";}
/// Algorithm's version for identification
virtual int version() const { return 1;};
/// Algorithm's category for identification
virtual const std::string category() const { return "MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
/// Initialise the properties
void init();
/// Run the algorithm
......
......@@ -30,14 +30,15 @@ namespace MDAlgorithms
/// Algorithm's name for identification
virtual const std::string name() const { return "FindPeaksMD";};
///Summary of algorithms purpose
virtual const std::string summary() const {return "Find peaks in reciprocal space in a MDEventWorkspace or a MDHistoWorkspace.";}
/// Algorithm's version for identification
virtual int version() const { return 1;};
/// Algorithm's category for identification
virtual const std::string category() const { return "Optimization\\PeakFinding;MDAlgorithms";}
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
/// Initialise the properties
void init();
/// Run the algorithm
......
......@@ -41,11 +41,12 @@ namespace MDAlgorithms
virtual ~GreaterThanMD();
virtual const std::string name() const;
///Summary of algorithms purpose
virtual const std::string summary() const {return "Perform the GreaterThan boolean operation on two MDHistoWorkspaces.";}
virtual int version() const;
private:
/// Sets documentation strings for this algorithm
virtual void initDocs();
bool acceptScalar() const { return true; }
bool commutative() const { return false; }
......
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