pub struct Moment(/* private fields */);
Expand description
Moment in time, in milliseconds relative to the start of the media file
Implementations§
source§impl Moment
impl Moment
sourcepub fn as_vtt_timestamp(&self) -> String
pub fn as_vtt_timestamp(&self) -> String
Convert to .vtt timestamp format (HH:MM:SS.0ms
)
sourcepub fn as_srt_timestamp(&self) -> String
pub fn as_srt_timestamp(&self) -> String
Convert to .srt timestamp format (HH:MM:SS,0ms
)
sourcepub fn as_substation_timestamp(&self) -> String
pub fn as_substation_timestamp(&self) -> String
Convert to .ass timestamp format (H:MM:SS,cs
)
Trait Implementations§
source§impl AddAssign<TimeDelta> for Moment
impl AddAssign<TimeDelta> for Moment
source§fn add_assign(&mut self, rhs: TimeDelta)
fn add_assign(&mut self, rhs: TimeDelta)
Performs the
+=
operation. Read moresource§impl Ord for Moment
impl Ord for Moment
source§impl PartialEq for Moment
impl PartialEq for Moment
source§impl PartialOrd for Moment
impl PartialOrd for Moment
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl SubAssign<TimeDelta> for Moment
impl SubAssign<TimeDelta> for Moment
source§fn sub_assign(&mut self, rhs: TimeDelta)
fn sub_assign(&mut self, rhs: TimeDelta)
Performs the
-=
operation. Read moreimpl Copy for Moment
impl Eq for Moment
impl StructuralEq for Moment
impl StructuralPartialEq for Moment
Auto Trait Implementations§
impl RefUnwindSafe for Moment
impl Send for Moment
impl Sync for Moment
impl Unpin for Moment
impl UnwindSafe for Moment
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more