1
0
mirror of https://github.com/actix/actix-website synced 2025-03-16 05:02:45 +01:00
2018-10-10 08:38:33 -07:00

249 lines
17 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!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 `fut` mod in crate `actix_web`."><meta name="keywords" content="rust, rustlang, rust-lang, fut"><title>actix_web::actix::fut - Rust</title><link rel="stylesheet" type="text/css" href="../../../normalize.css"><link rel="stylesheet" type="text/css" href="../../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../../dark.css"><link rel="stylesheet" type="text/css" href="../../../light.css" id="themeStyle"><script src="../../../storage.js"></script></head><body class="rustdoc mod"><!--[if lte IE 8]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="sidebar"><div class="sidebar-menu">&#9776;</div><p class='location'>Module fut</p><div class="sidebar-elems"><div class="block items"><ul><li><a href="#structs">Structs</a></li><li><a href="#enums">Enums</a></li><li><a href="#traits">Traits</a></li><li><a href="#functions">Functions</a></li></ul></div><p class='location'><a href='../../index.html'>actix_web</a>::<wbr><a href='../index.html'>actix</a></p><script>window.sidebarCurrent = {name: 'fut', ty: 'mod', 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"><a id="settings-menu" href="../../../settings.html"><img src="../../../wheel.svg" width="18" alt="Change settings"></a></div></form></nav><section id="main" class="content"><h1 class='fqn'><span class='out-of-band'><span id='render-detail'><a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class='inner'>&#x2212;</span>]</a></span></span><span class='in-band'>Module <a href='../../index.html'>actix_web</a>::<wbr><a href='../index.html'>actix</a>::<wbr><a class="mod" href=''>fut</a></span></h1><div class='docblock'><p>Custom <code>Future</code> implementation with <code>Actix</code> support</p>
</div><h2 id='structs' class='section-header'><a href="#structs">Structs</a></h2>
<table>
<tr class=' module-item'>
<td><a class="struct" href="struct.AndThen.html"
title='struct actix_web::actix::fut::AndThen'>AndThen</a></td>
<td class='docblock-short'>
<p>Future for the <code>and_then</code> combinator, chaining a computation onto the end of
another future which completes successfully.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.DropErr.html"
title='struct actix_web::actix::fut::DropErr'>DropErr</a></td>
<td class='docblock-short'>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.Finish.html"
title='struct actix_web::actix::fut::Finish'>Finish</a></td>
<td class='docblock-short'>
<p>A combinator used to convert stream into a future, future resolves
when stream completes.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.FromErr.html"
title='struct actix_web::actix::fut::FromErr'>FromErr</a></td>
<td class='docblock-short'>
<p>Future for the <code>from_err</code> combinator, changing the error type of a future.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.FutureResult.html"
title='struct actix_web::actix::fut::FutureResult'>FutureResult</a></td>
<td class='docblock-short'>
<p>A future representing a value that is immediately ready.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.FutureWrap.html"
title='struct actix_web::actix::fut::FutureWrap'>FutureWrap</a></td>
<td class='docblock-short'>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.Map.html"
title='struct actix_web::actix::fut::Map'>Map</a></td>
<td class='docblock-short'>
<p>Future for the <code>map</code> combinator, changing the type of a future.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.MapErr.html"
title='struct actix_web::actix::fut::MapErr'>MapErr</a></td>
<td class='docblock-short'>
<p>Future for the <code>map_err</code> combinator, changing the error type of a future.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.StreamAndThen.html"
title='struct actix_web::actix::fut::StreamAndThen'>StreamAndThen</a></td>
<td class='docblock-short'>
<p>A stream combinator which chains a computation onto values produced by a
stream.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.StreamFinish.html"
title='struct actix_web::actix::fut::StreamFinish'>StreamFinish</a></td>
<td class='docblock-short'>
<p>A combinator used to convert stream into a future, future resolves
when stream completes.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.StreamFold.html"
title='struct actix_web::actix::fut::StreamFold'>StreamFold</a></td>
<td class='docblock-short'>
<p>A future used to collect all the results of a stream into one generic type.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.StreamMap.html"
title='struct actix_web::actix::fut::StreamMap'>StreamMap</a></td>
<td class='docblock-short'>
<p>A stream combinator which will change the type of a stream from one
type to another.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.StreamMapErr.html"
title='struct actix_web::actix::fut::StreamMapErr'>StreamMapErr</a></td>
<td class='docblock-short'>
<p>A stream combinator which will change the error type of a stream from one
type to another.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.StreamThen.html"
title='struct actix_web::actix::fut::StreamThen'>StreamThen</a></td>
<td class='docblock-short'>
<p>A stream combinator which chains a computation onto each item produced by a
stream.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.StreamTimeout.html"
title='struct actix_web::actix::fut::StreamTimeout'>StreamTimeout</a></td>
<td class='docblock-short'>
<p>Future for the <code>timeout</code> combinator, interrupts computations if it takes
more than <code>timeout</code>.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.StreamWrap.html"
title='struct actix_web::actix::fut::StreamWrap'>StreamWrap</a></td>
<td class='docblock-short'>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.Then.html"
title='struct actix_web::actix::fut::Then'>Then</a></td>
<td class='docblock-short'>
<p>Future for the <code>then</code> combinator, chaining computations on the end of
another future regardless of its outcome.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="struct" href="struct.Timeout.html"
title='struct actix_web::actix::fut::Timeout'>Timeout</a></td>
<td class='docblock-short'>
<p>Future for the <code>timeout</code> combinator, interrupts computations if it takes
more than <code>timeout</code>.</p>
</td>
</tr></table><h2 id='enums' class='section-header'><a href="#enums">Enums</a></h2>
<table>
<tr class=' module-item'>
<td><a class="enum" href="enum.Either.html"
title='enum actix_web::actix::fut::Either'>Either</a></td>
<td class='docblock-short'>
<p>Combines two different futures yielding the same item and error
types into a single type.</p>
</td>
</tr></table><h2 id='traits' class='section-header'><a href="#traits">Traits</a></h2>
<table>
<tr class=' module-item'>
<td><a class="trait" href="trait.ActorFuture.html"
title='trait actix_web::actix::fut::ActorFuture'>ActorFuture</a></td>
<td class='docblock-short'>
<p>Trait for types which are a placeholder of a value that may become
available at some later point in time.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="trait" href="trait.ActorStream.html"
title='trait actix_web::actix::fut::ActorStream'>ActorStream</a></td>
<td class='docblock-short'>
<p>A stream of values, not all of which may have been produced yet.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="trait" href="trait.IntoActorFuture.html"
title='trait actix_web::actix::fut::IntoActorFuture'>IntoActorFuture</a></td>
<td class='docblock-short'>
<p>Class of types which can be converted into an actor future.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="trait" href="trait.WrapFuture.html"
title='trait actix_web::actix::fut::WrapFuture'>WrapFuture</a></td>
<td class='docblock-short'>
<p>Helper trait that allows conversion of normal future into <code>ActorFuture</code></p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="trait" href="trait.WrapStream.html"
title='trait actix_web::actix::fut::WrapStream'>WrapStream</a></td>
<td class='docblock-short'>
<p>Helper trait that allows conversion of normal stream into <code>ActorStream</code></p>
</td>
</tr></table><h2 id='functions' class='section-header'><a href="#functions">Functions</a></h2>
<table>
<tr class=' module-item'>
<td><a class="fn" href="fn.err.html"
title='fn actix_web::actix::fut::err'>err</a></td>
<td class='docblock-short'>
<p>Creates a &quot;leaf future&quot; from an immediate value of a failed computation.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="fn" href="fn.ok.html"
title='fn actix_web::actix::fut::ok'>ok</a></td>
<td class='docblock-short'>
<p>Creates a &quot;leaf future&quot; from an immediate value of a finished and
successful computation.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="fn" href="fn.result.html"
title='fn actix_web::actix::fut::result'>result</a></td>
<td class='docblock-short'>
<p>Creates a new &quot;leaf future&quot; which will resolve with the given result.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="fn" href="fn.wrap_future.html"
title='fn actix_web::actix::fut::wrap_future'>wrap_future</a></td>
<td class='docblock-short'>
<p>Converts normal future into <code>ActorFuture</code>, allowing its processing to
use the actor's state.</p>
</td>
</tr>
<tr class=' module-item'>
<td><a class="fn" href="fn.wrap_stream.html"
title='fn actix_web::actix::fut::wrap_stream'>wrap_stream</a></td>
<td class='docblock-short'>
<p>Converts normal stream into <code>ActorStream</code></p>
</td>
</tr></table></section><section id="search" class="content hidden"></section><section class="footer"></section><aside id="help" class="hidden"><div><h1 class="hidden">Help</h1><div class="shortcuts"><h2>Keyboard Shortcuts</h2><dl><dt><kbd>?</kbd></dt><dd>Show this help dialog</dd><dt><kbd>S</kbd></dt><dd>Focus the search field</dd><dt><kbd></kbd></dt><dd>Move up in search results</dd><dt><kbd></kbd></dt><dd>Move down in search results</dd><dt><kbd></kbd></dt><dd>Switch tab</dd><dt><kbd>&#9166;</kbd></dt><dd>Go to active search result</dd><dt><kbd>+</kbd></dt><dd>Expand all sections</dd><dt><kbd>-</kbd></dt><dd>Collapse all sections</dd></dl></div><div class="infos"><h2>Search Tricks</h2><p>Prefix searches with a type followed by a colon (e.g. <code>fn:</code>) to restrict the search to a given type.</p><p>Accepted types are: <code>fn</code>, <code>mod</code>, <code>struct</code>, <code>enum</code>, <code>trait</code>, <code>type</code>, <code>macro</code>, and <code>const</code>.</p><p>Search functions by type signature (e.g. <code>vec -> usize</code> or <code>* -> vec</code>)</p><p>Search multiple things at once by splitting your query with comma (e.g. <code>str,u8</code> or <code>String,struct:Vec,test</code>)</p></div></div></aside><script>window.rootPath = "../../../";window.currentCrate = "actix_web";</script><script src="../../../aliases.js"></script><script src="../../../main.js"></script><script defer src="../../../search-index.js"></script></body></html>