Struct nix::sys::time::TimeVal
[−]
[src]
#[repr(C)]pub struct TimeVal { pub tv_sec: time_t, pub tv_usec: suseconds_t, }
Fields
tv_sec: time_t
tv_usec: suseconds_t
Methods
impl TimeVal
[src]
impl TimeVal
pub fn zero() -> TimeVal
[src]
pub fn zero() -> TimeVal
pub fn hours(hours: i64) -> TimeVal
[src]
pub fn hours(hours: i64) -> TimeVal
pub fn minutes(minutes: i64) -> TimeVal
[src]
pub fn minutes(minutes: i64) -> TimeVal
pub fn seconds(seconds: i64) -> TimeVal
[src]
pub fn seconds(seconds: i64) -> TimeVal
pub fn milliseconds(milliseconds: i64) -> TimeVal
[src]
pub fn milliseconds(milliseconds: i64) -> TimeVal
pub fn microseconds(microseconds: i64) -> TimeVal
[src]
pub fn microseconds(microseconds: i64) -> TimeVal
Makes a new TimeVal
with given number of microseconds.
pub fn num_hours(&self) -> i64
[src]
pub fn num_hours(&self) -> i64
pub fn num_minutes(&self) -> i64
[src]
pub fn num_minutes(&self) -> i64
pub fn num_seconds(&self) -> i64
[src]
pub fn num_seconds(&self) -> i64
pub fn num_milliseconds(&self) -> i64
[src]
pub fn num_milliseconds(&self) -> i64
pub fn num_microseconds(&self) -> i64
[src]
pub fn num_microseconds(&self) -> i64
Trait Implementations
impl Clone for TimeVal
[src]
impl Clone for TimeVal
fn clone(&self) -> TimeVal
[src]
fn clone(&self) -> TimeVal
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl Copy for TimeVal
[src]
impl Copy for TimeVal
impl PartialEq for TimeVal
[src]
impl PartialEq for TimeVal
fn eq(&self, __arg_0: &TimeVal) -> bool
[src]
fn eq(&self, __arg_0: &TimeVal) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &TimeVal) -> bool
[src]
fn ne(&self, __arg_0: &TimeVal) -> bool
This method tests for !=
.
impl Eq for TimeVal
[src]
impl Eq for TimeVal
impl PartialOrd for TimeVal
[src]
impl PartialOrd for TimeVal
fn partial_cmp(&self, __arg_0: &TimeVal) -> Option<Ordering>
[src]
fn partial_cmp(&self, __arg_0: &TimeVal) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, __arg_0: &TimeVal) -> bool
[src]
fn lt(&self, __arg_0: &TimeVal) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, __arg_0: &TimeVal) -> bool
[src]
fn le(&self, __arg_0: &TimeVal) -> 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: &TimeVal) -> bool
[src]
fn gt(&self, __arg_0: &TimeVal) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, __arg_0: &TimeVal) -> bool
[src]
fn ge(&self, __arg_0: &TimeVal) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Ord for TimeVal
[src]
impl Ord for TimeVal
fn cmp(&self, __arg_0: &TimeVal) -> Ordering
[src]
fn cmp(&self, __arg_0: &TimeVal) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
impl Debug for TimeVal
[src]
impl Debug for TimeVal
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Neg for TimeVal
[src]
impl Neg for TimeVal
type Output = TimeVal
The resulting type after applying the -
operator.
fn neg(self) -> TimeVal
[src]
fn neg(self) -> TimeVal
Performs the unary -
operation.
impl Add for TimeVal
[src]
impl Add for TimeVal
type Output = TimeVal
The resulting type after applying the +
operator.
fn add(self, rhs: TimeVal) -> TimeVal
[src]
fn add(self, rhs: TimeVal) -> TimeVal
Performs the +
operation.
impl Sub for TimeVal
[src]
impl Sub for TimeVal
type Output = TimeVal
The resulting type after applying the -
operator.
fn sub(self, rhs: TimeVal) -> TimeVal
[src]
fn sub(self, rhs: TimeVal) -> TimeVal
Performs the -
operation.
impl Mul<i32> for TimeVal
[src]
impl Mul<i32> for TimeVal
type Output = TimeVal
The resulting type after applying the *
operator.
fn mul(self, rhs: i32) -> TimeVal
[src]
fn mul(self, rhs: i32) -> TimeVal
Performs the *
operation.
impl Div<i32> for TimeVal
[src]
impl Div<i32> for TimeVal
type Output = TimeVal
The resulting type after applying the /
operator.
fn div(self, rhs: i32) -> TimeVal
[src]
fn div(self, rhs: i32) -> TimeVal
Performs the /
operation.
impl Display for TimeVal
[src]
impl Display for TimeVal