Struct livesplit_core::time_span::TimeSpan
[−]
[src]
pub struct TimeSpan(_);
Methods
impl TimeSpan
[src]
fn zero() -> Self
fn from_milliseconds(milliseconds: f64) -> Self
fn from_seconds(seconds: f64) -> Self
fn from_days(days: f64) -> Self
fn option_op<F, R>(a: Option<TimeSpan>, b: Option<TimeSpan>, f: F) -> Option<R> where F: FnOnce(TimeSpan, TimeSpan) -> R
fn to_duration(&self) -> Duration
fn total_seconds(&self) -> f64
fn parse_opt<S>(text: S) -> Result<Option<TimeSpan>, ParseError> where S: AsRef<str>
Trait Implementations
impl From<Duration> for TimeSpan
[src]
impl Add for TimeSpan
[src]
type Output = TimeSpan
The resulting type after applying the +
operator
fn add(self, rhs: TimeSpan) -> TimeSpan
The method for the +
operator
impl Sub for TimeSpan
[src]
type Output = TimeSpan
The resulting type after applying the -
operator
fn sub(self, rhs: TimeSpan) -> TimeSpan
The method for the -
operator
impl Neg for TimeSpan
[src]
type Output = TimeSpan
The resulting type after applying the -
operator
fn neg(self) -> TimeSpan
The method for the unary -
operator
impl Copy for TimeSpan
[src]
impl Clone for TimeSpan
[src]
fn clone(&self) -> TimeSpan
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Debug for TimeSpan
[src]
impl Eq for TimeSpan
[src]
impl PartialEq for TimeSpan
[src]
fn eq(&self, __arg_0: &TimeSpan) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &TimeSpan) -> bool
This method tests for !=
.
impl Ord for TimeSpan
[src]
fn cmp(&self, __arg_0: &TimeSpan) -> Ordering
This method returns an Ordering
between self
and other
. Read more
impl PartialOrd for TimeSpan
[src]
fn partial_cmp(&self, __arg_0: &TimeSpan) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, __arg_0: &TimeSpan) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, __arg_0: &TimeSpan) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, __arg_0: &TimeSpan) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, __arg_0: &TimeSpan) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl FromStr for TimeSpan
[src]
type Err = ParseError
The associated error which can be returned from parsing.
fn from_str(text: &str) -> Result<Self, ParseError>
Parses a string s
to return a value of this type. Read more
impl Default for TimeSpan
[src]
impl From<StdDuration> for TimeSpan
[src]
fn from(duration: StdDuration) -> Self
Performs the conversion.
impl AddAssign for TimeSpan
[src]
fn add_assign(&mut self, rhs: TimeSpan)
The method for the +=
operator
impl SubAssign for TimeSpan
[src]
fn sub_assign(&mut self, rhs: TimeSpan)
The method for the -=
operator