blob: 9cc5339fcae9d504e91b7c8da9596761326ef322 [file] [log] [blame]
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="API documentation for the Rust `TimeValLike` trait in crate `nix`."><meta name="keywords" content="rust, rustlang, rust-lang, TimeValLike"><title>TimeValLike in nix::sys::time - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" href="../../../normalize.css"><link rel="stylesheet" href="../../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" href="../../../ayu.css" disabled><link rel="stylesheet" href="../../../dark.css" disabled><link rel="stylesheet" href="../../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../../main.js"></script><noscript><link rel="stylesheet" href="../../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../../favicon.svg"></head><body class="rustdoc trait"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle">&#9776;</button><a class="sidebar-logo" href="../../../nix/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div></a><h2></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../../nix/index.html"><div class="logo-container"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">TimeValLike</a></h2><div class="sidebar-elems"><section><h3><a href="#required-methods">Required Methods</a></h3><ul class="block"><li><a href="#tymethod.microseconds">microseconds</a></li><li><a href="#tymethod.milliseconds">milliseconds</a></li><li><a href="#tymethod.nanoseconds">nanoseconds</a></li><li><a href="#tymethod.num_microseconds">num_microseconds</a></li><li><a href="#tymethod.num_milliseconds">num_milliseconds</a></li><li><a href="#tymethod.num_nanoseconds">num_nanoseconds</a></li><li><a href="#tymethod.num_seconds">num_seconds</a></li><li><a href="#tymethod.seconds">seconds</a></li></ul><h3><a href="#provided-methods">Provided Methods</a></h3><ul class="block"><li><a href="#method.hours">hours</a></li><li><a href="#method.minutes">minutes</a></li><li><a href="#method.num_hours">num_hours</a></li><li><a href="#method.num_minutes">num_minutes</a></li><li><a href="#method.zero">zero</a></li></ul><h3><a href="#implementors">Implementors</a></h3></section><h2><a href="index.html">In nix::sys::time</a></h2></div></nav><main><div class="width-limiter"><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><a href="../../../help.html">?</a></div><div id="settings-menu" tabindex="-1"><a href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div></div></form></nav><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn">Trait <a href="../../index.html">nix</a>::<wbr><a href="../index.html">sys</a>::<wbr><a href="index.html">time</a>::<wbr><a class="trait" href="#">TimeValLike</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></h1><span class="out-of-band"><a class="srclink" href="../../../src/nix/sys/time.rs.html#143-184">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="item-decl"><pre class="rust trait"><code>pub trait TimeValLike: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a> {
<details class="rustdoc-toggle type-contents-toggle"><summary class="hideme"><span>Show 13 methods</span></summary> fn <a href="#tymethod.seconds" class="fnname">seconds</a>(seconds: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self;
<span class="item-spacer"></span> fn <a href="#tymethod.milliseconds" class="fnname">milliseconds</a>(milliseconds: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self;
<span class="item-spacer"></span> fn <a href="#tymethod.microseconds" class="fnname">microseconds</a>(microseconds: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self;
<span class="item-spacer"></span> fn <a href="#tymethod.nanoseconds" class="fnname">nanoseconds</a>(nanoseconds: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self;
<span class="item-spacer"></span> fn <a href="#tymethod.num_seconds" class="fnname">num_seconds</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>;
<span class="item-spacer"></span> fn <a href="#tymethod.num_milliseconds" class="fnname">num_milliseconds</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>;
<span class="item-spacer"></span> fn <a href="#tymethod.num_microseconds" class="fnname">num_microseconds</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>;
<span class="item-spacer"></span> fn <a href="#tymethod.num_nanoseconds" class="fnname">num_nanoseconds</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>;
fn <a href="#method.zero" class="fnname">zero</a>() -&gt; Self { ... }
<span class="item-spacer"></span> fn <a href="#method.hours" class="fnname">hours</a>(hours: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self { ... }
<span class="item-spacer"></span> fn <a href="#method.minutes" class="fnname">minutes</a>(minutes: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self { ... }
<span class="item-spacer"></span> fn <a href="#method.num_hours" class="fnname">num_hours</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a> { ... }
<span class="item-spacer"></span> fn <a href="#method.num_minutes" class="fnname">num_minutes</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a> { ... }
</details>}</code></pre></div><h2 id="required-methods" class="small-section-header">Required Methods<a href="#required-methods" class="anchor"></a></h2><div class="methods"><section id="tymethod.seconds" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#165">source</a><h4 class="code-header">fn <a href="#tymethod.seconds" class="fnname">seconds</a>(seconds: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self</h4></section><section id="tymethod.milliseconds" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#166">source</a><h4 class="code-header">fn <a href="#tymethod.milliseconds" class="fnname">milliseconds</a>(milliseconds: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self</h4></section><section id="tymethod.microseconds" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#167">source</a><h4 class="code-header">fn <a href="#tymethod.microseconds" class="fnname">microseconds</a>(microseconds: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self</h4></section><section id="tymethod.nanoseconds" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#168">source</a><h4 class="code-header">fn <a href="#tymethod.nanoseconds" class="fnname">nanoseconds</a>(nanoseconds: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self</h4></section><section id="tymethod.num_seconds" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#180">source</a><h4 class="code-header">fn <a href="#tymethod.num_seconds" class="fnname">num_seconds</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a></h4></section><section id="tymethod.num_milliseconds" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#181">source</a><h4 class="code-header">fn <a href="#tymethod.num_milliseconds" class="fnname">num_milliseconds</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a></h4></section><section id="tymethod.num_microseconds" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#182">source</a><h4 class="code-header">fn <a href="#tymethod.num_microseconds" class="fnname">num_microseconds</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a></h4></section><section id="tymethod.num_nanoseconds" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#183">source</a><h4 class="code-header">fn <a href="#tymethod.num_nanoseconds" class="fnname">num_nanoseconds</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a></h4></section></div><h2 id="provided-methods" class="small-section-header">Provided Methods<a href="#provided-methods" class="anchor"></a></h2><div class="methods"><section id="method.zero" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#145-147">source</a><h4 class="code-header">fn <a href="#method.zero" class="fnname">zero</a>() -&gt; Self</h4></section><section id="method.hours" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#150-155">source</a><h4 class="code-header">fn <a href="#method.hours" class="fnname">hours</a>(hours: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self</h4></section><section id="method.minutes" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#158-163">source</a><h4 class="code-header">fn <a href="#method.minutes" class="fnname">minutes</a>(minutes: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a>) -&gt; Self</h4></section><section id="method.num_hours" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#171-173">source</a><h4 class="code-header">fn <a href="#method.num_hours" class="fnname">num_hours</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a></h4></section><section id="method.num_minutes" class="method has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#176-178">source</a><h4 class="code-header">fn <a href="#method.num_minutes" class="fnname">num_minutes</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i64.html">i64</a></h4></section></div><h2 id="implementors" class="small-section-header">Implementors<a href="#implementors" class="anchor"></a></h2><div id="implementors-list"><section id="impl-TimeValLike-for-TimeSpec" class="impl has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#257-332">source</a><a href="#impl-TimeValLike-for-TimeSpec" class="anchor"></a><h3 class="code-header">impl <a class="trait" href="trait.TimeValLike.html" title="trait nix::sys::time::TimeValLike">TimeValLike</a> for <a class="struct" href="struct.TimeSpec.html" title="struct nix::sys::time::TimeSpec">TimeSpec</a></h3></section><section id="impl-TimeValLike-for-TimeVal" class="impl has-srclink"><a class="srclink rightside" href="../../../src/nix/sys/time.rs.html#495-579">source</a><a href="#impl-TimeValLike-for-TimeVal" class="anchor"></a><h3 class="code-header">impl <a class="trait" href="trait.TimeValLike.html" title="trait nix::sys::time::TimeValLike">TimeValLike</a> for <a class="struct" href="struct.TimeVal.html" title="struct nix::sys::time::TimeVal">TimeVal</a></h3></section></div><script src="../../../implementors/nix/sys/time/trait.TimeValLike.js" async></script></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="nix" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.66.0-nightly (5c8bff74b 2022-10-21)" ></div></body></html>