|
DocWire SDK
DocWire SDK: Award-winning modern data processing in C++20. SourceForge Community Choice & Microsoft support. AI-driven processing. Supports nearly 100 data formats, including email boxes and OCR. Boost efficiency in text extraction, web data extraction, data mining, document analysis. Offline processing possible for security and confidentiality
|
A wrapper for numeric types that enforces a range [Min, Max]. More...
#include <ranged.h>
Public Member Functions | |
| ranged (T value) | |
| Constructs a ranged value, enforcing the bounds in strict mode. More... | |
| operator T () const | |
| Implicit conversion to the underlying type. | |
| T | get () const |
A wrapper for numeric types that enforces a range [Min, Max].
In strict mode, the constructor checks if the value is within the specified range and throws an exception if the invariant is violated. In relaxed mode, this wrapper is a zero-cost abstraction with no runtime checks.
| Min | The minimum allowed value (or unlimited). |
| Max | The maximum allowed value (or unlimited). |
| T | The underlying numeric type. |
| safety_level | The safety policy to apply. |
|
inline |