diff options
Diffstat (limited to 'searchlib/src/vespa/searchcommon/attribute/persistent_predicate_params.h')
-rw-r--r-- | searchlib/src/vespa/searchcommon/attribute/persistent_predicate_params.h | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/searchlib/src/vespa/searchcommon/attribute/persistent_predicate_params.h b/searchlib/src/vespa/searchcommon/attribute/persistent_predicate_params.h index d81eb9c5d3c..205a75c188f 100644 --- a/searchlib/src/vespa/searchcommon/attribute/persistent_predicate_params.h +++ b/searchlib/src/vespa/searchcommon/attribute/persistent_predicate_params.h @@ -10,24 +10,23 @@ namespace search::attribute { * Persistent parameters for predicate attributes. */ class PersistentPredicateParams { - uint32_t _arity; int64_t _lower_bound; int64_t _upper_bound; + uint32_t _arity; public: - PersistentPredicateParams() - : _arity(8), - _lower_bound(std::numeric_limits<int64_t>::min()), - _upper_bound(std::numeric_limits<int64_t>::max()) - { - } - uint32_t arity() const { return _arity; } - int64_t lower_bound() const { return _lower_bound; } - int64_t upper_bound() const { return _upper_bound; } - void setArity(uint32_t v) { _arity = v; } - void setBounds(int64_t lower, int64_t upper) { _lower_bound = lower; _upper_bound = upper; } + PersistentPredicateParams() noexcept + : _lower_bound(std::numeric_limits<int64_t>::min()), + _upper_bound(std::numeric_limits<int64_t>::max()), + _arity(8) + { } + uint32_t arity() const noexcept { return _arity; } + int64_t lower_bound() const noexcept { return _lower_bound; } + int64_t upper_bound() const noexcept { return _upper_bound; } + void setArity(uint32_t v) noexcept { _arity = v; } + void setBounds(int64_t lower, int64_t upper) noexcept { _lower_bound = lower; _upper_bound = upper; } - bool operator==(const PersistentPredicateParams &rhs) const { + bool operator==(const PersistentPredicateParams &rhs) const noexcept { return ((_arity == rhs._arity) && (_lower_bound == rhs._lower_bound) && (_upper_bound == rhs._upper_bound)); |