16using namespace Geometry;
18using Kernel::Direction;
36 "Workspace to clear the mask flag of.");
38 "Specify the instrument component to clear the "
39 "mask. If empty clears the mask flag for "
40 "the whole instrument.");
48 auto &detectorInfo = ws->mutableDetectorInfo();
50 if (!componentName.empty()) {
51 std::vector<IDetector_const_sptr> detectors;
52 ws->getInstrument()->getDetectorsInBank(detectors, componentName);
53 for (
const auto &det : detectors) {
54 auto index = detectorInfo.indexOf(det->getID());
55 detectorInfo.setMasked(
index,
false);
58 detectorInfo.clearMaskFlags();
#define DECLARE_ALGORITHM(classname)
std::map< DeltaEMode::Type, std::string > index
void declareProperty(std::unique_ptr< Kernel::Property > p, const std::string &doc="") override
Add a property to the list of managed properties.
std::string getPropertyValue(const std::string &name) const override
Get the value of a property as a string.
TypedValue getProperty(const std::string &name) const override
Get the value of a property.
A property class for workspaces.
ClearMaskFlag : Delete the mask flag/bit on all spectra in a workspace.
void exec() override
Execute the algorithm.
void init() override
Initialize the algorithm's properties.
int version() const override
Algorithm's version for identification.
const std::string category() const override
Algorithm's category for identification.
std::shared_ptr< MatrixWorkspace > MatrixWorkspace_sptr
shared pointer to the matrix workspace base class
@ InOut
Both an input & output workspace.