logo
pub struct ArchivedDuration { /* private fields */ }
Expand description

An archived Duration.

Implementations

Returns the number of whole seconds contained by this ArchivedDuration.

The returned value does not include the fractional (nanosecond) part of the duration, which can be obtained using subsec_nanos.

Returns the fractional part of this ArchivedDuration, in whole milliseconds.

This method does not return the length of the duration when represented by milliseconds. The returned number always represents a fractional portion of a second (i.e., it is less than one thousand).

Returns the fractional part of this ArchivedDuration, in whole microseconds.

This method does not return the length of the duration when represented by microseconds. The returned number always represents a fractional portion of a second (i.e., it is less than one million).

Returns the fractional part of this Duration, in nanoseconds.

This method does not return the length of the duration when represented by nanoseconds. The returned number always represents a fractional portion of a second (i.e., it is less than one billion).

Returns the total number of whole milliseconds contained by this ArchivedDuration.

Returns the total number of whole microseconds contained by this ArchivedDuration.

Returns the total number of nanoseconds contained by this ArchivedDuration.

Returns the number of seconds contained by this ArchivedDuration as f64.

The returned value does include the fractional (nanosecond) part of the duration.

Returns the number of seconds contained by this ArchivedDuration as f32.

The returned value does include the fractional (nanosecond) part of the duration.

Constructs an archived duration at the given position.

Safety

out must point to memory suitable for holding an ArchivedDuration.

Trait Implementations

The error that may result from checking the type.

Checks whether the given pointer points to a valid value within the given context. Read more

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Deserializes using the given deserializer

Deserializes the field type F using the given deserializer.

Converts to this type from the input type.

Feeds this value into the given Hasher. Read more

Feeds a slice of this type into the given Hasher. Read more

This method returns an Ordering between self and other. Read more

Compares and returns the maximum of two values. Read more

Compares and returns the minimum of two values. Read more

Restrict a value to a certain interval. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

This method returns an ordering between self and other values if one exists. Read more

This method tests less than (for self and other) and is used by the < operator. Read more

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

This method tests greater than (for self and other) and is used by the > operator. Read more

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

The archived version of the pointer metadata for this type.

Converts some archived metadata to the pointer metadata for itself.

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Deserializes using the given deserializer

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Gets the layout of the type.

The type for metadata in pointers and references to Self.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.