pub trait ToDuration {
// Required method
fn to_duration(&self) -> SignedDuration;
}Expand description
Convert a Decimal amount of hours to a SignedDuration.
Required Methods§
Sourcefn to_duration(&self) -> SignedDuration
fn to_duration(&self) -> SignedDuration
Convert a Decimal amount of hours to a SignedDuration.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl ToDuration for Decimal
impl ToDuration for Decimal
Source§fn to_duration(&self) -> SignedDuration
fn to_duration(&self) -> SignedDuration
Convert a Decimal amount of hours to a SignedDuration.
Round to the maximal precision of SignedDuration which is nanoseconds.