Mantid
Loading...
Searching...
No Matches
MultiPeriodGroupWorker.h
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2014 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 +
7#pragma once
8
11#include "MantidKernel/System.h"
12#include <memory>
13#include <string>
14#include <vector>
15
16namespace Mantid {
17namespace API {
18
30class MANTID_API_DLL MultiPeriodGroupWorker {
31public:
33 using VecWSGroupType = std::vector<WorkspaceGroup_sptr>;
37 MultiPeriodGroupWorker(std::string workspacePropertyName);
38 virtual ~MultiPeriodGroupWorker() = default;
40 bool useCustomWorkspaceProperty() const;
42 VecWSGroupType findMultiPeriodGroups(Algorithm const *const sourceAlg) const;
44 bool processGroups(Algorithm *const sourceAlg, const VecWSGroupType &vecMultiPeriodGroups) const;
45
46private:
47 // Disable copy
49 // Disable assignment
51
53 void tryAddInputWorkspaceToInputGroups(const Workspace_sptr &ws, VecWSGroupType &vecMultiPeriodWorkspaceGroups,
54 VecWSGroupType &vecWorkspaceGroups) const;
55
57 void copyInputWorkspaceProperties(IAlgorithm *targetAlg, IAlgorithm *sourceAlg, const int &periodNumber) const;
58
60 std::string createFormattedInputWorkspaceNames(const size_t &periodIndex,
61 const VecWSGroupType &vecWorkspaceGroups) const;
62
64 void validateMultiPeriodGroupInputs(const VecWSGroupType &vecMultiPeriodGroups) const;
65
68};
69
70} // namespace API
71} // namespace Mantid
Base class from which all concrete algorithm classes should be derived.
Definition: Algorithm.h:85
IAlgorithm is the interface implemented by the Algorithm base class.
Definition: IAlgorithm.h:45
MultiPeriodGroupWorker : Multiperiod group logic relating to determining a valid multiperiod group,...
MultiPeriodGroupWorker & operator=(const MultiPeriodGroupWorker &)
MultiPeriodGroupWorker()=default
Constructor.
MultiPeriodGroupWorker(const MultiPeriodGroupWorker &)
virtual ~MultiPeriodGroupWorker()=default
std::vector< WorkspaceGroup_sptr > VecWSGroupType
Convenience typdef for workspace names.
std::string m_workspacePropertyName
Workspace property name.
std::shared_ptr< Workspace > Workspace_sptr
shared pointer to Mantid::API::Workspace
Definition: Workspace_fwd.h:20
Helper class which provides the Collimation Length for SANS instruments.