|
Boost Users : |
Subject: [Boost-users] [units] Conversions from quantities
From: Michael Powell (mwpowellhtx_at_[hidden])
Date: 2015-08-12 18:39:12
Hello,
Just wanted to clarify something. These should convert from given
quantities to the desired units?
double
unit_conversion::from_length_to_inches(quantity<length> const & L) {
const quantity<inch_base_unit::unit_type> result_(L);
return result_.value();
}
double unit_conversion::from_mass_to_pounds(quantity<mass>
const & M) {
const quantity<ounce_base_unit::unit_type> result_(M);
return result_.value();
}
>From an earlier post, I think maybe so, but I was interested in expert
opinions, as well.
https://groups.google.com/forum/#!topic/boost-list/YDJoMcu1Xx4
Thank you...
Best regards,
Michael Powell
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net