1
0
mirror of https://github.com/fafhrd91/actix-net synced 2024-11-27 18:02:58 +01:00
actix-net/actix_codec/struct.Framed.html
2024-10-01 00:01:00 +00:00

117 lines
58 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="A unified `Stream` and `Sink` interface to an underlying I/O object, using the `Encoder` and `Decoder` traits to encode and decode frames."><title>Framed in actix_codec - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-46f98efaafac5295.ttf.woff2,FiraSans-Regular-018c141bf0843ffd.woff2,FiraSans-Medium-8f9a781e4970d388.woff2,SourceCodePro-Regular-562dcc5011b6de7d.ttf.woff2,SourceCodePro-Semibold-d899c5a5c4aeb14a.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2" crossorigin href="../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../static.files/normalize-76eba96aa4d2e634.css"><link rel="stylesheet" href="../static.files/rustdoc-b778ab399e080a4b.css"><meta name="rustdoc-vars" data-root-path="../" data-static-root-path="../static.files/" data-current-crate="actix_codec" data-themes="" data-resource-suffix="" data-rustdoc-version="1.83.0-nightly (7608018cb 2024-09-29)" data-channel="nightly" data-search-js="search-e056c65ede92db13.js" data-settings-js="settings-805db61a62df4bd2.js" ><script src="../static.files/storage-1d39b6787ed640ff.js"></script><script defer src="sidebar-items.js"></script><script defer src="../static.files/main-54bc299d2a5e4e43.js"></script><noscript><link rel="stylesheet" href="../static.files/noscript-0111fcff984fae8f.css"></noscript><link rel="icon" href="https://actix.rs/favicon.ico"></head><body class="rustdoc struct"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle" title="show sidebar"></button><a class="logo-container" href="../actix_codec/index.html"><img src="https://actix.rs/img/logo.png" alt=""></a></nav><nav class="sidebar"><div class="sidebar-crate"><a class="logo-container" href="../actix_codec/index.html"><img src="https://actix.rs/img/logo.png" alt="logo"></a><h2><a href="../actix_codec/index.html">actix_<wbr>codec</a><span class="version">0.5.2</span></h2></div><div class="sidebar-elems"><section id="rustdoc-toc"><h2 class="location"><a href="#">Framed</a></h2><h3><a href="#implementations">Methods</a></h3><ul class="block method"><li><a href="#method.close" title="close">close</a></li><li><a href="#method.codec_mut" title="codec_mut">codec_mut</a></li><li><a href="#method.codec_ref" title="codec_ref">codec_ref</a></li><li><a href="#method.flush" title="flush">flush</a></li><li><a href="#method.from_parts" title="from_parts">from_parts</a></li><li><a href="#method.into_map_codec" title="into_map_codec">into_map_codec</a></li><li><a href="#method.into_map_io" title="into_map_io">into_map_io</a></li><li><a href="#method.into_parts" title="into_parts">into_parts</a></li><li><a href="#method.io_mut" title="io_mut">io_mut</a></li><li><a href="#method.io_pin" title="io_pin">io_pin</a></li><li><a href="#method.io_ref" title="io_ref">io_ref</a></li><li><a href="#method.is_read_buf_empty" title="is_read_buf_empty">is_read_buf_empty</a></li><li><a href="#method.is_write_buf_empty" title="is_write_buf_empty">is_write_buf_empty</a></li><li><a href="#method.is_write_buf_full" title="is_write_buf_full">is_write_buf_full</a></li><li><a href="#method.is_write_ready" title="is_write_ready">is_write_ready</a></li><li><a href="#method.new" title="new">new</a></li><li><a href="#method.next_item" title="next_item">next_item</a></li><li><a href="#method.replace_codec" title="replace_codec">replace_codec</a></li><li><a href="#method.write" title="write">write</a></li></ul><h3><a href="#trait-implementations">Trait Implementations</a></h3><ul class="block trait-implementation"><li><a href="#impl-Debug-for-Framed%3CT,+U%3E" title="Debug">Debug</a></li><li><a href="#impl-Sink%3CI%3E-for-Framed%3CT,+U%3E" title="Sink&#60;I&#62;">Sink&#60;I&#62;</a></li><li><a href="#impl-Stream-for-Framed%3CT,+U%3E" title="Stream">Stream</a></li><li><a href="#impl-Unpin-for-Framed%3CT,+U%3E" title="Unpin">Unpin</a></li></ul><h3><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul class="block synthetic-implementation"><li><a href="#impl-Freeze-for-Framed%3CT,+U%3E" title="Freeze">Freeze</a></li><li><a href="#impl-RefUnwindSafe-for-Framed%3CT,+U%3E" title="RefUnwindSafe">RefUnwindSafe</a></li><li><a href="#impl-Send-for-Framed%3CT,+U%3E" title="Send">Send</a></li><li><a href="#impl-Sync-for-Framed%3CT,+U%3E" title="Sync">Sync</a></li><li><a href="#impl-UnwindSafe-for-Framed%3CT,+U%3E" title="UnwindSafe">UnwindSafe</a></li></ul><h3><a href="#blanket-implementations">Blanket Implementations</a></h3><ul class="block blanket-implementation"><li><a href="#impl-Any-for-T" title="Any">Any</a></li><li><a href="#impl-Borrow%3CT%3E-for-T" title="Borrow&#60;T&#62;">Borrow&#60;T&#62;</a></li><li><a href="#impl-BorrowMut%3CT%3E-for-T" title="BorrowMut&#60;T&#62;">BorrowMut&#60;T&#62;</a></li><li><a href="#impl-From%3CT%3E-for-T" title="From&#60;T&#62;">From&#60;T&#62;</a></li><li><a href="#impl-Instrument-for-T" title="Instrument">Instrument</a></li><li><a href="#impl-Into%3CU%3E-for-T" title="Into&#60;U&#62;">Into&#60;U&#62;</a></li><li><a href="#impl-TryFrom%3CU%3E-for-T" title="TryFrom&#60;U&#62;">TryFrom&#60;U&#62;</a></li><li><a href="#impl-TryInto%3CU%3E-for-T" title="TryInto&#60;U&#62;">TryInto&#60;U&#62;</a></li><li><a href="#impl-TryStream-for-S" title="TryStream">TryStream</a></li><li><a href="#impl-WithSubscriber-for-T" title="WithSubscriber">WithSubscriber</a></li></ul></section><div id="rustdoc-modnav"><h2 class="in-crate"><a href="index.html">In crate actix_<wbr>codec</a></h2></div></div></nav><div class="sidebar-resizer"></div><main><div class="width-limiter"><rustdoc-search></rustdoc-search><section id="main-content" class="content"><div class="main-heading"><span class="rustdoc-breadcrumbs"><a href="index.html">actix_codec</a></span><h1>Struct <span class="struct">Framed</span><button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"><a class="src" href="../src/actix_codec/framed.rs.html#28-44">source</a> </span></div><pre class="rust item-decl"><code>pub struct Framed&lt;T, U&gt; { <span class="comment">/* private fields */</span> }</code></pre><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>A unified <code>Stream</code> and <code>Sink</code> interface to an underlying I/O object, using the <code>Encoder</code> and
<code>Decoder</code> traits to encode and decode frames.</p>
<p>Raw I/O objects work with byte sequences, but higher-level code usually wants to batch these
into meaningful chunks, called “frames”. This method layers framing on top of an I/O object,
by using the <code>Encoder</code>/<code>Decoder</code> traits to handle encoding and decoding of message frames.
Note that the incoming and outgoing frame types may be distinct.</p>
</div></details><h2 id="implementations" class="section-header">Implementations<a href="#implementations" class="anchor">§</a></h2><div id="implementations-list"><details class="toggle implementors-toggle" open><summary><section id="impl-Framed%3CT,+U%3E" class="impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#46-63">source</a><a href="#impl-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="trait.AsyncRead.html" title="trait actix_codec::AsyncRead">AsyncRead</a> + <a class="trait" href="trait.AsyncWrite.html" title="trait actix_codec::AsyncWrite">AsyncWrite</a>,
U: <a class="trait" href="trait.Decoder.html" title="trait actix_codec::Decoder">Decoder</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.new" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#54-62">source</a><h4 class="code-header">pub fn <a href="#method.new" class="fn">new</a>(io: T, codec: U) -&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;</h4></section></summary><div class="docblock"><p>This function returns a <em>single</em> object that is both <code>Stream</code> and <code>Sink</code>; grouping this into
a single object is often useful for layering things like gzip or TLS, which require both
read and write access to the underlying object.</p>
</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Framed%3CT,+U%3E-1" class="impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#65-157">source</a><a href="#impl-Framed%3CT,+U%3E-1" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.codec_ref" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#67-69">source</a><h4 class="code-header">pub fn <a href="#method.codec_ref" class="fn">codec_ref</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;U</a></h4></section></summary><div class="docblock"><p>Returns a reference to the underlying codec.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.codec_mut" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#72-74">source</a><h4 class="code-header">pub fn <a href="#method.codec_mut" class="fn">codec_mut</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut U</a></h4></section></summary><div class="docblock"><p>Returns a mutable reference to the underlying codec.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.io_ref" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#80-82">source</a><h4 class="code-header">pub fn <a href="#method.io_ref" class="fn">io_ref</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;T</a></h4></section></summary><div class="docblock"><p>Returns a reference to the underlying I/O stream wrapped by <code>Frame</code>.</p>
<p>Note that care should be taken to not tamper with the underlying stream of data coming in as
it may corrupt the stream of frames otherwise being worked with.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.io_mut" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#88-90">source</a><h4 class="code-header">pub fn <a href="#method.io_mut" class="fn">io_mut</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut T</a></h4></section></summary><div class="docblock"><p>Returns a mutable reference to the underlying I/O stream.</p>
<p>Note that care should be taken to not tamper with the underlying stream of data coming in as
it may corrupt the stream of frames otherwise being worked with.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.io_pin" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#93-95">source</a><h4 class="code-header">pub fn <a href="#method.io_pin" class="fn">io_pin</a>(self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut T</a>&gt;</h4></section></summary><div class="docblock"><p>Returns a <code>Pin</code> of a mutable reference to the underlying I/O stream.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.is_read_buf_empty" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#98-100">source</a><h4 class="code-header">pub fn <a href="#method.is_read_buf_empty" class="fn">is_read_buf_empty</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Check if read buffer is empty.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.is_write_buf_empty" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#103-105">source</a><h4 class="code-header">pub fn <a href="#method.is_write_buf_empty" class="fn">is_write_buf_empty</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Check if write buffer is empty.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.is_write_buf_full" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#108-110">source</a><h4 class="code-header">pub fn <a href="#method.is_write_buf_full" class="fn">is_write_buf_full</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Check if write buffer is full.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.is_write_ready" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#115-117">source</a><h4 class="code-header">pub fn <a href="#method.is_write_ready" class="fn">is_write_ready</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Check if framed is able to write more data.</p>
<p><code>Framed</code> object considers ready if there is free space in write buffer.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.replace_codec" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#120-128">source</a><h4 class="code-header">pub fn <a href="#method.replace_codec" class="fn">replace_codec</a>&lt;U2&gt;(self, codec: U2) -&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U2&gt;</h4></section></summary><div class="docblock"><p>Consume the <code>Frame</code>, returning <code>Frame</code> with different codec.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.into_map_io" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#131-142">source</a><h4 class="code-header">pub fn <a href="#method.into_map_io" class="fn">into_map_io</a>&lt;F, T2&gt;(self, f: F) -&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T2, U&gt;<div class="where">where
F: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/function/trait.Fn.html" title="trait core::ops::function::Fn">Fn</a>(T) -&gt; T2,</div></h4></section></summary><div class="docblock"><p>Consume the <code>Frame</code>, returning <code>Frame</code> with different io.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.into_map_codec" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#145-156">source</a><h4 class="code-header">pub fn <a href="#method.into_map_codec" class="fn">into_map_codec</a>&lt;F, U2&gt;(self, f: F) -&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U2&gt;<div class="where">where
F: <a class="trait" href="https://doc.rust-lang.org/nightly/core/ops/function/trait.Fn.html" title="trait core::ops::function::Fn">Fn</a>(U) -&gt; U2,</div></h4></section></summary><div class="docblock"><p>Consume the <code>Frame</code>, returning <code>Frame</code> with different codec.</p>
</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Framed%3CT,+U%3E-2" class="impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#159-280">source</a><a href="#impl-Framed%3CT,+U%3E-2" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.write" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#161-174">source</a><h4 class="code-header">pub fn <a href="#method.write" class="fn">write</a>&lt;I&gt;(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;,
item: I,
) -&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>, &lt;U as <a class="trait" href="trait.Encoder.html" title="trait actix_codec::Encoder">Encoder</a>&lt;I&gt;&gt;::<a class="associatedtype" href="trait.Encoder.html#associatedtype.Error" title="type actix_codec::Encoder::Error">Error</a>&gt;<div class="where">where
T: <a class="trait" href="trait.AsyncWrite.html" title="trait actix_codec::AsyncWrite">AsyncWrite</a>,
U: <a class="trait" href="trait.Encoder.html" title="trait actix_codec::Encoder">Encoder</a>&lt;I&gt;,</div></h4></section></summary><div class="docblock"><p>Serialize item and write to the inner buffer</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.next_item" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#177-234">source</a><h4 class="code-header">pub fn <a href="#method.next_item" class="fn">next_item</a>(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;,
cx: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/task/wake/struct.Context.html" title="struct core::task::wake::Context">Context</a>&lt;'_&gt;,
) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/task/poll/enum.Poll.html" title="enum core::task::poll::Poll">Poll</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;&lt;U as <a class="trait" href="trait.Decoder.html" title="trait actix_codec::Decoder">Decoder</a>&gt;::<a class="associatedtype" href="trait.Decoder.html#associatedtype.Item" title="type actix_codec::Decoder::Item">Item</a>, U::<a class="associatedtype" href="trait.Decoder.html#associatedtype.Error" title="type actix_codec::Decoder::Error">Error</a>&gt;&gt;&gt;<div class="where">where
T: <a class="trait" href="trait.AsyncRead.html" title="trait actix_codec::AsyncRead">AsyncRead</a>,
U: <a class="trait" href="trait.Decoder.html" title="trait actix_codec::Decoder">Decoder</a>,</div></h4></section></summary><div class="docblock"><p>Try to read underlying I/O stream and decode item.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.flush" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#237-267">source</a><h4 class="code-header">pub fn <a href="#method.flush" class="fn">flush</a>&lt;I&gt;(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;,
cx: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/task/wake/struct.Context.html" title="struct core::task::wake::Context">Context</a>&lt;'_&gt;,
) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/task/poll/enum.Poll.html" title="enum core::task::poll::Poll">Poll</a>&lt;<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>, U::<a class="associatedtype" href="trait.Encoder.html#associatedtype.Error" title="type actix_codec::Encoder::Error">Error</a>&gt;&gt;<div class="where">where
T: <a class="trait" href="trait.AsyncWrite.html" title="trait actix_codec::AsyncWrite">AsyncWrite</a>,
U: <a class="trait" href="trait.Encoder.html" title="trait actix_codec::Encoder">Encoder</a>&lt;I&gt;,</div></h4></section></summary><div class="docblock"><p>Flush write buffer to underlying I/O stream.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.close" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#270-279">source</a><h4 class="code-header">pub fn <a href="#method.close" class="fn">close</a>&lt;I&gt;(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;,
cx: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/task/wake/struct.Context.html" title="struct core::task::wake::Context">Context</a>&lt;'_&gt;,
) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/task/poll/enum.Poll.html" title="enum core::task::poll::Poll">Poll</a>&lt;<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>, U::<a class="associatedtype" href="trait.Encoder.html#associatedtype.Error" title="type actix_codec::Encoder::Error">Error</a>&gt;&gt;<div class="where">where
T: <a class="trait" href="trait.AsyncWrite.html" title="trait actix_codec::AsyncWrite">AsyncWrite</a>,
U: <a class="trait" href="trait.Encoder.html" title="trait actix_codec::Encoder">Encoder</a>&lt;I&gt;,</div></h4></section></summary><div class="docblock"><p>Flush write buffer and shutdown underlying I/O stream.</p>
</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Framed%3CT,+U%3E-3" class="impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#336-367">source</a><a href="#impl-Framed%3CT,+U%3E-3" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from_parts" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#343-351">source</a><h4 class="code-header">pub fn <a href="#method.from_parts" class="fn">from_parts</a>(parts: <a class="struct" href="struct.FramedParts.html" title="struct actix_codec::FramedParts">FramedParts</a>&lt;T, U&gt;) -&gt; <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;</h4></section></summary><div class="docblock"><p>This function returns a <em>single</em> object that is both <code>Stream</code> and <code>Sink</code>; grouping this into
a single object is often useful for layering things like gzip or TLS, which require both
read and write access to the underlying object.</p>
<p>These objects take a stream, a read buffer and a write buffer. These fields can be obtained
from an existing <code>Framed</code> with the <code>into_parts</code> method.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.into_parts" class="method"><a class="src rightside" href="../src/actix_codec/framed.rs.html#358-366">source</a><h4 class="code-header">pub fn <a href="#method.into_parts" class="fn">into_parts</a>(self) -&gt; <a class="struct" href="struct.FramedParts.html" title="struct actix_codec::FramedParts">FramedParts</a>&lt;T, U&gt;</h4></section></summary><div class="docblock"><p>Consumes the <code>Frame</code>, returning its underlying I/O stream, the buffer with unprocessed data,
and the codec.</p>
<p>Note that care should be taken to not tamper with the underlying stream of data coming in as
it may corrupt the stream of frames otherwise being worked with.</p>
</div></details></div></details></div><h2 id="trait-implementations" class="section-header">Trait Implementations<a href="#trait-implementations" class="anchor">§</a></h2><div id="trait-implementations-list"><details class="toggle implementors-toggle" open><summary><section id="impl-Debug-for-Framed%3CT,+U%3E" class="impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#323-334">source</a><a href="#impl-Debug-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <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="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a>,
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.fmt" class="method trait-impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#328-333">source</a><a href="#method.fmt" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/fmt/trait.Debug.html#tymethod.fmt" class="fn">fmt</a>(&amp;self, f: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html" title="struct core::fmt::Formatter">Formatter</a>&lt;'_&gt;) -&gt; <a class="type" href="https://doc.rust-lang.org/nightly/core/fmt/type.Result.html" title="type core::fmt::Result">Result</a></h4></section></summary><div class='docblock'>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></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Sink%3CI%3E-for-Framed%3CT,+U%3E" class="impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#294-321">source</a><a href="#impl-Sink%3CI%3E-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U, I&gt; Sink&lt;I&gt; for <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="trait.AsyncWrite.html" title="trait actix_codec::AsyncWrite">AsyncWrite</a>,
U: <a class="trait" href="trait.Encoder.html" title="trait actix_codec::Encoder">Encoder</a>&lt;I&gt;,
U::<a class="associatedtype" href="trait.Encoder.html#associatedtype.Error" title="type actix_codec::Encoder::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>&lt;<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;,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error" class="associatedtype trait-impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#300">source</a><a href="#associatedtype.Error" class="anchor">§</a><h4 class="code-header">type <a class="associatedtype">Error</a> = &lt;U as <a class="trait" href="trait.Encoder.html" title="trait actix_codec::Encoder">Encoder</a>&lt;I&gt;&gt;::<a class="associatedtype" href="trait.Encoder.html#associatedtype.Error" title="type actix_codec::Encoder::Error">Error</a></h4></section></summary><div class='docblock'>The type of value produced by the sink when an error occurs.</div></details><details class="toggle method-toggle" open><summary><section id="method.poll_ready" class="method trait-impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#302-308">source</a><a href="#method.poll_ready" class="anchor">§</a><h4 class="code-header">fn <a class="fn">poll_ready</a>(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;,
cx: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/task/wake/struct.Context.html" title="struct core::task::wake::Context">Context</a>&lt;'_&gt;,
) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/task/poll/enum.Poll.html" title="enum core::task::poll::Poll">Poll</a>&lt;<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>, Self::Error&gt;&gt;</h4></section></summary><div class='docblock'>Attempts to prepare the <code>Sink</code> to receive a value. <a>Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.start_send" class="method trait-impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#310-312">source</a><a href="#method.start_send" class="anchor">§</a><h4 class="code-header">fn <a class="fn">start_send</a>(self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;, item: I) -&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>, Self::Error&gt;</h4></section></summary><div class='docblock'>Begin the process of sending a value to the sink.
Each call to this function must be preceded by a successful call to
<code>poll_ready</code> which returned <code>Poll::Ready(Ok(()))</code>. <a>Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.poll_flush" class="method trait-impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#314-316">source</a><a href="#method.poll_flush" class="anchor">§</a><h4 class="code-header">fn <a class="fn">poll_flush</a>(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;,
cx: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/task/wake/struct.Context.html" title="struct core::task::wake::Context">Context</a>&lt;'_&gt;,
) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/task/poll/enum.Poll.html" title="enum core::task::poll::Poll">Poll</a>&lt;<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>, Self::Error&gt;&gt;</h4></section></summary><div class='docblock'>Flush any remaining output from this sink. <a>Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.poll_close" class="method trait-impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#318-320">source</a><a href="#method.poll_close" class="anchor">§</a><h4 class="code-header">fn <a class="fn">poll_close</a>(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;,
cx: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/task/wake/struct.Context.html" title="struct core::task::wake::Context">Context</a>&lt;'_&gt;,
) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/task/poll/enum.Poll.html" title="enum core::task::poll::Poll">Poll</a>&lt;<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>, Self::Error&gt;&gt;</h4></section></summary><div class='docblock'>Flush any remaining output and close this sink, if necessary. <a>Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Stream-for-Framed%3CT,+U%3E" class="impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#282-292">source</a><a href="#impl-Stream-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; Stream for <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="trait.AsyncRead.html" title="trait actix_codec::AsyncRead">AsyncRead</a>,
U: <a class="trait" href="trait.Decoder.html" title="trait actix_codec::Decoder">Decoder</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Item" class="associatedtype trait-impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#287">source</a><a href="#associatedtype.Item" class="anchor">§</a><h4 class="code-header">type <a class="associatedtype">Item</a> = <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;&lt;U as <a class="trait" href="trait.Decoder.html" title="trait actix_codec::Decoder">Decoder</a>&gt;::<a class="associatedtype" href="trait.Decoder.html#associatedtype.Item" title="type actix_codec::Decoder::Item">Item</a>, &lt;U as <a class="trait" href="trait.Decoder.html" title="trait actix_codec::Decoder">Decoder</a>&gt;::<a class="associatedtype" href="trait.Decoder.html#associatedtype.Error" title="type actix_codec::Decoder::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Values yielded by the stream.</div></details><details class="toggle method-toggle" open><summary><section id="method.poll_next" class="method trait-impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#289-291">source</a><a href="#method.poll_next" class="anchor">§</a><h4 class="code-header">fn <a class="fn">poll_next</a>(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;&amp;mut Self&gt;,
cx: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/task/wake/struct.Context.html" title="struct core::task::wake::Context">Context</a>&lt;'_&gt;,
) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/task/poll/enum.Poll.html" title="enum core::task::poll::Poll">Poll</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;Self::Item&gt;&gt;</h4></section></summary><div class='docblock'>Attempt to pull out the next value of this stream, registering the
current task for wakeup if the value is not yet available, and returning
<code>None</code> if the stream is exhausted. <a>Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.size_hint" class="method trait-impl"><a href="#method.size_hint" class="anchor">§</a><h4 class="code-header">fn <a class="fn">size_hint</a>(&amp;self) -&gt; (<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>, <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.usize.html">usize</a>&gt;)</h4></section></summary><div class='docblock'>Returns the bounds on the remaining length of the stream. <a>Read more</a></div></details></div></details><section id="impl-Unpin-for-Framed%3CT,+U%3E" class="impl"><a class="src rightside" href="../src/actix_codec/framed.rs.html#28-44">source</a><a href="#impl-Unpin-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;'__pin, T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a> for <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
__Origin&lt;'__pin, T, U&gt;: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a>,</div></h3></section></div><h2 id="synthetic-implementations" class="section-header">Auto Trait Implementations<a href="#synthetic-implementations" class="anchor">§</a></h2><div id="synthetic-implementations-list"><section id="impl-Freeze-for-Framed%3CT,+U%3E" class="impl"><a href="#impl-Freeze-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Freeze.html" title="trait core::marker::Freeze">Freeze</a> for <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Freeze.html" title="trait core::marker::Freeze">Freeze</a>,
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Freeze.html" title="trait core::marker::Freeze">Freeze</a>,</div></h3></section><section id="impl-RefUnwindSafe-for-Framed%3CT,+U%3E" class="impl"><a href="#impl-RefUnwindSafe-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a> for <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a>,
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a>,</div></h3></section><section id="impl-Send-for-Framed%3CT,+U%3E" class="impl"><a href="#impl-Send-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> for <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a>,
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a>,</div></h3></section><section id="impl-Sync-for-Framed%3CT,+U%3E" class="impl"><a href="#impl-Sync-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> for <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a>,
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a>,</div></h3></section><section id="impl-UnwindSafe-for-Framed%3CT,+U%3E" class="impl"><a href="#impl-UnwindSafe-for-Framed%3CT,+U%3E" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a> for <a class="struct" href="struct.Framed.html" title="struct actix_codec::Framed">Framed</a>&lt;T, U&gt;<div class="where">where
T: <a class="trait" href="https://doc.rust-lang.org/nightly/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a>,
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a>,</div></h3></section></div><h2 id="blanket-implementations" class="section-header">Blanket Implementations<a href="#blanket-implementations" class="anchor">§</a></h2><div id="blanket-implementations-list"><details class="toggle implementors-toggle"><summary><section id="impl-Any-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/any.rs.html#138">source</a><a href="#impl-Any-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/any/trait.Any.html" title="trait core::any::Any">Any</a> for T<div class="where">where
T: 'static + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.type_id" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/any.rs.html#139">source</a><a href="#method.type_id" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/any/trait.Any.html#tymethod.type_id" class="fn">type_id</a>(&amp;self) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/core/any/struct.TypeId.html" title="struct core::any::TypeId">TypeId</a></h4></section></summary><div class='docblock'>Gets the <code>TypeId</code> of <code>self</code>. <a href="https://doc.rust-lang.org/nightly/core/any/trait.Any.html#tymethod.type_id">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Borrow%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/borrow.rs.html#209">source</a><a href="#impl-Borrow%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html" title="trait core::borrow::Borrow">Borrow</a>&lt;T&gt; for T<div class="where">where
T: ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.borrow" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/borrow.rs.html#211">source</a><a href="#method.borrow" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html#tymethod.borrow" class="fn">borrow</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;T</a></h4></section></summary><div class='docblock'>Immutably borrows from an owned value. <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.Borrow.html#tymethod.borrow">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-BorrowMut%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/borrow.rs.html#217">source</a><a href="#impl-BorrowMut%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html" title="trait core::borrow::BorrowMut">BorrowMut</a>&lt;T&gt; for T<div class="where">where
T: ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.borrow_mut" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/borrow.rs.html#218">source</a><a href="#method.borrow_mut" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut" class="fn">borrow_mut</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut T</a></h4></section></summary><div class='docblock'>Mutably borrows from an owned value. <a href="https://doc.rust-lang.org/nightly/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-From%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#765">source</a><a href="#impl-From%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt; for T</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#768">source</a><a href="#method.from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(t: T) -&gt; T</h4></section></summary><div class="docblock"><p>Returns the argument unchanged.</p>
</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Instrument-for-T" class="impl"><a href="#impl-Instrument-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; Instrument for T</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.instrument" class="method trait-impl"><a href="#method.instrument" class="anchor">§</a><h4 class="code-header">fn <a class="fn">instrument</a>(self, span: Span) -&gt; Instrumented&lt;Self&gt;</h4></section></summary><div class='docblock'>Instruments this type with the provided [<code>Span</code>], returning an
<code>Instrumented</code> wrapper. <a>Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.in_current_span" class="method trait-impl"><a href="#method.in_current_span" class="anchor">§</a><h4 class="code-header">fn <a class="fn">in_current_span</a>(self) -&gt; Instrumented&lt;Self&gt;</h4></section></summary><div class='docblock'>Instruments this type with the <a href="super::Span::current()">current</a> <a href="crate::Span"><code>Span</code></a>, returning an
<code>Instrumented</code> wrapper. <a>Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Into%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#748-750">source</a><a href="#impl-Into%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;U&gt; for T<div class="where">where
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.into" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#758">source</a><a href="#method.into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html#tymethod.into" class="fn">into</a>(self) -&gt; U</h4></section></summary><div class="docblock"><p>Calls <code>U::from(self)</code>.</p>
<p>That is, this conversion is whatever the implementation of
<code><a href="https://doc.rust-lang.org/nightly/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt; for U</code> chooses to do.</p>
</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-TryFrom%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#805-807">source</a><a href="#impl-TryFrom%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;U&gt; for T<div class="where">where
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error-2" class="associatedtype trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#809">source</a><a href="#associatedtype.Error-2" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#associatedtype.Error" class="associatedtype">Error</a> = <a class="enum" href="https://doc.rust-lang.org/nightly/core/convert/enum.Infallible.html" title="enum core::convert::Infallible">Infallible</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="toggle method-toggle" open><summary><section id="method.try_from" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#812">source</a><a href="#method.try_from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#tymethod.try_from" class="fn">try_from</a>(value: U) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;T, &lt;T as <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;U&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-TryInto%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#790-792">source</a><a href="#impl-TryInto%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryInto.html" title="trait core::convert::TryInto">TryInto</a>&lt;U&gt; for T<div class="where">where
U: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error-1" class="associatedtype trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#794">source</a><a href="#associatedtype.Error-1" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/nightly/core/convert/trait.TryInto.html#associatedtype.Error" class="associatedtype">Error</a> = &lt;U as <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="toggle method-toggle" open><summary><section id="method.try_into" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/nightly/src/core/convert/mod.rs.html#797">source</a><a href="#method.try_into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/nightly/core/convert/trait.TryInto.html#tymethod.try_into" class="fn">try_into</a>(self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;U, &lt;U as <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/nightly/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-TryStream-for-S" class="impl"><a href="#impl-TryStream-for-S" class="anchor">§</a><h3 class="code-header">impl&lt;S, T, E&gt; TryStream for S<div class="where">where
S: Stream&lt;Item = <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;T, E&gt;&gt; + ?<a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Ok" class="associatedtype trait-impl"><a href="#associatedtype.Ok" class="anchor">§</a><h4 class="code-header">type <a class="associatedtype">Ok</a> = T</h4></section></summary><div class='docblock'>The type of successful values yielded by this future</div></details><details class="toggle" open><summary><section id="associatedtype.Error-3" class="associatedtype trait-impl"><a href="#associatedtype.Error-3" class="anchor">§</a><h4 class="code-header">type <a class="associatedtype">Error</a> = E</h4></section></summary><div class='docblock'>The type of failures yielded by this future</div></details><details class="toggle method-toggle" open><summary><section id="method.try_poll_next" class="method trait-impl"><a href="#method.try_poll_next" class="anchor">§</a><h4 class="code-header">fn <a class="fn">try_poll_next</a>(
self: <a class="struct" href="https://doc.rust-lang.org/nightly/core/pin/struct.Pin.html" title="struct core::pin::Pin">Pin</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;mut S</a>&gt;,
cx: &amp;mut <a class="struct" href="https://doc.rust-lang.org/nightly/core/task/wake/struct.Context.html" title="struct core::task::wake::Context">Context</a>&lt;'_&gt;,
) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/task/poll/enum.Poll.html" title="enum core::task::poll::Poll">Poll</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;&lt;S as TryStream&gt;::Ok, &lt;S as TryStream&gt;::Error&gt;&gt;&gt;</h4></section></summary><div class='docblock'>Poll this <code>TryStream</code> as if it were a <code>Stream</code>. <a>Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-WithSubscriber-for-T" class="impl"><a href="#impl-WithSubscriber-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; WithSubscriber for T</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.with_subscriber" class="method trait-impl"><a href="#method.with_subscriber" class="anchor">§</a><h4 class="code-header">fn <a class="fn">with_subscriber</a>&lt;S&gt;(self, subscriber: S) -&gt; WithDispatch&lt;Self&gt;<div class="where">where
S: <a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;Dispatch&gt;,</div></h4></section></summary><div class='docblock'>Attaches the provided <a href="super::Subscriber"><code>Subscriber</code></a> to this type, returning a
[<code>WithDispatch</code>] wrapper. <a>Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.with_current_subscriber" class="method trait-impl"><a href="#method.with_current_subscriber" class="anchor">§</a><h4 class="code-header">fn <a class="fn">with_current_subscriber</a>(self) -&gt; WithDispatch&lt;Self&gt;</h4></section></summary><div class='docblock'>Attaches the current <a href="crate::dispatcher#setting-the-default-subscriber">default</a> <a href="super::Subscriber"><code>Subscriber</code></a> to this type, returning a
[<code>WithDispatch</code>] wrapper. <a>Read more</a></div></details></div></details></div></section></div></main></body></html>