[−][src]Struct livesplit_core::timing::Time
A time that can store a Real Time and a Game Time. Both of them are optional.
Fields
real_time: Option<TimeSpan>
The Real Time value.
game_time: Option<TimeSpan>
The Game Time value.
Methods
impl Time
[src]
pub fn new() -> Self
[src]
Creates a new Time with empty Real Time and Game Time.
pub fn zero() -> Self
[src]
Creates a new Time where Real Time and Game Time are zero. Keep in mind
that a zero Time Span is not the same as a None
Time Span as created
by Time::new()
.
pub fn with_real_time(self, real_time: Option<TimeSpan>) -> Self
[src]
Creates a new Time based on the current one where the Real Time is replaced by the given Time Span.
pub fn with_game_time(self, game_time: Option<TimeSpan>) -> Self
[src]
Creates a new Time based on the current one where the Game Time is replaced by the given Time Span.
pub fn with_timing_method(
self,
timing_method: TimingMethod,
time: Option<TimeSpan>
) -> Self
[src]
self,
timing_method: TimingMethod,
time: Option<TimeSpan>
) -> Self
Creates a new Time based on the current one where the specified timing method is replaced by the given Time Span.
pub fn op<F>(a: Time, b: Time, f: F) -> Time where
F: FnMut(TimeSpan, TimeSpan) -> TimeSpan,
[src]
F: FnMut(TimeSpan, TimeSpan) -> TimeSpan,
Applies an operation to both Timing Methods of the two times provided and creates a new Time from the result.
Trait Implementations
impl From<Option<Duration>> for Time
[src]
impl From<Option<RunTime>> for Time
[src]
impl From<RealTime> for Time
[src]
impl From<GameTime> for Time
[src]
impl Copy for Time
[src]
impl PartialEq<Time> for Time
[src]
impl Eq for Time
[src]
impl Clone for Time
[src]
fn clone(&self) -> Time
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Default for Time
[src]
impl Add<Time> for Time
[src]
type Output = Time
The resulting type after applying the +
operator.
fn add(self, rhs: Time) -> Self
[src]
impl Sub<Time> for Time
[src]
type Output = Time
The resulting type after applying the -
operator.
fn sub(self, rhs: Time) -> Self
[src]
impl AddAssign<Time> for Time
[src]
fn add_assign(&mut self, rhs: Time)
[src]
impl SubAssign<Time> for Time
[src]
fn sub_assign(&mut self, rhs: Time)
[src]
impl Index<TimingMethod> for Time
[src]
type Output = Option<TimeSpan>
The returned type after indexing.
fn index(&self, timing_method: TimingMethod) -> &Self::Output
[src]
impl IndexMut<TimingMethod> for Time
[src]
fn index_mut(&mut self, timing_method: TimingMethod) -> &mut Self::Output
[src]
impl Debug for Time
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
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.
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.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
D: AdaptFrom<S, Swp, Dwp, T>,
Dwp: WhitePoint,
Swp: WhitePoint,
T: Component + Float,
[src]
D: AdaptFrom<S, Swp, Dwp, T>,
Dwp: WhitePoint,
Swp: WhitePoint,
T: Component + Float,
fn adapt_into_using<M>(self, method: M) -> D where
M: TransformMatrix<Swp, Dwp, T>,
[src]
M: TransformMatrix<Swp, Dwp, T>,
fn adapt_into(self) -> D
[src]
Convert the source color to the destination color using the bradford method by default Read more
impl<T> SetParameter for T
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
T: Parameter<Self>,
Sets value
as a parameter of self
.
impl<Q, K> Equivalent<K> for Q where
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
[src]
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,