[#mp_units-wrap_to_range] = xref:mp_units.adoc[mp_units]::wrap_to_range :relfileprefix: ../ :mrdocs: Policy that wraps the value into the half‐open range [min, max).] == Synopsis Declared in `<mp‐units/overflow_policies.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<xref:mp_units/Quantity.adoc[Quantity] Q> struct wrap_to_range; ---- == Description Uses modulo arithmetic to wrap values into the range. Use for periodic/cyclic quantities (angles, time‐of‐day, etc.). For example, with [0°, 360°): 370° ‐> 10°, ‐10° ‐> 350°.] == Member Functions [cols=1] |=== | Name | xref:mp_units/wrap_to_range/operator_call.adoc[`operator()`] |=== == Data Members [cols=1] |=== | Name | xref:mp_units/wrap_to_range/max.adoc[`max`] | xref:mp_units/wrap_to_range/min.adoc[`min`] |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#