Mantid
Loading...
Searching...
No Matches
StartsWithValidator.h
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2008 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 <set>
13#include <string>
14#include <vector>
15
16namespace Mantid {
17namespace Kernel {
23public:
25 StartsWithValidator(const std::vector<std::string> &values);
26 StartsWithValidator(const std::set<std::string> &values);
27 IValidator_sptr clone() const override;
28
33 template <std::size_t SIZE>
34 StartsWithValidator(const std::array<std::string, SIZE> &values) : Kernel::StringListValidator(values) {}
35
36protected:
37 std::string checkValidity(const std::string &value) const override;
38};
39
40} // namespace Kernel
41} // namespace Mantid
double value
The value of the point.
Definition: FitMW.cpp:51
#define DLLExport
Definitions of the DLLImport compiler directives for MSVC.
Definition: System.h:53
ListValidator is a validator that requires the value of a property to be one of a defined list of pos...
Definition: ListValidator.h:29
StartsWithValidator is a validator that requires the value of a property to start with one of the str...
StartsWithValidator(const std::array< std::string, SIZE > &values)
Constructor.
std::shared_ptr< IValidator > IValidator_sptr
A shared_ptr to an IValidator.
Definition: IValidator.h:26
Helper class which provides the Collimation Length for SANS instruments.