You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Trac3r-rust/doc/rand/trait.RngCore.html

114 lines
85 KiB

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!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 `RngCore` trait in crate `rand`."><meta name="keywords" content="rust, rustlang, rust-lang, RngCore"><title>rand::RngCore - Rust</title><link rel="stylesheet" type="text/css" href="../normalize.css"><link rel="stylesheet" type="text/css" href="../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../dark.css"><link rel="stylesheet" type="text/css" href="../light.css" id="themeStyle"><script src="../storage.js"></script><noscript><link rel="stylesheet" href="../noscript.css"></noscript><link rel="shortcut icon" href="https://www.rust-lang.org/favicon.ico"><style type="text/css">#crate-search{background-image:url("../down-arrow.svg");}</style></head><body class="rustdoc trait"><!--[if lte IE 8]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="sidebar"><div class="sidebar-menu">&#9776;</div><a href='../rand/index.html'><div class='logo-container'><img src='https://www.rust-lang.org/logos/rust-logo-128x128-blk.png' alt='logo'></div></a><p class='location'>Trait RngCore</p><div class="sidebar-elems"><div class="block items"><a class="sidebar-title" href="#required-methods">Required Methods</a><div class="sidebar-links"><a href="#tymethod.fill_bytes">fill_bytes</a><a href="#tymethod.next_u32">next_u32</a><a href="#tymethod.next_u64">next_u64</a><a href="#tymethod.try_fill_bytes">try_fill_bytes</a></div><a class="sidebar-title" href="#foreign-impls">Implementations on Foreign Types</a><div class="sidebar-links"><a href="#impl-RngCore-for-%26%27a%20mut%20R">&amp;&#39;a mut R</a><a href="#impl-RngCore-for-BlockRng%3CR%3E">BlockRng&lt;R&gt;</a><a href="#impl-RngCore-for-BlockRng64%3CR%3E">BlockRng64&lt;R&gt;</a><a href="#impl-RngCore-for-Box%3CR%3E">Box&lt;R&gt;</a><a href="#impl-RngCore-for-ChaChaRng">ChaChaRng</a><a href="#impl-RngCore-for-Hc128Rng">Hc128Rng</a><a href="#impl-RngCore-for-Isaac64Rng">Isaac64Rng</a><a href="#impl-RngCore-for-IsaacRng">IsaacRng</a><a href="#impl-RngCore-for-Lcg64Xsh32">Lcg64Xsh32</a><a href="#impl-RngCore-for-Mcg128Xsl64">Mcg128Xsl64</a><a href="#impl-RngCore-for-XorShiftRng">XorShiftRng</a></div><a class="sidebar-title" href="#implementors">Implementors</a><a class="sidebar-title" href="#implementations">Trait Implementations</a><div class="sidebar-links"><a href="#impl-Read">Read</a></div></div><p class='location'><a href='index.html'>rand</a></p><script>window.sidebarCurrent = {name: 'RngCore', ty: 'trait', relpath: ''};</script><script defer src="sidebar-items.js"></script></div></nav><div class="theme-picker"><button id="theme-picker" aria-label="Pick another theme!"><img src="../brush.svg" width="18" alt="Pick another theme!"></button><div id="theme-choices"></div></div><script src="../theme.js"></script><nav class="sub"><form class="search-form js-only"><div class="search-container"><div><select id="crate-search"><option value="All crates">All crates</option></select><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press S to search, ? for more options…" type="search"></div><a id="settings-menu" href="../settings.html"><img src="../wheel.svg" width="18" alt="Change settings"></a></div></form></nav><section id="main" class="content"><h1 class='fqn'><span class='out-of-band'><span id='render-detail'><a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class='inner'>&#x2212;</span>]</a></span><a class='srclink' href='../src/rand_core/lib.rs.html#138-185' title='goto source code'>[src]</a></span><span class='in-band'>Trait <a href='index.html'>rand</a>::<wbr><a class="trait" href=''>RngCore</a></span></h1><div class="docblock type-decl hidden-by-usual-hider"><pre class='rust trait'>pub trait RngCore {
fn <a href='#tymethod.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a>;
<div class='item-spacer'></div> fn <a href='#tymethod.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a>;
<div class='item-spacer'></div> fn <a href='#tymethod.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>);
<div class='item-spacer'></div> fn <a href='#tymethod.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;;
}</pre></div><div class='docblock'><p>The core of a random number generator.</p>
<p>This trait encapsulates the low-level functionality common to all
generators, and is the &quot;back end&quot;, to be implemented by generators.
End users should normally use the <code>Rng</code> trait from the <a href="https://docs.rs/rand"><code>rand</code></a> crate,
which is automatically implemented for every type implementing <code>RngCore</code>.</p>
<p>Three different methods for generating random data are provided since the
optimal implementation of each is dependent on the type of generator. There
is no required relationship between the output of each; e.g. many
implementations of <a href="RngCore::fill_bytes"><code>fill_bytes</code></a> consume a whole number of <code>u32</code> or <code>u64</code>
values and drop any remaining unused bytes.</p>
<p>The <a href="RngCore::try_fill_bytes"><code>try_fill_bytes</code></a> method is a variant of <a href="RngCore::fill_bytes"><code>fill_bytes</code></a> allowing error
handling; it is not deemed sufficiently useful to add equivalents for
<a href="RngCore::next_u32"><code>next_u32</code></a> or <a href="RngCore::next_u64"><code>next_u64</code></a> since the latter methods are almost always used
with algorithmic generators (PRNGs), which are normally infallible.</p>
<p>Algorithmic generators implementing [<code>SeedableRng</code>] should normally have
<em>portable, reproducible</em> output, i.e. fix Endianness when converting values
to avoid platform differences, and avoid making any changes which affect
output (except by communicating that the release has breaking changes).</p>
<p>Typically implementators will implement only one of the methods available
in this trait directly, then use the helper functions from the
[<code>impls</code>] module to implement the other methods.</p>
<p>It is recommended that implementations also implement:</p>
<ul>
<li><code>Debug</code> with a custom implementation which <em>does not</em> print any internal
state (at least, [<code>CryptoRng</code>]s should not risk leaking state through
<code>Debug</code>).</li>
<li><code>Serialize</code> and <code>Deserialize</code> (from Serde), preferably making Serde
support optional at the crate level in PRNG libs.</li>
<li><code>Clone</code>, if possible.</li>
<li><em>never</em> implement <code>Copy</code> (accidental copies may cause repeated values).</li>
<li><em>do not</em> implement <code>Default</code> for pseudorandom generators, but instead
implement [<code>SeedableRng</code>], to guide users towards proper seeding.
External / hardware RNGs can choose to implement <code>Default</code>.</li>
<li><code>Eq</code> and <code>PartialEq</code> could be implemented, but are probably not useful.</li>
</ul>
<h1 id="example" class="section-header"><a href="#example">Example</a></h1>
<p>A simple example, obviously not generating very <em>random</em> output:</p>
<div class="example-wrap"><pre class="rust rust-example-rendered">
<span class="attribute">#![<span class="ident">allow</span>(<span class="ident">dead_code</span>)]</span>
<span class="kw">use</span> <span class="ident">rand_core</span>::{<span class="ident">RngCore</span>, <span class="ident">Error</span>, <span class="ident">impls</span>};
<span class="kw">struct</span> <span class="ident">CountingRng</span>(<span class="ident">u64</span>);
<span class="kw">impl</span> <span class="ident">RngCore</span> <span class="kw">for</span> <span class="ident">CountingRng</span> {
<span class="kw">fn</span> <span class="ident">next_u32</span>(<span class="kw-2">&amp;</span><span class="kw-2">mut</span> <span class="self">self</span>) <span class="op">-</span><span class="op">&gt;</span> <span class="ident">u32</span> {
<span class="self">self</span>.<span class="ident">next_u64</span>() <span class="kw">as</span> <span class="ident">u32</span>
}
<span class="kw">fn</span> <span class="ident">next_u64</span>(<span class="kw-2">&amp;</span><span class="kw-2">mut</span> <span class="self">self</span>) <span class="op">-</span><span class="op">&gt;</span> <span class="ident">u64</span> {
<span class="self">self</span>.<span class="number">0</span> <span class="op">+</span><span class="op">=</span> <span class="number">1</span>;
<span class="self">self</span>.<span class="number">0</span>
}
<span class="kw">fn</span> <span class="ident">fill_bytes</span>(<span class="kw-2">&amp;</span><span class="kw-2">mut</span> <span class="self">self</span>, <span class="ident">dest</span>: <span class="kw-2">&amp;</span><span class="kw-2">mut</span> [<span class="ident">u8</span>]) {
<span class="ident">impls</span>::<span class="ident">fill_bytes_via_next</span>(<span class="self">self</span>, <span class="ident">dest</span>)
}
<span class="kw">fn</span> <span class="ident">try_fill_bytes</span>(<span class="kw-2">&amp;</span><span class="kw-2">mut</span> <span class="self">self</span>, <span class="ident">dest</span>: <span class="kw-2">&amp;</span><span class="kw-2">mut</span> [<span class="ident">u8</span>]) <span class="op">-</span><span class="op">&gt;</span> <span class="prelude-ty">Result</span><span class="op">&lt;</span>(), <span class="ident">Error</span><span class="op">&gt;</span> {
<span class="prelude-val">Ok</span>(<span class="self">self</span>.<span class="ident">fill_bytes</span>(<span class="ident">dest</span>))
}
}</pre></div>
</div>
<h2 id='required-methods' class='small-section-header'>Required methods<a href='#required-methods' class='anchor'></a></h2><div class='methods'><h3 id='tymethod.next_u32' class='method'><code id='next_u32.v'>fn <a href='#tymethod.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code></h3><div class='docblock'><p>Return the next random <code>u32</code>.</p>
<p>RNGs must implement at least one method from this trait directly. In
the case this method is not implemented directly, it can be implemented
using <code>self.next_u64() as u32</code> or via
[<code>fill_bytes</code>][impls::next_u32_via_fill].</p>
</div><h3 id='tymethod.next_u64' class='method'><code id='next_u64.v'>fn <a href='#tymethod.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code></h3><div class='docblock'><p>Return the next random <code>u64</code>.</p>
<p>RNGs must implement at least one method from this trait directly. In
the case this method is not implemented directly, it can be implemented
via [<code>next_u32</code>][impls::next_u64_via_u32] or via
[<code>fill_bytes</code>][impls::next_u64_via_fill].</p>
</div><h3 id='tymethod.fill_bytes' class='method'><code id='fill_bytes.v'>fn <a href='#tymethod.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code></h3><div class='docblock'><p>Fill <code>dest</code> with random data.</p>
<p>RNGs must implement at least one method from this trait directly. In
the case this method is not implemented directly, it can be implemented
via [<code>next_u*</code>][impls::fill_bytes_via_next] or
via [<code>try_fill_bytes</code>][RngCore::try_fill_bytes]; if this generator can
fail the implementation must choose how best to handle errors here
(e.g. panic with a descriptive message or log a warning and retry a few
times).</p>
<p>This method should guarantee that <code>dest</code> is entirely filled
with new data, and may panic if this is impossible
(e.g. reading past the end of a file that is being used as the
source of randomness).</p>
</div><h3 id='tymethod.try_fill_bytes' class='method'><code id='try_fill_bytes.v'>fn <a href='#tymethod.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code></h3><div class='docblock'><p>Fill <code>dest</code> entirely with random data.</p>
<p>This is the only method which allows an RNG to report errors while
generating random data thus making this the primary method implemented
by external (true) RNGs (e.g. <code>OsRng</code>) which can fail. It may be used
directly to generate keys and to seed (infallible) PRNGs.</p>
<p>Other than error handling, this method is identical to <a href="RngCore::fill_bytes"><code>fill_bytes</code></a>;
thus this may be implemented using <code>Ok(self.fill_bytes(dest))</code> or
<code>fill_bytes</code> may be implemented with
<code>self.try_fill_bytes(dest).unwrap()</code> or more specific error handling.</p>
</div></div><span class='loading-content'>Loading content...</span><h2 id='implementations' class='small-section-header'>Trait Implementations<a href='#implementations' class='anchor'></a></h2><div id='implementations-list'><h3 id='impl-Read' class='impl'><code class='in-band'>impl <a class="trait" href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html" title="trait std::io::Read">Read</a> for dyn <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> + 'static</code><a href='#impl-Read' class='anchor'></a><a class='srclink' href='../src/rand_core/lib.rs.html#422-427' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.read' class="method hidden"><code id='read.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#tymethod.read' class='fnname'>read</a>(&amp;mut self, buf: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/error/struct.Error.html" title="struct std::io::error::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_core/lib.rs.html#423-426' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Pull some bytes from this source into the specified buffer, returning how many bytes were read. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#tymethod.read">Read more</a></p>
</div><h4 id='method.read_vectored' class="method hidden"><code id='read_vectored.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_vectored' class='fnname'>read_vectored</a>(&amp;mut self, bufs: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="struct" href="https://doc.rust-lang.org/nightly/std/io/struct.IoSliceMut.html" title="struct std::io::IoSliceMut">IoSliceMut</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/error/struct.Error.html" title="struct std::io::error::Error">Error</a>&gt;</code><span class='since' title='Stable since Rust version 1.36.0'>1.36.0</span><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#580-582' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Like <code>read</code>, except that it reads into a slice of buffers. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_vectored">Read more</a></p>
</div><h4 id='method.initializer' class="method hidden"><code id='initializer.v'>unsafe fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.initializer' class='fnname'>initializer</a>(&amp;self) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/struct.Initializer.html" title="struct std::io::Initializer">Initializer</a></code><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#608-610' title='goto source code'>[src]</a></h4><div class='stability hidden'><div class='stab unstable'><span class='emoji'>🔬</span> This is a nightly-only experimental API. (<code>read_initializer</code>)</div></div><div class='docblock hidden'><p>Determines if this <code>Read</code>er can work with buffers of uninitialized memory. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.initializer">Read more</a></p>
</div><h4 id='method.read_to_end' class="method hidden"><code id='read_to_end.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_to_end' class='fnname'>read_to_end</a>(&amp;mut self, buf: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/vec/struct.Vec.html" title="struct alloc::vec::Vec">Vec</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>&gt;) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/error/struct.Error.html" title="struct std::io::error::Error">Error</a>&gt;</code><span class='since' title='Stable since Rust version 1.0.0'>1.0.0</span><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#660-662' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Read all bytes until EOF in this source, placing them into <code>buf</code>. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_to_end">Read more</a></p>
</div><h4 id='method.read_to_string' class="method hidden"><code id='read_to_string.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_to_string' class='fnname'>read_to_string</a>(&amp;mut self, buf: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/error/struct.Error.html" title="struct std::io::error::Error">Error</a>&gt;</code><span class='since' title='Stable since Rust version 1.0.0'>1.0.0</span><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#703-714' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Read all bytes until EOF in this source, appending them to <code>buf</code>. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_to_string">Read more</a></p>
</div><h4 id='method.read_exact' class="method hidden"><code id='read_exact.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_exact' class='fnname'>read_exact</a>(&amp;mut self, buf: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/error/struct.Error.html" title="struct std::io::error::Error">Error</a>&gt;</code><span class='since' title='Stable since Rust version 1.6.0'>1.6.0</span><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#766-781' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Read the exact number of bytes required to fill <code>buf</code>. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_exact">Read more</a></p>
</div><h4 id='method.by_ref' class="method hidden"><code id='by_ref.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.by_ref' class='fnname'>by_ref</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut </a>Self</code><span class='since' title='Stable since Rust version 1.0.0'>1.0.0</span><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#818' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Creates a &quot;by reference&quot; adaptor for this instance of <code>Read</code>. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.by_ref">Read more</a></p>
</div><h4 id='method.bytes' class="method hidden"><code id='bytes.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.bytes' class='fnname'>bytes</a>(self) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/struct.Bytes.html" title="struct std::io::Bytes">Bytes</a>&lt;Self&gt;</code><span class='since' title='Stable since Rust version 1.0.0'>1.0.0</span><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#855-857' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Transforms this <code>Read</code> instance to an [<code>Iterator</code>] over its bytes. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.bytes">Read more</a></p>
</div><h4 id='method.chain' class="method hidden"><code id='chain.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.chain' class='fnname'>chain</a>&lt;R&gt;(self, next: R) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/struct.Chain.html" title="struct std::io::Chain">Chain</a>&lt;Self, R&gt; <span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;R: <a class="trait" href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html" title="trait std::io::Read">Read</a>,&nbsp;</span></code><span class='since' title='Stable since Rust version 1.0.0'>1.0.0</span><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#890-892' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Creates an adaptor which will chain this stream with another. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.chain">Read more</a></p>
</div><h4 id='method.take' class="method hidden"><code id='take.v'>fn <a href='https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.take' class='fnname'>take</a>(self, limit: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a>) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/std/io/struct.Take.html" title="struct std::io::Take">Take</a>&lt;Self&gt;</code><span class='since' title='Stable since Rust version 1.0.0'>1.0.0</span><a class='srclink' href='https://doc.rust-lang.org/nightly/src/std/io/mod.rs.html#926-928' title='goto source code'>[src]</a></h4><div class='docblock hidden'><p>Creates an adaptor which will read at most <code>limit</code> bytes from it. <a href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.take">Read more</a></p>
</div></div></div>
<h2 id='foreign-impls' class='small-section-header'>Implementations on Foreign Types<a href='#foreign-impls' class='anchor'></a></h2><h3 id='impl-RngCore-for-Box%3CR%3E' class='impl'><code class='in-band'>impl&lt;R&gt; <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/boxed/struct.Box.html" title="struct alloc::boxed::Box">Box</a>&lt;R&gt; <span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;R: <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,&nbsp;</span></code><a href='#impl-RngCore-for-Box%3CR%3E' class='anchor'></a><a class='srclink' href='../src/rand_core/lib.rs.html#399-419' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32' class="method hidden"><code id='next_u32.v-1'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_core/lib.rs.html#401-403' title='goto source code'>[src]</a></h4><h4 id='method.next_u64' class="method hidden"><code id='next_u64.v-1'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_core/lib.rs.html#406-408' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes' class="method hidden"><code id='fill_bytes.v-1'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_core/lib.rs.html#411-413' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes' class="method hidden"><code id='try_fill_bytes.v-1'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_core/lib.rs.html#416-418' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-%26%27a%20mut%20R' class='impl'><code class='in-band'>impl&lt;'a, R&gt; <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;'a mut </a>R <span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;R: <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,&nbsp;</span></code><a href='#impl-RngCore-for-%26%27a%20mut%20R' class='anchor'></a><a class='srclink' href='../src/rand_core/lib.rs.html#373-393' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-1' class="method hidden"><code id='next_u32.v-2'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_core/lib.rs.html#375-377' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-1' class="method hidden"><code id='next_u64.v-2'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_core/lib.rs.html#380-382' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-1' class="method hidden"><code id='fill_bytes.v-2'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_core/lib.rs.html#385-387' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-1' class="method hidden"><code id='try_fill_bytes.v-2'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_core/lib.rs.html#390-392' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-BlockRng64%3CR%3E' class='impl'><code class='in-band'>impl&lt;R&gt; <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_core/block/struct.BlockRng64.html" title="struct rand_core::block::BlockRng64">BlockRng64</a>&lt;R&gt; <span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;R: <a class="trait" href="../rand_core/block/trait.BlockRngCore.html" title="trait rand_core::block::BlockRngCore">BlockRngCore</a>&lt;Item = <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a>&gt;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&lt;R as <a class="trait" href="../rand_core/block/trait.BlockRngCore.html" title="trait rand_core::block::BlockRngCore">BlockRngCore</a>&gt;::<a class="type" href="../rand_core/block/trait.BlockRngCore.html#associatedtype.Results" title="type rand_core::block::BlockRngCore::Results">Results</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html" title="trait core::convert::AsRef">AsRef</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">[</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>&gt;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&lt;R as <a class="trait" href="../rand_core/block/trait.BlockRngCore.html" title="trait rand_core::block::BlockRngCore">BlockRngCore</a>&gt;::<a class="type" href="../rand_core/block/trait.BlockRngCore.html#associatedtype.Results" title="type rand_core::block::BlockRngCore::Results">Results</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsMut.html" title="trait core::convert::AsMut">AsMut</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">[</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>&gt;,&nbsp;</span></code><a href='#impl-RngCore-for-BlockRng64%3CR%3E' class='anchor'></a><a class='srclink' href='../src/rand_core/block.rs.html#376-481' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-2' class="method hidden"><code id='next_u32.v-3'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_core/block.rs.html#380-403' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-2' class="method hidden"><code id='next_u64.v-3'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_core/block.rs.html#406-416' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-2' class="method hidden"><code id='fill_bytes.v-3'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_core/block.rs.html#422-457' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-2' class="method hidden"><code id='try_fill_bytes.v-3'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_core/block.rs.html#478-480' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-BlockRng%3CR%3E' class='impl'><code class='in-band'>impl&lt;R&gt; <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_core/block/struct.BlockRng.html" title="struct rand_core::block::BlockRng">BlockRng</a>&lt;R&gt; <span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;R: <a class="trait" href="../rand_core/block/trait.BlockRngCore.html" title="trait rand_core::block::BlockRngCore">BlockRngCore</a>&lt;Item = <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a>&gt;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&lt;R as <a class="trait" href="../rand_core/block/trait.BlockRngCore.html" title="trait rand_core::block::BlockRngCore">BlockRngCore</a>&gt;::<a class="type" href="../rand_core/block/trait.BlockRngCore.html#associatedtype.Results" title="type rand_core::block::BlockRngCore::Results">Results</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html" title="trait core::convert::AsRef">AsRef</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">[</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>&gt;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&lt;R as <a class="trait" href="../rand_core/block/trait.BlockRngCore.html" title="trait rand_core::block::BlockRngCore">BlockRngCore</a>&gt;::<a class="type" href="../rand_core/block/trait.BlockRngCore.html#associatedtype.Results" title="type rand_core::block::BlockRngCore::Results">Results</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsMut.html" title="trait core::convert::AsMut">AsMut</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">[</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>&gt;,&nbsp;</span></code><a href='#impl-RngCore-for-BlockRng%3CR%3E' class='anchor'></a><a class='srclink' href='../src/rand_core/block.rs.html#167-273' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-3' class="method hidden"><code id='next_u32.v-4'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_core/block.rs.html#171-179' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-3' class="method hidden"><code id='next_u64.v-4'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_core/block.rs.html#182-210' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-3' class="method hidden"><code id='fill_bytes.v-4'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_core/block.rs.html#216-251' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-3' class="method hidden"><code id='try_fill_bytes.v-4'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_core/block.rs.html#269-272' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-IsaacRng' class='impl'><code class='in-band'>impl <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_isaac/isaac/struct.IsaacRng.html" title="struct rand_isaac::isaac::IsaacRng">IsaacRng</a></code><a href='#impl-RngCore-for-IsaacRng' class='anchor'></a><a class='srclink' href='../src/rand_isaac/isaac.rs.html#96-114' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-4' class="method hidden"><code id='next_u32.v-5'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_isaac/isaac.rs.html#98-100' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-4' class="method hidden"><code id='next_u64.v-5'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_isaac/isaac.rs.html#103-105' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-4' class="method hidden"><code id='fill_bytes.v-5'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_isaac/isaac.rs.html#107-109' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-4' class="method hidden"><code id='try_fill_bytes.v-5'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_isaac/isaac.rs.html#111-113' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-Isaac64Rng' class='impl'><code class='in-band'>impl <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_isaac/isaac64/struct.Isaac64Rng.html" title="struct rand_isaac::isaac64::Isaac64Rng">Isaac64Rng</a></code><a href='#impl-RngCore-for-Isaac64Rng' class='anchor'></a><a class='srclink' href='../src/rand_isaac/isaac64.rs.html#86-104' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-5' class="method hidden"><code id='next_u32.v-6'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_isaac/isaac64.rs.html#88-90' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-5' class="method hidden"><code id='next_u64.v-6'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_isaac/isaac64.rs.html#93-95' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-5' class="method hidden"><code id='fill_bytes.v-6'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_isaac/isaac64.rs.html#97-99' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-5' class="method hidden"><code id='try_fill_bytes.v-6'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_isaac/isaac64.rs.html#101-103' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-ChaChaRng' class='impl'><code class='in-band'>impl <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_chacha/chacha/struct.ChaChaRng.html" title="struct rand_chacha::chacha::ChaChaRng">ChaChaRng</a></code><a href='#impl-RngCore-for-ChaChaRng' class='anchor'></a><a class='srclink' href='../src/rand_chacha/chacha.rs.html#72-92' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-6' class="method hidden"><code id='next_u32.v-7'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_chacha/chacha.rs.html#74-76' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-6' class="method hidden"><code id='next_u64.v-7'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_chacha/chacha.rs.html#79-81' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-6' class="method hidden"><code id='fill_bytes.v-7'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_chacha/chacha.rs.html#84-86' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-6' class="method hidden"><code id='try_fill_bytes.v-7'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_chacha/chacha.rs.html#89-91' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-Hc128Rng' class='impl'><code class='in-band'>impl <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_hc/hc128/struct.Hc128Rng.html" title="struct rand_hc::hc128::Hc128Rng">Hc128Rng</a></code><a href='#impl-RngCore-for-Hc128Rng' class='anchor'></a><a class='srclink' href='../src/rand_hc/hc128.rs.html#72-90' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-7' class="method hidden"><code id='next_u32.v-8'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_hc/hc128.rs.html#74-76' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-7' class="method hidden"><code id='next_u64.v-8'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_hc/hc128.rs.html#79-81' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-7' class="method hidden"><code id='fill_bytes.v-8'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_hc/hc128.rs.html#83-85' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-7' class="method hidden"><code id='try_fill_bytes.v-8'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_hc/hc128.rs.html#87-89' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-Lcg64Xsh32' class='impl'><code class='in-band'>impl <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_pcg/pcg64/struct.Lcg64Xsh32.html" title="struct rand_pcg::pcg64::Lcg64Xsh32">Lcg64Xsh32</a></code><a href='#impl-RngCore-for-Lcg64Xsh32' class='anchor'></a><a class='srclink' href='../src/rand_pcg/pcg64.rs.html#94-141' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-8' class="method hidden"><code id='next_u32.v-9'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_pcg/pcg64.rs.html#96-109' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-8' class="method hidden"><code id='next_u64.v-9'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_pcg/pcg64.rs.html#112-114' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-8' class="method hidden"><code id='fill_bytes.v-9'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_pcg/pcg64.rs.html#117-135' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-8' class="method hidden"><code id='try_fill_bytes.v-9'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_pcg/pcg64.rs.html#138-140' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-Mcg128Xsl64' class='impl'><code class='in-band'>impl <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_pcg/pcg128/struct.Mcg128Xsl64.html" title="struct rand_pcg::pcg128::Mcg128Xsl64">Mcg128Xsl64</a></code><a href='#impl-RngCore-for-Mcg128Xsl64' class='anchor'></a><a class='srclink' href='../src/rand_pcg/pcg128.rs.html#75-122' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-9' class="method hidden"><code id='next_u32.v-10'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_pcg/pcg128.rs.html#77-79' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-9' class="method hidden"><code id='next_u64.v-10'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_pcg/pcg128.rs.html#82-95' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-9' class="method hidden"><code id='fill_bytes.v-10'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_pcg/pcg128.rs.html#98-116' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-9' class="method hidden"><code id='try_fill_bytes.v-10'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_pcg/pcg128.rs.html#119-121' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-for-XorShiftRng' class='impl'><code class='in-band'>impl <a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a> for <a class="struct" href="../rand_xorshift/struct.XorShiftRng.html" title="struct rand_xorshift::XorShiftRng">XorShiftRng</a></code><a href='#impl-RngCore-for-XorShiftRng' class='anchor'></a><a class='srclink' href='../src/rand_xorshift/lib.rs.html#54-80' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-10' class="method hidden"><code id='next_u32.v-11'>fn <a href='#method.next_u32' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_xorshift/lib.rs.html#56-65' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-10' class="method hidden"><code id='next_u64.v-11'>fn <a href='#method.next_u64' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_xorshift/lib.rs.html#68-70' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-10' class="method hidden"><code id='fill_bytes.v-11'>fn <a href='#method.fill_bytes' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_xorshift/lib.rs.html#73-75' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-10' class="method hidden"><code id='try_fill_bytes.v-11'>fn <a href='#method.try_fill_bytes' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_xorshift/lib.rs.html#77-79' title='goto source code'>[src]</a></h4></div><span class='loading-content'>Loading content...</span>
<h2 id='implementors' class='small-section-header'>Implementors<a href='#implementors' class='anchor'></a></h2><div class='item-list' id='implementors-list'><h3 id='impl-RngCore' class='impl'><code class='in-band'>impl RngCore for <a class="struct" href="../rand/rngs/mock/struct.StepRng.html" title="struct rand::rngs::mock::StepRng">StepRng</a></code><a href='#impl-RngCore' class='anchor'></a><a class='srclink' href='../src/rand/rngs/mock.rs.html#41-59' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-11' class="method hidden"><code id='next_u32.v-12'>fn <a href='#method.next_u32-11' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand/rngs/mock.rs.html#42-44' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-11' class="method hidden"><code id='next_u64.v-12'>fn <a href='#method.next_u64-11' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand/rngs/mock.rs.html#46-50' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-11' class="method hidden"><code id='fill_bytes.v-12'>fn <a href='#method.fill_bytes-11' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand/rngs/mock.rs.html#52-54' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-11' class="method hidden"><code id='try_fill_bytes.v-12'>fn <a href='#method.try_fill_bytes-11' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand/rngs/mock.rs.html#56-58' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-1' class='impl'><code class='in-band'>impl RngCore for <a class="struct" href="../rand/rngs/struct.EntropyRng.html" title="struct rand::rngs::EntropyRng">EntropyRng</a></code><a href='#impl-RngCore-1' class='anchor'></a><a class='srclink' href='../src/rand/rngs/entropy.rs.html#75-160' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-12' class="method hidden"><code id='next_u32.v-13'>fn <a href='#method.next_u32-12' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand/rngs/entropy.rs.html#76-78' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-12' class="method hidden"><code id='next_u64.v-13'>fn <a href='#method.next_u64-12' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand/rngs/entropy.rs.html#80-82' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-12' class="method hidden"><code id='fill_bytes.v-13'>fn <a href='#method.fill_bytes-12' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand/rngs/entropy.rs.html#84-87' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-12' class="method hidden"><code id='try_fill_bytes.v-13'>fn <a href='#method.try_fill_bytes-12' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand/rngs/entropy.rs.html#89-159' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-2' class='impl'><code class='in-band'>impl RngCore for <a class="struct" href="../rand/rngs/struct.JitterRng.html" title="struct rand::rngs::JitterRng">JitterRng</a></code><a href='#impl-RngCore-2' class='anchor'></a><a class='srclink' href='../src/rand_jitter/lib.rs.html#685-715' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-13' class="method hidden"><code id='next_u32.v-14'>fn <a href='#method.next_u32-13' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_jitter/lib.rs.html#686-696' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-13' class="method hidden"><code id='next_u64.v-14'>fn <a href='#method.next_u64-13' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_jitter/lib.rs.html#698-701' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-13' class="method hidden"><code id='fill_bytes.v-14'>fn <a href='#method.fill_bytes-13' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_jitter/lib.rs.html#703-710' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-13' class="method hidden"><code id='try_fill_bytes.v-14'>fn <a href='#method.try_fill_bytes-13' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_jitter/lib.rs.html#712-714' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-3' class='impl'><code class='in-band'>impl RngCore for <a class="struct" href="../rand/rngs/struct.OsRng.html" title="struct rand::rngs::OsRng">OsRng</a></code><a href='#impl-RngCore-3' class='anchor'></a><a class='srclink' href='../src/rand_os/lib.rs.html#174-256' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-14' class="method hidden"><code id='next_u32.v-15'>fn <a href='#method.next_u32-14' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand_os/lib.rs.html#175-177' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-14' class="method hidden"><code id='next_u64.v-15'>fn <a href='#method.next_u64-14' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand_os/lib.rs.html#179-181' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-14' class="method hidden"><code id='fill_bytes.v-15'>fn <a href='#method.fill_bytes-14' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand_os/lib.rs.html#183-233' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-14' class="method hidden"><code id='try_fill_bytes.v-15'>fn <a href='#method.try_fill_bytes-14' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand_os/lib.rs.html#235-255' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-4' class='impl'><code class='in-band'>impl RngCore for <a class="struct" href="../rand/rngs/struct.SmallRng.html" title="struct rand::rngs::SmallRng">SmallRng</a></code><a href='#impl-RngCore-4' class='anchor'></a><a class='srclink' href='../src/rand/rngs/small.rs.html#76-94' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-15' class="method hidden"><code id='next_u32.v-16'>fn <a href='#method.next_u32-15' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand/rngs/small.rs.html#78-80' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-15' class="method hidden"><code id='next_u64.v-16'>fn <a href='#method.next_u64-15' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand/rngs/small.rs.html#83-85' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-15' class="method hidden"><code id='fill_bytes.v-16'>fn <a href='#method.fill_bytes-15' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand/rngs/small.rs.html#87-89' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-15' class="method hidden"><code id='try_fill_bytes.v-16'>fn <a href='#method.try_fill_bytes-15' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand/rngs/small.rs.html#91-93' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-5' class='impl'><code class='in-band'>impl RngCore for <a class="struct" href="../rand/rngs/struct.StdRng.html" title="struct rand::rngs::StdRng">StdRng</a></code><a href='#impl-RngCore-5' class='anchor'></a><a class='srclink' href='../src/rand/rngs/std.rs.html#35-53' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-16' class="method hidden"><code id='next_u32.v-17'>fn <a href='#method.next_u32-16' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand/rngs/std.rs.html#37-39' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-16' class="method hidden"><code id='next_u64.v-17'>fn <a href='#method.next_u64-16' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand/rngs/std.rs.html#42-44' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-16' class="method hidden"><code id='fill_bytes.v-17'>fn <a href='#method.fill_bytes-16' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand/rngs/std.rs.html#46-48' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-16' class="method hidden"><code id='try_fill_bytes.v-17'>fn <a href='#method.try_fill_bytes-16' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand/rngs/std.rs.html#50-52' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-6' class='impl'><code class='in-band'>impl RngCore for <a class="struct" href="../rand/rngs/struct.ThreadRng.html" title="struct rand::rngs::ThreadRng">ThreadRng</a></code><a href='#impl-RngCore-6' class='anchor'></a><a class='srclink' href='../src/rand/rngs/thread.rs.html#105-123' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-17' class="method hidden"><code id='next_u32.v-18'>fn <a href='#method.next_u32-17' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand/rngs/thread.rs.html#107-109' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-17' class="method hidden"><code id='next_u64.v-18'>fn <a href='#method.next_u64-17' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand/rngs/thread.rs.html#112-114' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-17' class="method hidden"><code id='fill_bytes.v-18'>fn <a href='#method.fill_bytes-17' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand/rngs/thread.rs.html#116-118' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-17' class="method hidden"><code id='try_fill_bytes.v-18'>fn <a href='#method.try_fill_bytes-17' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand/rngs/thread.rs.html#120-122' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-7' class='impl'><code class='in-band'>impl&lt;R, Rsdr:&nbsp;<a class="trait" href="../rand/trait.RngCore.html" title="trait rand::RngCore">RngCore</a>&gt; RngCore for <a class="struct" href="../rand/rngs/adapter/struct.ReseedingRng.html" title="struct rand::rngs::adapter::ReseedingRng">ReseedingRng</a>&lt;R, Rsdr&gt; <span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;R: <a class="trait" href="../rand_core/block/trait.BlockRngCore.html" title="trait rand_core::block::BlockRngCore">BlockRngCore</a>&lt;Item = <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a>&gt; + <a class="trait" href="../rand/trait.SeedableRng.html" title="trait rand::SeedableRng">SeedableRng</a>,<br>&nbsp;&nbsp;&nbsp;&nbsp;&lt;R as <a class="trait" href="../rand_core/block/trait.BlockRngCore.html" title="trait rand_core::block::BlockRngCore">BlockRngCore</a>&gt;::<a class="type" href="../rand_core/block/trait.BlockRngCore.html#associatedtype.Results" title="type rand_core::block::BlockRngCore::Results">Results</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsRef.html" title="trait core::convert::AsRef">AsRef</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">[</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>&gt; + <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.AsMut.html" title="trait core::convert::AsMut">AsMut</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">[</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>&gt;,&nbsp;</span></code><a href='#impl-RngCore-7' class='anchor'></a><a class='srclink' href='../src/rand/rngs/adapter/reseeding.rs.html#114-135' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-18' class="method hidden"><code id='next_u32.v-19'>fn <a href='#method.next_u32-18' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand/rngs/adapter/reseeding.rs.html#119-121' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-18' class="method hidden"><code id='next_u64.v-19'>fn <a href='#method.next_u64-18' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand/rngs/adapter/reseeding.rs.html#124-126' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-18' class="method hidden"><code id='fill_bytes.v-19'>fn <a href='#method.fill_bytes-18' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand/rngs/adapter/reseeding.rs.html#128-130' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-18' class="method hidden"><code id='try_fill_bytes.v-19'>fn <a href='#method.try_fill_bytes-18' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand/rngs/adapter/reseeding.rs.html#132-134' title='goto source code'>[src]</a></h4></div><h3 id='impl-RngCore-8' class='impl'><code class='in-band'>impl&lt;R:&nbsp;<a class="trait" href="https://doc.rust-lang.org/nightly/std/io/trait.Read.html" title="trait std::io::Read">Read</a>&gt; RngCore for <a class="struct" href="../rand/rngs/adapter/struct.ReadRng.html" title="struct rand::rngs::adapter::ReadRng">ReadRng</a>&lt;R&gt;</code><a href='#impl-RngCore-8' class='anchor'></a><a class='srclink' href='../src/rand/rngs/adapter/read.rs.html#59-86' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.next_u32-19' class="method hidden"><code id='next_u32.v-20'>fn <a href='#method.next_u32-19' class='fnname'>next_u32</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u32.html">u32</a></code><a class='srclink' href='../src/rand/rngs/adapter/read.rs.html#60-62' title='goto source code'>[src]</a></h4><h4 id='method.next_u64-19' class="method hidden"><code id='next_u64.v-20'>fn <a href='#method.next_u64-19' class='fnname'>next_u64</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u64.html">u64</a></code><a class='srclink' href='../src/rand/rngs/adapter/read.rs.html#64-66' title='goto source code'>[src]</a></h4><h4 id='method.fill_bytes-19' class="method hidden"><code id='fill_bytes.v-20'>fn <a href='#method.fill_bytes-19' class='fnname'>fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>)</code><a class='srclink' href='../src/rand/rngs/adapter/read.rs.html#68-71' title='goto source code'>[src]</a></h4><h4 id='method.try_fill_bytes-19' class="method hidden"><code id='try_fill_bytes.v-20'>fn <a href='#method.try_fill_bytes-19' class='fnname'>try_fill_bytes</a>(&amp;mut self, dest: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">&amp;mut [</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a><a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.slice.html">]</a>) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../rand/struct.Error.html" title="struct rand::Error">Error</a>&gt;</code><a class='srclink' href='../src/rand/rngs/adapter/read.rs.html#73-85' title='goto source code'>[src]</a></h4></div></div><span class='loading-content'>Loading content...</span><script type="text/javascript">window.inlined_types=new Set([]);</script><script type="text/javascript" async
src="../implementors/rand_core/trait.RngCore.js">
</script></section><section id="search" class="content hidden"></section><section class="footer"></section><aside id="help" class="hidden"><div><h1 class="hidden">Help</h1><div class="shortcuts"><h2>Keyboard Shortcuts</h2><dl><dt><kbd>?</kbd></dt><dd>Show this help dialog</dd><dt><kbd>S</kbd></dt><dd>Focus the search field</dd><dt><kbd></kbd></dt><dd>Move up in search results</dd><dt><kbd></kbd></dt><dd>Move down in search results</dd><dt><kbd></kbd></dt><dd>Switch tab</dd><dt><kbd>&#9166;</kbd></dt><dd>Go to active search result</dd><dt><kbd>+</kbd></dt><dd>Expand all sections</dd><dt><kbd>-</kbd></dt><dd>Collapse all sections</dd></dl></div><div class="infos"><h2>Search Tricks</h2><p>Prefix searches with a type followed by a colon (e.g., <code>fn:</code>) to restrict the search to a given type.</p><p>Accepted types are: <code>fn</code>, <code>mod</code>, <code>struct</code>, <code>enum</code>, <code>trait</code>, <code>type</code>, <code>macro</code>, and <code>const</code>.</p><p>Search functions by type signature (e.g., <code>vec -> usize</code> or <code>* -> vec</code>)</p><p>Search multiple things at once by splitting your query with comma (e.g., <code>str,u8</code> or <code>String,struct:Vec,test</code>)</p></div></div></aside><script>window.rootPath = "../";window.currentCrate = "rand";</script><script src="../aliases.js"></script><script src="../main.js"></script><script defer src="../search-index.js"></script></body></html>