Time::to_ratio
This commit is contained in:
parent
4bd5815184
commit
734be35937
@ -41,6 +41,10 @@ impl Time{
|
||||
pub const fn nanos(self)->i64{
|
||||
self.0
|
||||
}
|
||||
#[inline]
|
||||
pub const fn to_ratio(self)->Ratio<Planar64,Planar64>{
|
||||
Ratio::new(Planar64::raw(self.0),Planar64::raw(1_000_000_000))
|
||||
}
|
||||
}
|
||||
impl From<Planar64> for Time{
|
||||
#[inline]
|
||||
|
Loading…
Reference in New Issue
Block a user