mp_units::representation_values¶
A type trait that defines zero, one, min, and max for a representation type
Synopsis¶
Declared in <mp-units/framework/customization_points.h>
template<typename Rep>
struct representation_values : std::chrono::duration_values<Rep>
Description¶
The zero, one, min, and max member functions in mp_units::quantity forward their work to these methods. This type can be specialized if the representation Rep requires a specific implementation to return these quantity objects.
The primary template provides zero() and one() only for a scalar type constructible from int. A vector or a tensor type specializes it to provide zero(), which is what a quantity of it, and zero, compare against.
Base Classes¶
| Name | Description |
|---|---|
std::chrono::duration_values<Rep> |
Static Member Functions¶
Specializations¶
| Name |
|---|
representation_values<mp_units::utility::cartesian_tensor<T, N>> |
representation_values<mp_units::utility::cartesian_vector<T, N>> |
Template Parameters¶
| Name | Description |
|---|---|
| Rep | a representation type for which a type trait is defined |