213 lines
No EOL
44 KiB
HTML
213 lines
No EOL
44 KiB
HTML
<!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 `UnboundedSender` struct in crate `futures`.">
|
||
<meta name="keywords" content="rust, rustlang, rust-lang, UnboundedSender">
|
||
|
||
<title>futures::sync::mpsc::UnboundedSender - 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="../../../main.css" id="themeStyle">
|
||
<script src="../../../storage.js"></script>
|
||
|
||
|
||
|
||
|
||
</head>
|
||
<body class="rustdoc struct">
|
||
<!--[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">☰</div>
|
||
|
||
<p class='location'>Struct UnboundedSender</p><div class="sidebar-elems"><div class="block items"><a class="sidebar-title" href="#methods">Methods</a><div class="sidebar-links"><a href="#method.unbounded_send">unbounded_send</a></div><a class="sidebar-title" href="#implementations">Trait Implementations</a><div class="sidebar-links"><a href="#impl-Debug">Debug</a><a href="#impl-Sink">Sink</a><a href="#impl-Clone">Clone</a></div></div><p class='location'><a href='../../index.html'>futures</a>::<wbr><a href='../index.html'>sync</a>::<wbr><a href='index.html'>mpsc</a></p><script>window.sidebarCurrent = {name: 'UnboundedSender', ty: 'struct', 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">
|
||
<input class="search-input" name="search"
|
||
autocomplete="off"
|
||
placeholder="Click or press ‘S’ to search, ‘?’ for more options…"
|
||
type="search">
|
||
</div>
|
||
</form>
|
||
</nav>
|
||
|
||
<section id='main' class="content">
|
||
<h1 class='fqn'><span class='in-band'>Struct <a href='../../index.html'>futures</a>::<wbr><a href='../index.html'>sync</a>::<wbr><a href='index.html'>mpsc</a>::<wbr><a class="struct" href=''>UnboundedSender</a></span><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'>−</span>]
|
||
</a>
|
||
</span><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#111' title='goto source code'>[src]</a></span></h1>
|
||
<pre class='rust struct'>pub struct UnboundedSender<T>(_);</pre><div class='docblock'><p>The transmission end of a channel which is used to send values.</p>
|
||
<p>This is created by the <code>unbounded</code> method.</p>
|
||
</div>
|
||
<h2 id='methods' class='small-section-header'>
|
||
Methods<a href='#methods' class='anchor'></a>
|
||
</h2>
|
||
<h3 id='impl' class='impl'><span class='in-band'><code>impl<T> <a class="struct" href="../../../futures/sync/mpsc/struct.UnboundedSender.html" title="struct futures::sync::mpsc::UnboundedSender">UnboundedSender</a><T></code><a href='#impl' class='anchor'></a></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#660-680' title='goto source code'>[src]</a></span></h3>
|
||
<div class='impl-items'><h4 id='method.unbounded_send' class="method"><span id='unbounded_send.v' class='invisible'><code>pub fn <a href='#method.unbounded_send' class='fnname'>unbounded_send</a>(&self, msg: T) -> <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a><<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T>></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#677-679' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Sends the provided message along this channel.</p>
|
||
<p>This is an unbounded sender, so this function differs from <code>Sink::send</code>
|
||
by ensuring the return type reflects that the channel is always ready to
|
||
receive messages.</p>
|
||
</div></div>
|
||
<h2 id='implementations' class='small-section-header'>
|
||
Trait Implementations<a href='#implementations' class='anchor'></a>
|
||
</h2>
|
||
<h3 id='impl-Debug' class='impl'><span class='in-band'><code>impl<T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a>> <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> for <a class="struct" href="../../../futures/sync/mpsc/struct.UnboundedSender.html" title="struct futures::sync::mpsc::UnboundedSender">UnboundedSender</a><T></code><a href='#impl-Debug' class='anchor'></a></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#110' title='goto source code'>[src]</a></span></h3>
|
||
<div class='impl-items'><h4 id='method.fmt' class="method"><span id='fmt.v' class='invisible'><code>fn <a href='https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html#tymethod.fmt' class='fnname'>fmt</a>(&self, __arg_0: &mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html" title="struct core::fmt::Formatter">Formatter</a>) -> <a class="type" href="https://doc.rust-lang.org/nightly/core/fmt/type.Result.html" title="type core::fmt::Result">Result</a></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#110' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Formats the value using the given formatter. <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html#tymethod.fmt">Read more</a></p>
|
||
</div></div><h3 id='impl-Sink' class='impl'><span class='in-band'><code>impl<T> <a class="trait" href="../../../futures/sink/trait.Sink.html" title="trait futures::sink::Sink">Sink</a> for <a class="struct" href="../../../futures/sync/mpsc/struct.UnboundedSender.html" title="struct futures::sync::mpsc::UnboundedSender">UnboundedSender</a><T></code><a href='#impl-Sink' class='anchor'></a></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#682-697' title='goto source code'>[src]</a></span></h3>
|
||
<div class='impl-items'><h4 id='associatedtype.SinkItem' class="type"><span id='SinkItem.t' class='invisible'><code>type <a href='../../../futures/sink/trait.Sink.html#associatedtype.SinkItem' class="type">SinkItem</a> = T</code></span></h4>
|
||
<div class='docblock'><p>The type of value that the sink accepts.</p>
|
||
</div><h4 id='associatedtype.SinkError' class="type"><span id='SinkError.t' class='invisible'><code>type <a href='../../../futures/sink/trait.Sink.html#associatedtype.SinkError' class="type">SinkError</a> = <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T></code></span></h4>
|
||
<div class='docblock'><p>The type of value produced by the sink when an error occurs.</p>
|
||
</div><h4 id='method.start_send' class="method"><span id='start_send.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#tymethod.start_send' class='fnname'>start_send</a>(&mut self, msg: T) -> <a class="type" href="../../../futures/type.StartSend.html" title="type futures::StartSend">StartSend</a><T, <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T>></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#686-688' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Begin the process of sending a value to the sink. <a href="../../../futures/sink/trait.Sink.html#tymethod.start_send">Read more</a></p>
|
||
</div><h4 id='method.poll_complete' class="method"><span id='poll_complete.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#tymethod.poll_complete' class='fnname'>poll_complete</a>(&mut self) -> <a class="type" href="../../../futures/type.Poll.html" title="type futures::Poll">Poll</a><<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T>></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#690-692' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Flush all output from this sink, if necessary. <a href="../../../futures/sink/trait.Sink.html#tymethod.poll_complete">Read more</a></p>
|
||
</div><h4 id='method.close' class="method"><span id='close.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.close' class='fnname'>close</a>(&mut self) -> <a class="type" href="../../../futures/type.Poll.html" title="type futures::Poll">Poll</a><<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T>></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#694-696' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>A method to indicate that no more values will ever be pushed into this sink. <a href="../../../futures/sink/trait.Sink.html#method.close">Read more</a></p>
|
||
</div><h4 id='method.wait' class="method"><span id='wait.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.wait' class='fnname'>wait</a>(self) -> <a class="struct" href="../../../futures/sink/struct.Wait.html" title="struct futures::sink::Wait">Wait</a><Self> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#296-300' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Creates a new object which will produce a synchronous sink. <a href="../../../futures/sink/trait.Sink.html#method.wait">Read more</a></p>
|
||
</div><h4 id='method.with' class="method"><span id='with.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.with' class='fnname'>with</a><U, F, Fut>(self, f: F) -> <a class="struct" href="../../../futures/sink/struct.With.html" title="struct futures::sink::With">With</a><Self, U, F, Fut> <span class="where fmt-newline">where<br> F: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/function/trait.FnMut.html" title="trait core::ops::function::FnMut">FnMut</a>(U) -> Fut,<br> Fut: <a class="trait" href="../../../futures/future/trait.IntoFuture.html" title="trait futures::future::IntoFuture">IntoFuture</a><Item = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>>,<br> Fut::<a class="type" href="../../../futures/future/trait.IntoFuture.html#associatedtype.Error" title="type futures::future::IntoFuture::Error">Error</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a><Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>>,<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#313-320' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Composes a function in front of the sink. <a href="../../../futures/sink/trait.Sink.html#method.with">Read more</a></p>
|
||
</div><h4 id='method.with_flat_map' class="method"><span id='with_flat_map.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.with_flat_map' class='fnname'>with_flat_map</a><U, F, St>(self, f: F) -> <a class="struct" href="../../../futures/sink/struct.WithFlatMap.html" title="struct futures::sink::WithFlatMap">WithFlatMap</a><Self, U, F, St> <span class="where fmt-newline">where<br> F: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/function/trait.FnMut.html" title="trait core::ops::function::FnMut">FnMut</a>(U) -> St,<br> St: <a class="trait" href="../../../futures/stream/trait.Stream.html" title="trait futures::stream::Stream">Stream</a><Item = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>, Error = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>>,<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#352-358' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Composes a function in front of the sink. <a href="../../../futures/sink/trait.Sink.html#method.with_flat_map">Read more</a></p>
|
||
</div><h4 id='method.sink_map_err' class="method"><span id='sink_map_err.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.sink_map_err' class='fnname'>sink_map_err</a><F, E>(self, f: F) -> <a class="struct" href="../../../futures/sink/struct.SinkMapErr.html" title="struct futures::sink::SinkMapErr">SinkMapErr</a><Self, F> <span class="where fmt-newline">where<br> F: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>) -> E,<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#375-380' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Transforms the error returned by the sink.</p>
|
||
</div><h4 id='method.sink_from_err' class="method"><span id='sink_from_err.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.sink_from_err' class='fnname'>sink_from_err</a><E: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a><Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>>>(self) -> <a class="struct" href="../../../futures/sink/struct.SinkFromErr.html" title="struct futures::sink::SinkFromErr">SinkFromErr</a><Self, E> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#386-390' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Map this sink's error to any error implementing <code>From</code> for this sink's <code>Error</code>, returning a new sink. <a href="../../../futures/sink/trait.Sink.html#method.sink_from_err">Read more</a></p>
|
||
</div><h4 id='method.buffer' class="method"><span id='buffer.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.buffer' class='fnname'>buffer</a>(self, amt: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>) -> <a class="struct" href="../../../futures/sink/struct.Buffer.html" title="struct futures::sink::Buffer">Buffer</a><Self> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#406-410' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Adds a fixed-size buffer to the current sink. <a href="../../../futures/sink/trait.Sink.html#method.buffer">Read more</a></p>
|
||
</div><h4 id='method.fanout' class="method"><span id='fanout.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.fanout' class='fnname'>fanout</a><S>(self, other: S) -> <a class="struct" href="../../../futures/sink/struct.Fanout.html" title="struct futures::sink::Fanout">Fanout</a><Self, S> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,<br> Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,<br> S: <a class="trait" href="../../../futures/sink/trait.Sink.html" title="trait futures::sink::Sink">Sink</a><SinkItem = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>, SinkError = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#416-422' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Fanout items to multiple sinks. <a href="../../../futures/sink/trait.Sink.html#method.fanout">Read more</a></p>
|
||
</div><h4 id='method.flush' class="method"><span id='flush.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.flush' class='fnname'>flush</a>(self) -> <a class="struct" href="../../../futures/sink/struct.Flush.html" title="struct futures::sink::Flush">Flush</a><Self> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#430-434' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>A future that completes when the sink has finished processing all pending requests. <a href="../../../futures/sink/trait.Sink.html#method.flush">Read more</a></p>
|
||
</div><h4 id='method.send' class="method"><span id='send.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.send' class='fnname'>send</a>(self, item: Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>) -> <a class="struct" href="../../../futures/sink/struct.Send.html" title="struct futures::sink::Send">Send</a><Self> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#444-448' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>A future that completes after the given item has been fully processed into the sink, including flushing. <a href="../../../futures/sink/trait.Sink.html#method.send">Read more</a></p>
|
||
</div><h4 id='method.send_all' class="method"><span id='send_all.v' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.send_all' class='fnname'>send_all</a><S>(self, stream: S) -> <a class="struct" href="../../../futures/sink/struct.SendAll.html" title="struct futures::sink::SendAll">SendAll</a><Self, S> <span class="where fmt-newline">where<br> S: <a class="trait" href="../../../futures/stream/trait.Stream.html" title="trait futures::stream::Stream">Stream</a><Item = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>>,<br> Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a><S::<a class="type" href="../../../futures/stream/trait.Stream.html#associatedtype.Error" title="type futures::stream::Stream::Error">Error</a>>,<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#464-470' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>A future that completes after the given stream has been fully processed into the sink, including flushing. <a href="../../../futures/sink/trait.Sink.html#method.send_all">Read more</a></p>
|
||
</div></div><h3 id='impl-Sink-1' class='impl'><span class='in-band'><code>impl<'a, T> <a class="trait" href="../../../futures/sink/trait.Sink.html" title="trait futures::sink::Sink">Sink</a> for &'a <a class="struct" href="../../../futures/sync/mpsc/struct.UnboundedSender.html" title="struct futures::sync::mpsc::UnboundedSender">UnboundedSender</a><T></code><a href='#impl-Sink-1' class='anchor'></a></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#699-715' title='goto source code'>[src]</a></span></h3>
|
||
<div class='impl-items'><h4 id='associatedtype.SinkItem-1' class="type"><span id='SinkItem.t-1' class='invisible'><code>type <a href='../../../futures/sink/trait.Sink.html#associatedtype.SinkItem' class="type">SinkItem</a> = T</code></span></h4>
|
||
<div class='docblock'><p>The type of value that the sink accepts.</p>
|
||
</div><h4 id='associatedtype.SinkError-1' class="type"><span id='SinkError.t-1' class='invisible'><code>type <a href='../../../futures/sink/trait.Sink.html#associatedtype.SinkError' class="type">SinkError</a> = <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T></code></span></h4>
|
||
<div class='docblock'><p>The type of value produced by the sink when an error occurs.</p>
|
||
</div><h4 id='method.start_send-1' class="method"><span id='start_send.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#tymethod.start_send' class='fnname'>start_send</a>(&mut self, msg: T) -> <a class="type" href="../../../futures/type.StartSend.html" title="type futures::StartSend">StartSend</a><T, <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T>></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#703-706' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Begin the process of sending a value to the sink. <a href="../../../futures/sink/trait.Sink.html#tymethod.start_send">Read more</a></p>
|
||
</div><h4 id='method.poll_complete-1' class="method"><span id='poll_complete.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#tymethod.poll_complete' class='fnname'>poll_complete</a>(&mut self) -> <a class="type" href="../../../futures/type.Poll.html" title="type futures::Poll">Poll</a><<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T>></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#708-710' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Flush all output from this sink, if necessary. <a href="../../../futures/sink/trait.Sink.html#tymethod.poll_complete">Read more</a></p>
|
||
</div><h4 id='method.close-1' class="method"><span id='close.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.close' class='fnname'>close</a>(&mut self) -> <a class="type" href="../../../futures/type.Poll.html" title="type futures::Poll">Poll</a><<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.unit.html">()</a>, <a class="struct" href="../../../futures/sync/mpsc/struct.SendError.html" title="struct futures::sync::mpsc::SendError">SendError</a><T>></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#712-714' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>A method to indicate that no more values will ever be pushed into this sink. <a href="../../../futures/sink/trait.Sink.html#method.close">Read more</a></p>
|
||
</div><h4 id='method.wait-1' class="method"><span id='wait.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.wait' class='fnname'>wait</a>(self) -> <a class="struct" href="../../../futures/sink/struct.Wait.html" title="struct futures::sink::Wait">Wait</a><Self> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#296-300' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Creates a new object which will produce a synchronous sink. <a href="../../../futures/sink/trait.Sink.html#method.wait">Read more</a></p>
|
||
</div><h4 id='method.with-1' class="method"><span id='with.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.with' class='fnname'>with</a><U, F, Fut>(self, f: F) -> <a class="struct" href="../../../futures/sink/struct.With.html" title="struct futures::sink::With">With</a><Self, U, F, Fut> <span class="where fmt-newline">where<br> F: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/function/trait.FnMut.html" title="trait core::ops::function::FnMut">FnMut</a>(U) -> Fut,<br> Fut: <a class="trait" href="../../../futures/future/trait.IntoFuture.html" title="trait futures::future::IntoFuture">IntoFuture</a><Item = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>>,<br> Fut::<a class="type" href="../../../futures/future/trait.IntoFuture.html#associatedtype.Error" title="type futures::future::IntoFuture::Error">Error</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a><Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>>,<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#313-320' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Composes a function in front of the sink. <a href="../../../futures/sink/trait.Sink.html#method.with">Read more</a></p>
|
||
</div><h4 id='method.with_flat_map-1' class="method"><span id='with_flat_map.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.with_flat_map' class='fnname'>with_flat_map</a><U, F, St>(self, f: F) -> <a class="struct" href="../../../futures/sink/struct.WithFlatMap.html" title="struct futures::sink::WithFlatMap">WithFlatMap</a><Self, U, F, St> <span class="where fmt-newline">where<br> F: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/function/trait.FnMut.html" title="trait core::ops::function::FnMut">FnMut</a>(U) -> St,<br> St: <a class="trait" href="../../../futures/stream/trait.Stream.html" title="trait futures::stream::Stream">Stream</a><Item = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>, Error = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>>,<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#352-358' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Composes a function in front of the sink. <a href="../../../futures/sink/trait.Sink.html#method.with_flat_map">Read more</a></p>
|
||
</div><h4 id='method.sink_map_err-1' class="method"><span id='sink_map_err.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.sink_map_err' class='fnname'>sink_map_err</a><F, E>(self, f: F) -> <a class="struct" href="../../../futures/sink/struct.SinkMapErr.html" title="struct futures::sink::SinkMapErr">SinkMapErr</a><Self, F> <span class="where fmt-newline">where<br> F: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>(Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>) -> E,<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#375-380' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Transforms the error returned by the sink.</p>
|
||
</div><h4 id='method.sink_from_err-1' class="method"><span id='sink_from_err.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.sink_from_err' class='fnname'>sink_from_err</a><E: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a><Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>>>(self) -> <a class="struct" href="../../../futures/sink/struct.SinkFromErr.html" title="struct futures::sink::SinkFromErr">SinkFromErr</a><Self, E> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#386-390' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Map this sink's error to any error implementing <code>From</code> for this sink's <code>Error</code>, returning a new sink. <a href="../../../futures/sink/trait.Sink.html#method.sink_from_err">Read more</a></p>
|
||
</div><h4 id='method.buffer-1' class="method"><span id='buffer.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.buffer' class='fnname'>buffer</a>(self, amt: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>) -> <a class="struct" href="../../../futures/sink/struct.Buffer.html" title="struct futures::sink::Buffer">Buffer</a><Self> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#406-410' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Adds a fixed-size buffer to the current sink. <a href="../../../futures/sink/trait.Sink.html#method.buffer">Read more</a></p>
|
||
</div><h4 id='method.fanout-1' class="method"><span id='fanout.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.fanout' class='fnname'>fanout</a><S>(self, other: S) -> <a class="struct" href="../../../futures/sink/struct.Fanout.html" title="struct futures::sink::Fanout">Fanout</a><Self, S> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,<br> Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,<br> S: <a class="trait" href="../../../futures/sink/trait.Sink.html" title="trait futures::sink::Sink">Sink</a><SinkItem = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>, SinkError = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#416-422' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Fanout items to multiple sinks. <a href="../../../futures/sink/trait.Sink.html#method.fanout">Read more</a></p>
|
||
</div><h4 id='method.flush-1' class="method"><span id='flush.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.flush' class='fnname'>flush</a>(self) -> <a class="struct" href="../../../futures/sink/struct.Flush.html" title="struct futures::sink::Flush">Flush</a><Self> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#430-434' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>A future that completes when the sink has finished processing all pending requests. <a href="../../../futures/sink/trait.Sink.html#method.flush">Read more</a></p>
|
||
</div><h4 id='method.send-1' class="method"><span id='send.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.send' class='fnname'>send</a>(self, item: Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>) -> <a class="struct" href="../../../futures/sink/struct.Send.html" title="struct futures::sink::Send">Send</a><Self> <span class="where fmt-newline">where<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#444-448' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>A future that completes after the given item has been fully processed into the sink, including flushing. <a href="../../../futures/sink/trait.Sink.html#method.send">Read more</a></p>
|
||
</div><h4 id='method.send_all-1' class="method"><span id='send_all.v-1' class='invisible'><code>fn <a href='../../../futures/sink/trait.Sink.html#method.send_all' class='fnname'>send_all</a><S>(self, stream: S) -> <a class="struct" href="../../../futures/sink/struct.SendAll.html" title="struct futures::sink::SendAll">SendAll</a><Self, S> <span class="where fmt-newline">where<br> S: <a class="trait" href="../../../futures/stream/trait.Stream.html" title="trait futures::stream::Stream">Stream</a><Item = Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkItem" title="type futures::sink::Sink::SinkItem">SinkItem</a>>,<br> Self::<a class="type" href="../../../futures/sink/trait.Sink.html#associatedtype.SinkError" title="type futures::sink::Sink::SinkError">SinkError</a>: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a><S::<a class="type" href="../../../futures/stream/trait.Stream.html#associatedtype.Error" title="type futures::stream::Stream::Error">Error</a>>,<br> Self: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>, </span></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sink/mod.rs.html#464-470' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>A future that completes after the given stream has been fully processed into the sink, including flushing. <a href="../../../futures/sink/trait.Sink.html#method.send_all">Read more</a></p>
|
||
</div></div><h3 id='impl-Clone' class='impl'><span class='in-band'><code>impl<T> <a class="trait" href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a> for <a class="struct" href="../../../futures/sync/mpsc/struct.UnboundedSender.html" title="struct futures::sync::mpsc::UnboundedSender">UnboundedSender</a><T></code><a href='#impl-Clone' class='anchor'></a></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#717-721' title='goto source code'>[src]</a></span></h3>
|
||
<div class='impl-items'><h4 id='method.clone' class="method"><span id='clone.v' class='invisible'><code>fn <a href='https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#tymethod.clone' class='fnname'>clone</a>(&self) -> <a class="struct" href="../../../futures/sync/mpsc/struct.UnboundedSender.html" title="struct futures::sync::mpsc::UnboundedSender">UnboundedSender</a><T></code></span><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../../../src/futures/sync/mpsc/mod.rs.html#718-720' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Returns a copy of the value. <a href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#tymethod.clone">Read more</a></p>
|
||
</div><h4 id='method.clone_from' class="method"><span id='clone_from.v' class='invisible'><code>fn <a href='https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#method.clone_from' class='fnname'>clone_from</a>(&mut self, source: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&</a>Self)</code></span><span class='out-of-band'><div class='ghost'></div><div class='since' title='Stable since Rust version 1.0.0'>1.0.0</div><a class='srclink' href='https://doc.rust-lang.org/nightly/src/core/clone.rs.html#112-114' title='goto source code'>[src]</a></span></h4>
|
||
<div class='docblock'><p>Performs copy-assignment from <code>source</code>. <a href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#method.clone_from">Read more</a></p>
|
||
</div></div></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>⏎</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>
|
||
</div>
|
||
</div>
|
||
</aside>
|
||
|
||
|
||
|
||
<script>
|
||
window.rootPath = "../../../";
|
||
window.currentCrate = "futures";
|
||
</script>
|
||
<script src="../../../main.js"></script>
|
||
<script defer src="../../../search-index.js"></script>
|
||
</body>
|
||
</html> |