Struct mysql::time::Timespec [−][src]
A record specifying a time value in seconds and nanoseconds, where nanoseconds represent the offset from the given second.
For example a timespec of 1.2 seconds after the beginning of the epoch would be represented as {sec: 1, nsec: 200000000}.
Fields
sec: i64
nsec: i32
Methods
impl Timespec
[src]
impl Timespec
Trait Implementations
impl FromValue for Timespec
[src]
impl FromValue for Timespec
type Intermediate = ParseIr<Timespec>
fn from_value(v: Value) -> Timespec
[src]
fn from_value(v: Value) -> Timespec
Will panic if could not convert v
to Self
.
fn from_value_opt(v: Value) -> Result<Self, FromValueError>
[src]
fn from_value_opt(v: Value) -> Result<Self, FromValueError>
Will return Err(Error::FromValueError(v))
if could not convert v
to Self
.
fn get_intermediate(v: Value) -> Result<Self::Intermediate, FromValueError>
[src]
fn get_intermediate(v: Value) -> Result<Self::Intermediate, FromValueError>
Will return Err(Error::FromValueError(v))
if v
is not convertible to Self
.
impl ConvIr<Timespec> for ParseIr<Timespec>
[src]
impl ConvIr<Timespec> for ParseIr<Timespec>
fn new(v: Value) -> Result<ParseIr<Timespec>, FromValueError>
[src]
fn new(v: Value) -> Result<ParseIr<Timespec>, FromValueError>
fn commit(self) -> Timespec
[src]
fn commit(self) -> Timespec
fn rollback(self) -> Value
[src]
fn rollback(self) -> Value
impl From<Timespec> for Value
[src]
impl From<Timespec> for Value
impl Add<Duration> for Timespec
[src]
impl Add<Duration> for Timespec
type Output = Timespec
The resulting type after applying the +
operator.
fn add(self, other: Duration) -> Timespec
[src]
fn add(self, other: Duration) -> Timespec
Performs the +
operation.
impl PartialOrd<Timespec> for Timespec
[src]
impl PartialOrd<Timespec> for Timespec
fn partial_cmp(&self, other: &Timespec) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Timespec) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Timespec) -> bool
[src]
fn lt(&self, other: &Timespec) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Timespec) -> bool
[src]
fn le(&self, other: &Timespec) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Timespec) -> bool
[src]
fn gt(&self, other: &Timespec) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Timespec) -> bool
[src]
fn ge(&self, other: &Timespec) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Hash for Timespec
[src]
impl Hash for Timespec
fn hash<__H>(&self, state: &mut __H) where
__H: Hasher,
[src]
fn hash<__H>(&self, state: &mut __H) where
__H: Hasher,
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Sub<Timespec> for Timespec
[src]
impl Sub<Timespec> for Timespec
type Output = Duration
The resulting type after applying the -
operator.
fn sub(self, other: Timespec) -> Duration
[src]
fn sub(self, other: Timespec) -> Duration
Performs the -
operation.
impl Sub<Duration> for Timespec
[src]
impl Sub<Duration> for Timespec
type Output = Timespec
The resulting type after applying the -
operator.
fn sub(self, other: Duration) -> Timespec
[src]
fn sub(self, other: Duration) -> Timespec
Performs the -
operation.
impl Clone for Timespec
[src]
impl Clone for Timespec
fn clone(&self) -> Timespec
[src]
fn clone(&self) -> Timespec
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 Debug for Timespec
[src]
impl Debug for Timespec
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
[src]
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
Formats the value using the given formatter. Read more
impl Copy for Timespec
[src]
impl Copy for Timespec
impl Ord for Timespec
[src]
impl Ord for Timespec
fn cmp(&self, other: &Timespec) -> Ordering
[src]
fn cmp(&self, other: &Timespec) -> 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 Eq for Timespec
[src]
impl Eq for Timespec
impl PartialEq<Timespec> for Timespec
[src]
impl PartialEq<Timespec> for Timespec