AuboStudio SDK 0.6.3

Public 成员函数 | Private 成员函数 | Private 属性 | 所有成员列表
arcs::aubo_scope::DoubleRangeValidator结构体 参考

`#include <input_validator.h>`

类 arcs::aubo_scope::DoubleRangeValidator 继承关系图:
[图例]
arcs::aubo_scope::DoubleRangeValidator 的协作图:
[图例]

## Public 成员函数
| DoubleRangeValidator (double minValue, double maxValue, bool is_min_inclusive=true, bool is_max_inclusive=true)
| DoubleRangeValidator (std::function< std::pair< double, double >()> range_func)
| DoubleRangeValidator (std::function< std::tuple< double, double, bool, bool >()> range_func)
bool | isValid (std::string value) override
std::string | getMessage (std::string value) override
| Returns a meaningful message in case the value is not valid. 更多...

## Private 成员函数
void | updateValue ()

## Private 属性
double | min_value_ { DBL_MIN }
double | max_value_ { DBL_MAX }
std::function< std::pair< double, double >)> | range_func_ { nullptr }
std::function< std::tuple< double, double, bool, bool >)> | range_func_with_flags_ { nullptr }
bool | is_min_inclusive_ { true }
bool | is_max_inclusive_ { true }

## 详细描述

在文件 input_validator.h 第 89 行定义.

## 构造及析构函数说明

## ◆ DoubleRangeValidator() [1/3]

arcs::aubo_scope::DoubleRangeValidator::DoubleRangeValidator | ( | double | minValue,
|  | double | maxValue,
|  | bool | is_min_inclusive = `true`,
|  | bool | is_max_inclusive = `true`
| ) |  |

## ◆ DoubleRangeValidator() [2/3]

arcs::aubo_scope::DoubleRangeValidator::DoubleRangeValidator | ( | std::function< std::pair< double, double >()> | range_func | ) |

## ◆ DoubleRangeValidator() [3/3]

arcs::aubo_scope::DoubleRangeValidator::DoubleRangeValidator | ( | std::function< std::tuple< double, double, bool, bool >()> | range_func | ) |

## 成员函数说明

## ◆ getMessage()

std::string arcs::aubo_scope::DoubleRangeValidator::getMessage | ( | std::string | value | ) |
| override virtual

Returns a meaningful message in case the value is not valid.

参数

  value | the invalid value. Can be included in the message if it makes sense.

返回
  message.

实现了 arcs::aubo_scope::InputValidator.

## ◆ isValid()

bool arcs::aubo_scope::DoubleRangeValidator::isValid | ( | std::string | value | ) |
| override virtual

参数

  value | to be validated.

返回
  `true` if value is valid.

实现了 arcs::aubo_scope::InputValidator.

## ◆ updateValue()

void arcs::aubo_scope::DoubleRangeValidator::updateValue | ( |  | ) |
| private

## 类成员变量说明

## ◆ is_max_inclusive_

bool arcs::aubo_scope::DoubleRangeValidator::is_max_inclusive_ { true }
| private

在文件 input_validator.h 第 114 行定义.

## ◆ is_min_inclusive_

bool arcs::aubo_scope::DoubleRangeValidator::is_min_inclusive_ { true }
| private

在文件 input_validator.h 第 113 行定义.

## ◆ max_value_

double arcs::aubo_scope::DoubleRangeValidator::max_value_ { DBL_MAX }
| private

在文件 input_validator.h 第 109 行定义.

## ◆ min_value_

double arcs::aubo_scope::DoubleRangeValidator::min_value_ { DBL_MIN }
| private

在文件 input_validator.h 第 108 行定义.

## ◆ range_func_

std::function<std::pair<double, double>)> arcs::aubo_scope::DoubleRangeValidator::range_func_ { nullptr }
| private

在文件 input_validator.h 第 110 行定义.

## ◆ range_func_with_flags_

std::function<std::tuple<double, double, bool, bool>)> arcs::aubo_scope::DoubleRangeValidator::range_func_with_flags_ { nullptr }
| private

在文件 input_validator.h 第 112 行定义.

该结构体的文档由以下文件生成:

- include/aubo_caps/domain/user_interface/input_validator.h