#include <constraints.hpp>
Public Member Functions | |
| bool | check (const V &value, std::string &error) const |
Public Attributes | |
| std::function< bool(const V &)> | predicate |
| std::string | message |
Custom constraint.
| V | the value type |
| bool anch::val::Custom< V >::check | ( | const V & | value, |
| std::string & | error ) const |
Check value
| value | the value |
| error | the error message (set when value is invalid) |
true when value is valid | std::string anch::val::Custom< V >::message |
Error message
| std::function<bool(const V&)> anch::val::Custom< V >::predicate |
Predicate: true when value is valid