1
0
mirror of https://github.com/fafhrd91/actix-web synced 2024-11-27 17:52:56 +01:00
actix-web/actix_web/web/index.html

22 lines
14 KiB
HTML
Raw Permalink Normal View History

<!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="Essentials helper functions and types for application registration."><title>actix_web::web - 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-dd39b87e5fcfba68.css"><meta name="rustdoc-vars" data-root-path="../../" data-static-root-path="../../static.files/" data-current-crate="actix_web" data-themes="" data-resource-suffix="" data-rustdoc-version="1.80.0-nightly (bdbbb6c6a 2024-05-26)" data-channel="nightly" data-search-js="search-d52510db62a78183.js" data-settings-js="settings-4313503d2e1961c2.js" ><script src="../../static.files/storage-118b08c4c78b968e.js"></script><script defer src="../sidebar-items.js"></script><script defer src="../../static.files/main-20a3ad099b048cf2.js"></script><noscript><link rel="stylesheet" href="../../static.files/noscript-df360f571f6edeae.css"></noscript><link rel="icon" href="https://actix.rs/favicon.ico"></head><body class="rustdoc mod"><!--[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_web/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_web/index.html"><img src="https://actix.rs/img/logo.png" alt="logo"></a><h2><a href="../../actix_web/index.html">actix_web</a><span class="version">4.6.0</span></h2></div><h2 class="location"><a href="#">Module web</a></h2><div class="sidebar-elems"><section><ul class="block"><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></section><h2><a href="../index.html">In crate actix_web</a></h2></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"><h1>Module <a href="../index.html">actix_web</a>::<wbr><a class="mod" href="#">web</a><button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><span class="out-of-band"><a class="src" href="../../src/actix_web/web.rs.html#1-213">source</a> · <button id="toggle-all-docs" title="collapse all docs">[<span>&#x2212;</span>]</button></span></div><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Essentials helper functions and types for application registration.</p>
<h2 id="request-extractors"><a class="doc-anchor" href="#request-extractors">§</a>Request Extractors</h2>
<ul>
<li><a href="struct.Data.html" title="struct actix_web::web::Data"><code>Data</code></a>: Application data item</li>
<li><a href="struct.ReqData.html" title="struct actix_web::web::ReqData"><code>ReqData</code></a>: Request-local data item</li>
<li><a href="struct.Path.html" title="struct actix_web::web::Path"><code>Path</code></a>: URL path parameters / dynamic segments</li>
<li><a href="struct.Query.html" title="struct actix_web::web::Query"><code>Query</code></a>: URL query parameters</li>
<li><a href="struct.Header.html" title="struct actix_web::web::Header"><code>Header</code></a>: Typed header</li>
<li><a href="struct.Json.html" title="struct actix_web::web::Json"><code>Json</code></a>: JSON payload</li>
<li><a href="struct.Form.html" title="struct actix_web::web::Form"><code>Form</code></a>: URL-encoded payload</li>
<li><a href="struct.Bytes.html" title="struct actix_web::web::Bytes"><code>Bytes</code></a>: Raw payload</li>
</ul>
<h2 id="responders"><a class="doc-anchor" href="#responders">§</a>Responders</h2>
<ul>
<li><a href="struct.Json.html" title="struct actix_web::web::Json"><code>Json</code></a>: JSON response</li>
<li><a href="struct.Form.html" title="struct actix_web::web::Form"><code>Form</code></a>: URL-encoded response</li>
<li><a href="struct.Bytes.html" title="struct actix_web::web::Bytes"><code>Bytes</code></a>: Raw bytes response</li>
<li><a href="struct.Redirect.html#method.to" title="associated function actix_web::web::Redirect::to"><code>Redirect</code></a>: Convenient redirect responses</li>
</ul>
</div></details><h2 id="structs" class="section-header">Structs<a href="#structs" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="struct" href="struct.Bytes.html" title="struct actix_web::web::Bytes">Bytes</a></div><div class="desc docblock-short">A cheaply cloneable and sliceable chunk of contiguous memory.</div></li><li><div class="item-name"><a class="struct" href="struct.BytesMut.html" title="struct actix_web::web::BytesMut">BytesMut</a></div><div class="desc docblock-short">A unique reference to a contiguous slice of memory.</div></li><li><div class="item-name"><a class="struct" href="struct.Data.html" title="struct actix_web::web::Data">Data</a></div><div class="desc docblock-short">Application data wrapper and extractor.</div></li><li><div class="item-name"><a class="struct" href="struct.Form.html" title="struct actix_web::web::Form">Form</a></div><div class="desc docblock-short">URL encoded payload extractor and responder.</div></li><li><div class="item-name"><a class="struct" href="struct.FormConfig.html" title="struct actix_web::web::FormConfig">FormConfig</a></div><div class="desc docblock-short"><a href="struct.Form.html" title="struct actix_web::web::Form"><code>Form</code></a> extractor configuration.</div></li><li><div class="item-name"><a class="struct" href="struct.Header.html" title="struct actix_web::web::Header">Header</a></div><div class="desc docblock-short">Extract typed headers from the request.</div></li><li><div class="item-name"><a class="struct" href="struct.Json.html" title="struct actix_web::web::Json">Json</a></div><div class="desc docblock-short">JSON extractor and responder.</div></li><li><div class="item-name"><a class="struct" href="struct.JsonConfig.html" title="struct actix_web::web::JsonConfig">JsonConfig</a></div><div class="desc docblock-short"><code>Json</code> extractor configuration.</div></li><li><div class="item-name"><a class="struct" href="struct.Path.html" title="struct actix_web::web::Path">Path</a></div><div class="desc docblock-short">Extract typed data from request path segments.</div></li><li><div class="item-name"><a class="struct" href="struct.PathConfig.html" title="struct actix_web::web::PathConfig">PathConfig</a></div><div class="desc docblock-short">Path extractor configuration</div></li><li><div class="item-name"><a class="struct" href="struct.Payload.html" title="struct actix_web::web::Payload">Payload</a></div><div class="desc docblock-short">Extract a requests raw payload stream.</div></li><li><div class="item-name"><a class="struct" href="struct.PayloadConfig.html" title="struct actix_web::web::PayloadConfig">PayloadConfig</a></div><div class="desc docblock-short">Configuration for request payloads.</div></li><li><div class="item-name"><a class="struct" href="struct.Query.html" title="struct actix_web::web::Query">Query</a></div><div class="desc docblock-short">Extract typed information from the requests query.</div></li><li><div class="item-name"><a class="struct" href="struct.QueryConfig.html" title="struct actix_web::web::QueryConfig">QueryConfig</a></div><div class="desc docblock-short">Query extractor configuration.</div></li><li><div class="item-name"><a class="struct" href="struct.Readlines.html" title="struct actix_web::web::Readlines">Readlines</a></div><div class="desc docblock-short">Stream that reads request line by line.</div></li><li><div class="item-name"><a class="struct" href="struct.Redirect.html" title="struct actix_web::web::Redirect">Redirect</a></div><div class="desc docblock-short">An HTTP service for redirecting one path to another path or URL.</div></li><li><div class="item-name"><a class="struct" href="struct.ReqData.html" title="struct actix_web::web::ReqData">ReqData</a></div><div class="desc docblock-short">Request-local data extractor.</div></li><li><div class="item-name"><a class="struct" href="struct.ServiceConfig.html" title="struct actix_web::web::ServiceConfig">ServiceConfig</a></div><div class="desc docblock-short">Enables parts of app configuration to be declared separately fro
modularizing large applications.</div></li><li><div class="item-name"><a class="struct" href="struct.UrlEncoded.html" title="struct actix_web::web::UrlEncoded">UrlEncoded</a></div><div class="desc docblock-short">Future that resolves to some <code>T</code> when parsed from a URL encoded payload.</div></li></ul><h2 id="enums" class="section-header">Enums<a href="#enums" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="enum" href="enum.Either.html" title="enum actix_web::web::Either">Either</a></div><div class="desc docblock-short">Combines two extractor or responder types into a single type.</div></li><li><div class="item-name"><a class="enum" href="enum.JsonBody.html" title="enum actix_web::web::JsonBody">JsonBody</a></div><div class="desc docblock-short">Future that resolves to some <code>T</code> when parsed from a JSON payload.</div></li></ul><h2 id="traits" class="section-header">Traits<a href="#traits" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="trait" href="trait.Buf.html" title="trait actix_web::web::Buf">Buf</a></div><div class="desc docblock-short">Read bytes from a buffer.</div></li><li><div class="item-name"><a class="trait" href="trait.BufMut.html" title="trait actix_web::web::BufMut">BufMut</a></div><div class="desc docblock-short">A trait for values that provide sequential write access to bytes.</div></li></ul><h2 id="functions" class="section-header">Functions<a href="#functions" class="anchor">§</a></h2><ul class="item-table"><li><div class="item-name"><a class="fn" href="fn.block.html" title="fn actix_web::web::block">block</a></div><div class="desc docblock-short">Executes blocking function on a thread pool, returns future that resolves to result of the
function execution.</div></li><li><div class="item-name"><a class="fn" href="fn.delete.html" title="fn actix_web::web::delete">delete</a></div><div class="desc docblock-short">Creates a new route with <code>DELETE</code> method guard.</div></li><li><div class="item-name"><a class="fn" href="fn.get.html" title="fn actix_web::web::get">get</a></div><div class="desc docblock-short">Creates a new route with <code>GET</code> method guard.</div></li><li><div class="item-name"><a class="fn" href="fn.head.html" title="fn actix_web::web::head">head</a></div><div class="desc docblock-short">Creates a new route with <code>HEAD</code> method guard.</div></li><li><div class="item-name"><a class="fn" href="fn.method.html" title="fn actix_web::web::method">method</a></div><div class="desc docblock-short">Creates a new route with specified method guard.</div></li><li><div class="item-name"><a class="fn" href="fn.patch.html" title="fn actix_web::web::patch">patch</a></div><div class="desc docblock-short">Creates a new route with <code>PATCH</code> method guard.</div></li><li><div class="item-name"><a class="fn" href="fn.post.html" title="fn actix_web::web::post">post</a></div><div class="desc docblock-short">Creates a new route with <code>POST</code> method guard.</div></li><li><div class="item-name"><a class="fn" href="fn.put.html" title="fn actix_web::web::put">put</a></div><div class="desc docblock-short">Creates a new route with <code>PUT</code> method guard.</div></li><li><div class="item-name"><a class="fn" href="fn.redirect.html" title="fn actix_web::web::redirect">redirect</a></div><div class="desc docblock-short">Create a relative or absolute redirect.</div></li><li><div class="item-name"><a class="fn" href="fn.resource.html" title="fn actix_web::web::resource">resource</a></div><div class="desc docblock-short">Creates a new resource for a specific path.</div></li><li><div class="item-name"><a class="fn" href="fn.route.html" title="fn actix_web::web::route">route</a></div><div class="desc docblock-short">Creates a new un-configured route.</div></li><li><div class="item-name"><a class="fn" href="fn.scope.html" title="fn actix_web::web::scope">scope</a></div><div class="desc docblock-short">Creates scope for common path prefix.</div></li><li><div class="item-name"><a class="fn" href="fn.service.html" title="fn actix_web::web::service">service</a></div><div class="desc docblock-short">Creates a raw service for a specific path.</div></li><li><div class="item-name"><a class="fn" href="fn.to.html" title="fn actix_web::web::to">to</a></div><div class="desc docblock-short">Creates a new any-method route with handler.</div></li><li><div class="item-name"><a class="fn" href="fn.trace.html" title="fn actix_web::web::trace">trace</a></div><div class="desc docblock-short">Creates a new route with <code>TRACE</code> method guard.</div></li></ul></section></div></main></body></html>