Struct af_core::time::Span [−][src]
An inclusive span between a start and end time.
Implementations
impl Span[src]
pub fn new(a: Time, b: Time) -> Self[src]
Creates a new span between two given times.
The earlier time becomes the start time, and the later time becomes the end time.
pub fn contains(&self, time: Time) -> bool[src]
Returns true if a given time is contained with the span.
pub fn duration(&self) -> Duration[src]
Returns a Duration equal to the time span in length.
pub fn end(&self) -> Time[src]
Returns the end time of the span.
pub fn overlaps(&self, rhs: Span) -> bool[src]
Returns true if the span overlaps another given span.
pub fn start(&self) -> Time[src]
Returns the start time of the span.
Trait Implementations
impl Add<Span> for Span[src]
type Output = Self
The resulting type after applying the + operator.
fn add(self, rhs: Self) -> Self::Output[src]
impl Add<Time> for Span[src]
type Output = Self
The resulting type after applying the + operator.
fn add(self, rhs: Time) -> Self::Output[src]
impl AddAssign<Span> for Span[src]
fn add_assign(&mut self, rhs: Self)[src]
impl AddAssign<Time> for Span[src]
fn add_assign(&mut self, rhs: Time)[src]
impl Clone for Span[src]
impl Copy for Span[src]
impl Debug for Span[src]
impl Display for Span[src]
impl Eq for Span[src]
impl From<Range<Time>> for Span[src]
impl From<RangeInclusive<Time>> for Span[src]
fn from(range: RangeInclusive<Time>) -> Self[src]
impl From<Time> for Span[src]
impl PartialEq<Span> for Span[src]
impl StructuralEq for Span[src]
impl StructuralPartialEq for Span[src]
Auto Trait Implementations
impl RefUnwindSafe for Span
impl Send for Span
impl Sync for Span
impl Unpin for Span
impl UnwindSafe for Span
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut Tⓘ[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn clone_into(&self, target: &mut T)[src]
impl<T> ToString for T where
T: Display + ?Sized, [src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,