Mantid
Loading...
Searching...
No Matches
RebinParamsValidator.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#include <boost/python/class.hpp>
9#include <boost/python/default_call_policies.hpp>
10#include <boost/python/make_constructor.hpp>
11
14using namespace boost::python;
15
16namespace {
17RebinParamsValidator *createRebinParamsValidator(bool allowEmpty, bool allowRange) {
18 return new RebinParamsValidator(allowEmpty, allowRange);
19}
20} // namespace
21
23 class_<RebinParamsValidator, bases<IValidator>, boost::noncopyable>("RebinParamsValidator")
24 .def("__init__",
25 make_constructor(&createRebinParamsValidator, default_call_policies(),
26 (arg("AllowEmpty") = false, arg("AllowRange") = false)),
27 "Constructs a validator verifying that the given float array is "
28 "valid sequence of rebinning parameters.");
29}
void export_RebinParamsValidator()
IValidator is the basic interface for all validators for properties.
Definition: IValidator.h:43
Validator to check the format of a vector providing the rebin parameters to an algorithm.