blob: 71299de69dfeeaea49ace21d31e1408b3e95cd57 [file] [log] [blame]
<!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="Represents an HTTP header field value."><meta name="keywords" content="rust, rustlang, rust-lang, HeaderValue"><title>HeaderValue in http::header - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Regular.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../FiraSans-Medium.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Regular.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceSerif4-Bold.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../SourceCodePro-Semibold.ttf.woff2"><link rel="stylesheet" href="../../normalize.css"><link rel="stylesheet" href="../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" href="../../ayu.css" disabled><link rel="stylesheet" href="../../dark.css" disabled><link rel="stylesheet" href="../../light.css" id="themeStyle"><script id="default-settings" ></script><script src="../../storage.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../main.js"></script><noscript><link rel="stylesheet" href="../../noscript.css"></noscript><link rel="alternate icon" type="image/png" href="../../favicon-16x16.png"><link rel="alternate icon" type="image/png" href="../../favicon-32x32.png"><link rel="icon" type="image/svg+xml" href="../../favicon.svg"></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">&#9776;</button><a class="sidebar-logo" href="../../http/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2></h2></nav><nav class="sidebar"><a class="sidebar-logo" href="../../http/index.html"><div class="logo-container"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></div></a><h2 class="location"><a href="#">HeaderValue</a></h2><div class="sidebar-elems"><section><h3><a href="#implementations">Methods</a></h3><ul class="block"><li><a href="#method.as_bytes">as_bytes</a></li><li><a href="#method.from_bytes">from_bytes</a></li><li><a href="#method.from_maybe_shared">from_maybe_shared</a></li><li><a href="#method.from_maybe_shared_unchecked">from_maybe_shared_unchecked</a></li><li><a href="#method.from_name">from_name</a></li><li><a href="#method.from_static">from_static</a></li><li><a href="#method.from_str">from_str</a></li><li><a href="#method.is_empty">is_empty</a></li><li><a href="#method.is_sensitive">is_sensitive</a></li><li><a href="#method.len">len</a></li><li><a href="#method.set_sensitive">set_sensitive</a></li><li><a href="#method.to_str">to_str</a></li></ul><h3><a href="#trait-implementations">Trait Implementations</a></h3><ul class="block"><li><a href="#impl-AsRef%3C%5Bu8%5D%3E-for-HeaderValue">AsRef&lt;[u8]&gt;</a></li><li><a href="#impl-Clone-for-HeaderValue">Clone</a></li><li><a href="#impl-Debug-for-HeaderValue">Debug</a></li><li><a href="#impl-Eq-for-HeaderValue">Eq</a></li><li><a href="#impl-From%3C%26%27a%20HeaderValue%3E-for-HeaderValue">From&lt;&amp;&#39;a HeaderValue&gt;</a></li><li><a href="#impl-From%3CHeaderName%3E-for-HeaderValue">From&lt;HeaderName&gt;</a></li><li><a href="#impl-From%3Ci16%3E-for-HeaderValue">From&lt;i16&gt;</a></li><li><a href="#impl-From%3Ci32%3E-for-HeaderValue">From&lt;i32&gt;</a></li><li><a href="#impl-From%3Ci64%3E-for-HeaderValue">From&lt;i64&gt;</a></li><li><a href="#impl-From%3Cisize%3E-for-HeaderValue">From&lt;isize&gt;</a></li><li><a href="#impl-From%3Cu16%3E-for-HeaderValue">From&lt;u16&gt;</a></li><li><a href="#impl-From%3Cu32%3E-for-HeaderValue">From&lt;u32&gt;</a></li><li><a href="#impl-From%3Cu64%3E-for-HeaderValue">From&lt;u64&gt;</a></li><li><a href="#impl-From%3Cusize%3E-for-HeaderValue">From&lt;usize&gt;</a></li><li><a href="#impl-FromStr-for-HeaderValue">FromStr</a></li><li><a href="#impl-Hash-for-HeaderValue">Hash</a></li><li><a href="#impl-Ord-for-HeaderValue">Ord</a></li><li><a href="#impl-PartialEq%3C%26%27a%20T%3E-for-HeaderValue">PartialEq&lt;&amp;&#39;a T&gt;</a></li><li><a href="#impl-PartialEq%3C%5Bu8%5D%3E-for-HeaderValue">PartialEq&lt;[u8]&gt;</a></li><li><a href="#impl-PartialEq%3CHeaderValue%3E-for-%26%27a%20HeaderValue">PartialEq&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialEq%3CHeaderValue%3E-for-%26%27a%20str">PartialEq&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialEq%3CHeaderValue%3E-for-%5Bu8%5D">PartialEq&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialEq%3CHeaderValue%3E-for-HeaderValue">PartialEq&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialEq%3CHeaderValue%3E-for-String">PartialEq&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialEq%3CHeaderValue%3E-for-str">PartialEq&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialEq%3CString%3E-for-HeaderValue">PartialEq&lt;String&gt;</a></li><li><a href="#impl-PartialEq%3Cstr%3E-for-HeaderValue">PartialEq&lt;str&gt;</a></li><li><a href="#impl-PartialOrd%3C%26%27a%20T%3E-for-HeaderValue">PartialOrd&lt;&amp;&#39;a T&gt;</a></li><li><a href="#impl-PartialOrd%3C%5Bu8%5D%3E-for-HeaderValue">PartialOrd&lt;[u8]&gt;</a></li><li><a href="#impl-PartialOrd%3CHeaderValue%3E-for-%26%27a%20HeaderValue">PartialOrd&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialOrd%3CHeaderValue%3E-for-%26%27a%20str">PartialOrd&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialOrd%3CHeaderValue%3E-for-%5Bu8%5D">PartialOrd&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialOrd%3CHeaderValue%3E-for-HeaderValue">PartialOrd&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialOrd%3CHeaderValue%3E-for-String">PartialOrd&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialOrd%3CHeaderValue%3E-for-str">PartialOrd&lt;HeaderValue&gt;</a></li><li><a href="#impl-PartialOrd%3CString%3E-for-HeaderValue">PartialOrd&lt;String&gt;</a></li><li><a href="#impl-PartialOrd%3Cstr%3E-for-HeaderValue">PartialOrd&lt;str&gt;</a></li><li><a href="#impl-TryFrom%3C%26%27a%20%5Bu8%5D%3E-for-HeaderValue">TryFrom&lt;&amp;&#39;a [u8]&gt;</a></li><li><a href="#impl-TryFrom%3C%26%27a%20String%3E-for-HeaderValue">TryFrom&lt;&amp;&#39;a String&gt;</a></li><li><a href="#impl-TryFrom%3C%26%27a%20str%3E-for-HeaderValue">TryFrom&lt;&amp;&#39;a str&gt;</a></li><li><a href="#impl-TryFrom%3CString%3E-for-HeaderValue">TryFrom&lt;String&gt;</a></li><li><a href="#impl-TryFrom%3CVec%3Cu8%2C%20Global%3E%3E-for-HeaderValue">TryFrom&lt;Vec&lt;u8, Global&gt;&gt;</a></li></ul><h3><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul class="block"><li><a href="#impl-RefUnwindSafe-for-HeaderValue">RefUnwindSafe</a></li><li><a href="#impl-Send-for-HeaderValue">Send</a></li><li><a href="#impl-Sync-for-HeaderValue">Sync</a></li><li><a href="#impl-Unpin-for-HeaderValue">Unpin</a></li><li><a href="#impl-UnwindSafe-for-HeaderValue">UnwindSafe</a></li></ul><h3><a href="#blanket-implementations">Blanket Implementations</a></h3><ul class="block"><li><a href="#impl-Any-for-HeaderValue">Any</a></li><li><a href="#impl-Borrow%3CT%3E-for-HeaderValue">Borrow&lt;T&gt;</a></li><li><a href="#impl-BorrowMut%3CT%3E-for-HeaderValue">BorrowMut&lt;T&gt;</a></li><li><a href="#impl-From%3CT%3E-for-HeaderValue">From&lt;T&gt;</a></li><li><a href="#impl-Into%3CU%3E-for-HeaderValue">Into&lt;U&gt;</a></li><li><a href="#impl-ToOwned-for-HeaderValue">ToOwned</a></li><li><a href="#impl-TryFrom%3CU%3E-for-HeaderValue">TryFrom&lt;U&gt;</a></li><li><a href="#impl-TryInto%3CU%3E-for-HeaderValue">TryInto&lt;U&gt;</a></li></ul></section><h2><a href="index.html">In http::header</a></h2></div></nav><main><div class="width-limiter"><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press ‘S’ to search, ‘?’ for more options…" type="search"><div id="help-button" title="help" tabindex="-1"><a href="../../help.html">?</a></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div></div></form></nav><section id="main-content" class="content"><div class="main-heading"><h1 class="fqn">Struct <a href="../index.html">http</a>::<wbr><a href="index.html">header</a>::<wbr><a class="struct" href="#">HeaderValue</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></h1><span class="out-of-band"><a class="srclink" href="../../src/http/header/value.rs.html#21-24">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="item-decl"><pre class="rust struct"><code>pub struct HeaderValue { /* private fields */ }</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Represents an HTTP header field value.</p>
<p>In practice, HTTP header field values are usually valid ASCII. However, the
HTTP spec allows for a header value to contain opaque bytes as well. In this
case, the header field value is not able to be represented as a string.</p>
<p>To handle this, the <code>HeaderValue</code> is useable as a type and can be compared
with strings and implements <code>Debug</code>. A <code>to_str</code> fn is provided that returns
an <code>Err</code> if the header value contains non visible ascii characters.</p>
</div></details><h2 id="implementations" class="small-section-header">Implementations<a href="#implementations" class="anchor"></a></h2><div id="implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#41-359">source</a><a href="#impl-HeaderValue" class="anchor"></a><h3 class="code-header">impl <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from_static" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#83-97">source</a><h4 class="code-header">pub const fn <a href="#method.from_static" class="fnname">from_static</a>(src: &amp;'static str) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class="docblock"><p>Convert a static string to a <code>HeaderValue</code>.</p>
<p>This function will not perform any copying, however the string is
checked to ensure that no invalid characters are present. Only visible
ASCII characters (32-127) are permitted.</p>
<h5 id="panics"><a href="#panics">Panics</a></h5>
<p>This function panics if the argument contains invalid header value
characters.</p>
<p>Until <a href="https://github.com/rust-lang/rfcs/pull/2345">Allow panicking in constants</a>
makes its way into stable, the panic message at compile-time is
going to look cryptic, but should at least point at your header value:</p>
<div class="example-wrap"><pre class="language-text"><code>error: any use of this value will cause an error
--&gt; http/src/header/value.rs:67:17
|
67 | ([] as [u8; 0])[0]; // Invalid header value
| ^^^^^^^^^^^^^^^^^^
| |
| index out of bounds: the length is 0 but the index is 0
| inside `HeaderValue::from_static` at http/src/header/value.rs:67:17
| inside `INVALID_HEADER` at src/main.rs:73:33
|
::: src/main.rs:73:1
|
73 | const INVALID_HEADER: HeaderValue = HeaderValue::from_static(&quot;жsome value&quot;);
| ----------------------------------------------------------------------------</code></pre></div><h5 id="examples"><a href="#examples">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_static(<span class="string">&quot;hello&quot;</span>);
<span class="macro">assert_eq!</span>(val, <span class="string">&quot;hello&quot;</span>);</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from_str" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#125-127">source</a><h4 class="code-header">pub fn <a href="#method.from_str" class="fnname">from_str</a>(src: &amp;str) -&gt; Result&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>, <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a>&gt;</h4></section></summary><div class="docblock"><p>Attempt to convert a string to a <code>HeaderValue</code>.</p>
<p>If the argument contains invalid header value characters, an error is
returned. Only visible ASCII characters (32-127) are permitted. Use
<code>from_bytes</code> to create a <code>HeaderValue</code> that includes opaque octets
(128-255).</p>
<p>This function is intended to be replaced in the future by a <code>TryFrom</code>
implementation once the trait is stabilized in std.</p>
<h5 id="examples-1"><a href="#examples-1">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_str(<span class="string">&quot;hello&quot;</span>).unwrap();
<span class="macro">assert_eq!</span>(val, <span class="string">&quot;hello&quot;</span>);</code></pre></div>
<p>An invalid value</p>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_str(<span class="string">&quot;\n&quot;</span>);
<span class="macro">assert!</span>(val.is_err());</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from_name" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#142-144">source</a><h4 class="code-header">pub fn <a href="#method.from_name" class="fnname">from_name</a>(name: <a class="struct" href="struct.HeaderName.html" title="struct http::header::HeaderName">HeaderName</a>) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class="docblock"><p>Converts a HeaderName into a HeaderValue</p>
<p>Since every valid HeaderName is a valid HeaderValue this is done infallibly.</p>
<h5 id="examples-2"><a href="#examples-2">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_name(ACCEPT);
<span class="macro">assert_eq!</span>(val, HeaderValue::from_bytes(<span class="string">b&quot;accept&quot;</span>).unwrap());</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from_bytes" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#171-173">source</a><h4 class="code-header">pub fn <a href="#method.from_bytes" class="fnname">from_bytes</a>(src: &amp;[u8]) -&gt; Result&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>, <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a>&gt;</h4></section></summary><div class="docblock"><p>Attempt to convert a byte slice to a <code>HeaderValue</code>.</p>
<p>If the argument contains invalid header value bytes, an error is
returned. Only byte values between 32 and 255 (inclusive) are permitted,
excluding byte 127 (DEL).</p>
<p>This function is intended to be replaced in the future by a <code>TryFrom</code>
implementation once the trait is stabilized in std.</p>
<h5 id="examples-3"><a href="#examples-3">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_bytes(<span class="string">b&quot;hello\xfa&quot;</span>).unwrap();
<span class="macro">assert_eq!</span>(val, <span class="kw-2">&amp;</span><span class="string">b&quot;hello\xfa&quot;</span>[..]);</code></pre></div>
<p>An invalid value</p>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_bytes(<span class="string">b&quot;\n&quot;</span>);
<span class="macro">assert!</span>(val.is_err());</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from_maybe_shared" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#179-188">source</a><h4 class="code-header">pub fn <a href="#method.from_maybe_shared" class="fnname">from_maybe_shared</a>&lt;T&gt;(src: T) -&gt; Result&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>, <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a>&gt;<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;T: AsRef&lt;[u8]&gt; + 'static,</span></h4></section></summary><div class="docblock"><p>Attempt to convert a <code>Bytes</code> buffer to a <code>HeaderValue</code>.</p>
<p>This will try to prevent a copy if the type passed is the type used
internally, and will copy the data if it is not.</p>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from_maybe_shared_unchecked" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#194-220">source</a><h4 class="code-header">pub unsafe fn <a href="#method.from_maybe_shared_unchecked" class="fnname">from_maybe_shared_unchecked</a>&lt;T&gt;(src: T) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a><span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;T: AsRef&lt;[u8]&gt; + 'static,</span></h4></section></summary><div class="docblock"><p>Convert a <code>Bytes</code> directly into a <code>HeaderValue</code> without validating.</p>
<p>This function does NOT validate that illegal bytes are not contained
within the buffer.</p>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.to_str" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#251-261">source</a><h4 class="code-header">pub fn <a href="#method.to_str" class="fnname">to_str</a>(&amp;self) -&gt; Result&lt;&amp;str, <a class="struct" href="struct.ToStrError.html" title="struct http::header::ToStrError">ToStrError</a>&gt;</h4></section></summary><div class="docblock"><p>Yields a <code>&amp;str</code> slice if the <code>HeaderValue</code> only contains visible ASCII
chars.</p>
<p>This function will perform a scan of the header value, checking all the
characters.</p>
<h5 id="examples-4"><a href="#examples-4">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_static(<span class="string">&quot;hello&quot;</span>);
<span class="macro">assert_eq!</span>(val.to_str().unwrap(), <span class="string">&quot;hello&quot;</span>);</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.len" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#275-277">source</a><h4 class="code-header">pub fn <a href="#method.len" class="fnname">len</a>(&amp;self) -&gt; usize</h4></section></summary><div class="docblock"><p>Returns the length of <code>self</code>.</p>
<p>This length is in bytes.</p>
<h5 id="examples-5"><a href="#examples-5">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_static(<span class="string">&quot;hello&quot;</span>);
<span class="macro">assert_eq!</span>(val.len(), <span class="number">5</span>);</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.is_empty" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#292-294">source</a><h4 class="code-header">pub fn <a href="#method.is_empty" class="fnname">is_empty</a>(&amp;self) -&gt; bool</h4></section></summary><div class="docblock"><p>Returns true if the <code>HeaderValue</code> has a length of zero bytes.</p>
<h5 id="examples-6"><a href="#examples-6">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_static(<span class="string">&quot;&quot;</span>);
<span class="macro">assert!</span>(val.is_empty());
<span class="kw">let </span>val = HeaderValue::from_static(<span class="string">&quot;hello&quot;</span>);
<span class="macro">assert!</span>(!val.is_empty());</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.as_bytes" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#306-308">source</a><h4 class="code-header">pub fn <a href="#method.as_bytes" class="fnname">as_bytes</a>(&amp;self) -&gt; &amp;[u8]</h4></section></summary><div class="docblock"><p>Converts a <code>HeaderValue</code> to a byte slice.</p>
<h5 id="examples-7"><a href="#examples-7">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span>val = HeaderValue::from_static(<span class="string">&quot;hello&quot;</span>);
<span class="macro">assert_eq!</span>(val.as_bytes(), <span class="string">b&quot;hello&quot;</span>);</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.set_sensitive" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#325-327">source</a><h4 class="code-header">pub fn <a href="#method.set_sensitive" class="fnname">set_sensitive</a>(&amp;mut self, val: bool)</h4></section></summary><div class="docblock"><p>Mark that the header value represents sensitive information.</p>
<h5 id="examples-8"><a href="#examples-8">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span><span class="kw-2">mut </span>val = HeaderValue::from_static(<span class="string">&quot;my secret&quot;</span>);
val.set_sensitive(<span class="bool-val">true</span>);
<span class="macro">assert!</span>(val.is_sensitive());
val.set_sensitive(<span class="bool-val">false</span>);
<span class="macro">assert!</span>(!val.is_sensitive());</code></pre></div>
</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.is_sensitive" class="method has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#356-358">source</a><h4 class="code-header">pub fn <a href="#method.is_sensitive" class="fnname">is_sensitive</a>(&amp;self) -&gt; bool</h4></section></summary><div class="docblock"><p>Returns <code>true</code> if the value represents sensitive data.</p>
<p>Sensitive data could represent passwords or other data that should not
be stored on disk or in memory. By marking header values as sensitive,
components using this crate can be instructed to treat them with special
care for security reasons. For example, caches can avoid storing
sensitive values, and HPACK encoders used by HTTP/2.0 implementations
can choose not to compress them.</p>
<p>Additionally, sensitive values will be masked by the <code>Debug</code>
implementation of <code>HeaderValue</code>.</p>
<p>Note that sensitivity is not factored into equality or ordering.</p>
<h5 id="examples-9"><a href="#examples-9">Examples</a></h5>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">let </span><span class="kw-2">mut </span>val = HeaderValue::from_static(<span class="string">&quot;my secret&quot;</span>);
val.set_sensitive(<span class="bool-val">true</span>);
<span class="macro">assert!</span>(val.is_sensitive());
val.set_sensitive(<span class="bool-val">false</span>);
<span class="macro">assert!</span>(!val.is_sensitive());</code></pre></div>
</div></details></div></details></div><h2 id="trait-implementations" class="small-section-header">Trait Implementations<a href="#trait-implementations" class="anchor"></a></h2><div id="trait-implementations-list"><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-AsRef%3C%5Bu8%5D%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#361-366">source</a><a href="#impl-AsRef%3C%5Bu8%5D%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl AsRef&lt;[u8]&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.as_ref" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#363-365">source</a><a href="#method.as_ref" class="anchor"></a><h4 class="code-header">fn <a class="fnname">as_ref</a>(&amp;self) -&gt; &amp;[u8]</h4></section></summary><div class='docblock'>Converts this type into a shared reference of the (usually inferred) input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-Clone-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#20">source</a><a href="#impl-Clone-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl Clone for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.clone" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#20">source</a><a href="#method.clone" class="anchor"></a><h4 class="code-header">fn <a class="fnname">clone</a>(&amp;self) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Returns a copy of the value. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.clone_from" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.clone_from" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">clone_from</a>(&amp;mut self, source: &amp;Self)</h4></section></summary><div class='docblock'>Performs copy-assignment from <code>source</code>. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-Debug-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#368-394">source</a><a href="#impl-Debug-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl Debug for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.fmt" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#369-393">source</a><a href="#method.fmt" class="anchor"></a><h4 class="code-header">fn <a class="fnname">fmt</a>(&amp;self, f: &amp;mut Formatter&lt;'_&gt;) -&gt; Result</h4></section></summary><div class='docblock'>Formats the value using the given formatter. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3C%26%27a%20HeaderValue%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#518-523">source</a><a href="#impl-From%3C%26%27a%20HeaderValue%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;'a&gt; From&lt;&amp;'a <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-9" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#520-522">source</a><a href="#method.from-9" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(t: &amp;'a <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; Self</h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3CHeaderName%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#396-404">source</a><a href="#impl-From%3CHeaderName%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;<a class="struct" href="struct.HeaderName.html" title="struct http::header::HeaderName">HeaderName</a>&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#398-403">source</a><a href="#method.from" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(h: <a class="struct" href="struct.HeaderName.html" title="struct http::header::HeaderName">HeaderName</a>) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3Ci16%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#impl-From%3Ci16%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;i16&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-2" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#method.from-2" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(num: i16) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3Ci32%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#impl-From%3Ci32%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;i32&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-4" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#method.from-4" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(num: i32) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3Ci64%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#impl-From%3Ci64%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;i64&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-6" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#method.from-6" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(num: i64) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3Cisize%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#477-480">source</a><a href="#impl-From%3Cisize%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;isize&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-8" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#477-480">source</a><a href="#method.from-8" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(num: isize) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3Cu16%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#impl-From%3Cu16%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;u16&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-1" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#method.from-1" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(num: u16) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3Cu32%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#impl-From%3Cu32%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;u32&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-3" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#method.from-3" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(num: u32) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3Cu64%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#impl-From%3Cu64%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;u64&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-5" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#452-462">source</a><a href="#method.from-5" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(num: u64) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-From%3Cusize%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#477-480">source</a><a href="#impl-From%3Cusize%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl From&lt;usize&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-7" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#477-480">source</a><a href="#method.from-7" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(num: usize) -&gt; <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h4></section></summary><div class='docblock'>Converts to this type from the input type.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-FromStr-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#509-516">source</a><a href="#impl-FromStr-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl FromStr for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Err" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Err" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Err</a> = <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a></h4></section></summary><div class='docblock'>The associated error which can be returned from parsing.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from_str-1" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#513-515">source</a><a href="#method.from_str-1" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from_str</a>(s: &amp;str) -&gt; Result&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>, Self::Err&gt;</h4></section></summary><div class='docblock'>Parses a string <code>s</code> to return a value of this type. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-Hash-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#20">source</a><a href="#impl-Hash-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl Hash for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.hash" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#20">source</a><a href="#method.hash" class="anchor"></a><h4 class="code-header">fn <a class="fnname">hash</a>&lt;__H:&nbsp;Hasher&gt;(&amp;self, state: &amp;mut __H)</h4></section></summary><div class='docblock'>Feeds this value into the given [<code>Hasher</code>]. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.hash_slice" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.3.0">1.3.0</span><a href="#method.hash_slice" class="anchor"></a><h4 class="code-header">fn <a class="fnname">hash_slice</a>&lt;H&gt;(data: &amp;[Self], state: &amp;mut H)<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;H: Hasher,</span></h4></section></summary><div class='docblock'>Feeds a slice of this type into the given [<code>Hasher</code>]. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-Ord-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#634-639">source</a><a href="#impl-Ord-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl Ord for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.cmp" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#636-638">source</a><a href="#method.cmp" class="anchor"></a><h4 class="code-header">fn <a class="fnname">cmp</a>(&amp;self, other: &amp;Self) -&gt; Ordering</h4></section></summary><div class='docblock'>This method returns an [<code>Ordering</code>] between <code>self</code> and <code>other</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.max" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.21.0">1.21.0</span><a href="#method.max" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">max</a>(self, other: Self) -&gt; Self</h4></section></summary><div class='docblock'>Compares and returns the maximum of two values. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.min" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.21.0">1.21.0</span><a href="#method.min" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">min</a>(self, other: Self) -&gt; Self</h4></section></summary><div class='docblock'>Compares and returns the minimum of two values. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.clamp" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.50.0">1.50.0</span><a href="#method.clamp" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">clamp</a>(self, min: Self, max: Self) -&gt; Self<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;Self: PartialOrd&lt;Self&gt;,</span></h4></section></summary><div class='docblock'>Restrict a value to a certain interval. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3C%26%27a%20T%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#739-747">source</a><a href="#impl-PartialEq%3C%26%27a%20T%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;'a, T:&nbsp;?Sized&gt; PartialEq&lt;&amp;'a T&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a><span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>: PartialEq&lt;T&gt;,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-8" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#744-746">source</a><a href="#method.eq-8" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;&amp;'a T) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-8" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-8" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3C%5Bu8%5D%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#648-653">source</a><a href="#impl-PartialEq%3C%5Bu8%5D%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl PartialEq&lt;[u8]&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-2" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#650-652">source</a><a href="#method.eq-2" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;[u8]) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-2" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-2" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CHeaderValue%3E-for-%26%27a%20HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#725-730">source</a><a href="#impl-PartialEq%3CHeaderValue%3E-for-%26%27a%20HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;'a&gt; PartialEq&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for &amp;'a <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-7" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#727-729">source</a><a href="#method.eq-7" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-7" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-7" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CHeaderValue%3E-for-%26%27a%20str" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#759-764">source</a><a href="#impl-PartialEq%3CHeaderValue%3E-for-%26%27a%20str" class="anchor"></a><h3 class="code-header">impl&lt;'a&gt; PartialEq&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for &amp;'a str</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-9" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#761-763">source</a><a href="#method.eq-9" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-9" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-9" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CHeaderValue%3E-for-%5Bu8%5D" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#676-681">source</a><a href="#impl-PartialEq%3CHeaderValue%3E-for-%5Bu8%5D" class="anchor"></a><h3 class="code-header">impl PartialEq&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for [u8]</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-4" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#678-680">source</a><a href="#method.eq-4" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-4" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-4" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CHeaderValue%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#618-623">source</a><a href="#impl-PartialEq%3CHeaderValue%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl PartialEq&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#620-622">source</a><a href="#method.eq" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CHeaderValue%3E-for-String" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#711-716">source</a><a href="#impl-PartialEq%3CHeaderValue%3E-for-String" class="anchor"></a><h3 class="code-header">impl PartialEq&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for String</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-6" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#713-715">source</a><a href="#method.eq-6" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-6" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-6" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CHeaderValue%3E-for-str" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#669-674">source</a><a href="#impl-PartialEq%3CHeaderValue%3E-for-str" class="anchor"></a><h3 class="code-header">impl PartialEq&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for str</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-3" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#671-673">source</a><a href="#method.eq-3" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-3" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-3" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3CString%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#697-702">source</a><a href="#impl-PartialEq%3CString%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl PartialEq&lt;String&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-5" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#699-701">source</a><a href="#method.eq-5" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;String) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-5" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-5" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialEq%3Cstr%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#641-646">source</a><a href="#impl-PartialEq%3Cstr%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl PartialEq&lt;str&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.eq-1" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#643-645">source</a><a href="#method.eq-1" class="anchor"></a><h4 class="code-header">fn <a class="fnname">eq</a>(&amp;self, other: &amp;str) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>self</code> and <code>other</code> values to be equal, and is used
by <code>==</code>. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ne-1" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ne-1" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ne</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests for <code>!=</code>. The default implementation is almost always
sufficient, and should not be overridden without very good reason. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3C%26%27a%20T%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#749-757">source</a><a href="#impl-PartialOrd%3C%26%27a%20T%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;'a, T:&nbsp;?Sized&gt; PartialOrd&lt;&amp;'a T&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a><span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>: PartialOrd&lt;T&gt;,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-8" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#754-756">source</a><a href="#method.partial_cmp-8" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;&amp;'a T) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-8" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-8" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-8" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-8" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-8" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-8" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-8" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-8" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3C%5Bu8%5D%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#662-667">source</a><a href="#impl-PartialOrd%3C%5Bu8%5D%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl PartialOrd&lt;[u8]&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-2" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#664-666">source</a><a href="#method.partial_cmp-2" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;[u8]) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-2" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-2" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-2" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-2" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-2" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-2" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-2" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-2" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CHeaderValue%3E-for-%26%27a%20HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#732-737">source</a><a href="#impl-PartialOrd%3CHeaderValue%3E-for-%26%27a%20HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;'a&gt; PartialOrd&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for &amp;'a <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-7" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#734-736">source</a><a href="#method.partial_cmp-7" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-7" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-7" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-7" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-7" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-7" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-7" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-7" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-7" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CHeaderValue%3E-for-%26%27a%20str" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#766-771">source</a><a href="#impl-PartialOrd%3CHeaderValue%3E-for-%26%27a%20str" class="anchor"></a><h3 class="code-header">impl&lt;'a&gt; PartialOrd&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for &amp;'a str</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-9" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#768-770">source</a><a href="#method.partial_cmp-9" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-9" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-9" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-9" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-9" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-9" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-9" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-9" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-9" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CHeaderValue%3E-for-%5Bu8%5D" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#690-695">source</a><a href="#impl-PartialOrd%3CHeaderValue%3E-for-%5Bu8%5D" class="anchor"></a><h3 class="code-header">impl PartialOrd&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for [u8]</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-4" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#692-694">source</a><a href="#method.partial_cmp-4" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-4" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-4" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-4" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-4" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-4" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-4" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-4" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-4" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CHeaderValue%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#627-632">source</a><a href="#impl-PartialOrd%3CHeaderValue%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl PartialOrd&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#629-631">source</a><a href="#method.partial_cmp" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CHeaderValue%3E-for-String" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#718-723">source</a><a href="#impl-PartialOrd%3CHeaderValue%3E-for-String" class="anchor"></a><h3 class="code-header">impl PartialOrd&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for String</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-6" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#720-722">source</a><a href="#method.partial_cmp-6" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-6" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-6" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-6" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-6" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-6" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-6" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-6" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-6" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CHeaderValue%3E-for-str" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#683-688">source</a><a href="#impl-PartialOrd%3CHeaderValue%3E-for-str" class="anchor"></a><h3 class="code-header">impl PartialOrd&lt;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>&gt; for str</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-3" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#685-687">source</a><a href="#method.partial_cmp-3" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;<a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a>) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-3" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-3" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-3" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-3" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-3" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-3" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-3" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-3" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3CString%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#704-709">source</a><a href="#impl-PartialOrd%3CString%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl PartialOrd&lt;String&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-5" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#706-708">source</a><a href="#method.partial_cmp-5" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;String) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-5" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-5" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-5" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-5" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-5" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-5" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-5" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-5" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-PartialOrd%3Cstr%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#655-660">source</a><a href="#impl-PartialOrd%3Cstr%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl PartialOrd&lt;str&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.partial_cmp-1" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#657-659">source</a><a href="#method.partial_cmp-1" class="anchor"></a><h4 class="code-header">fn <a class="fnname">partial_cmp</a>(&amp;self, other: &amp;str) -&gt; Option&lt;Ordering&gt;</h4></section></summary><div class='docblock'>This method returns an ordering between <code>self</code> and <code>other</code> values if one exists. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.lt-1" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.lt-1" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">lt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.le-1" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.le-1" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">le</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests less than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&lt;=</code>
operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.gt-1" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.gt-1" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">gt</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;</code> operator. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.ge-1" class="method trait-impl has-srclink"><span class="since rightside" title="Stable since Rust version 1.0.0">1.0.0</span><a href="#method.ge-1" class="anchor"></a><h4 class="code-header">const fn <a class="fnname">ge</a>(&amp;self, other: &amp;Rhs) -&gt; bool</h4></section></summary><div class='docblock'>This method tests greater than or equal to (for <code>self</code> and <code>other</code>) and is used by the <code>&gt;=</code>
operator. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-TryFrom%3C%26%27a%20%5Bu8%5D%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#542-549">source</a><a href="#impl-TryFrom%3C%26%27a%20%5Bu8%5D%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;'a&gt; TryFrom&lt;&amp;'a [u8]&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Error-2" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Error-2" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Error</a> = <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.try_from-2" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#546-548">source</a><a href="#method.try_from-2" class="anchor"></a><h4 class="code-header">fn <a class="fnname">try_from</a>(t: &amp;'a [u8]) -&gt; Result&lt;Self, Self::Error&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-TryFrom%3C%26%27a%20String%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#534-540">source</a><a href="#impl-TryFrom%3C%26%27a%20String%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;'a&gt; TryFrom&lt;&amp;'a String&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Error-1" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Error-1" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Error</a> = <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.try_from-1" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#537-539">source</a><a href="#method.try_from-1" class="anchor"></a><h4 class="code-header">fn <a class="fnname">try_from</a>(s: &amp;'a String) -&gt; Result&lt;Self, Self::Error&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-TryFrom%3C%26%27a%20str%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#525-532">source</a><a href="#impl-TryFrom%3C%26%27a%20str%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;'a&gt; TryFrom&lt;&amp;'a str&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Error" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Error" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Error</a> = <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.try_from" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#529-531">source</a><a href="#method.try_from" class="anchor"></a><h4 class="code-header">fn <a class="fnname">try_from</a>(t: &amp;'a str) -&gt; Result&lt;Self, Self::Error&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-TryFrom%3CString%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#551-558">source</a><a href="#impl-TryFrom%3CString%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl TryFrom&lt;String&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Error-3" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Error-3" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Error</a> = <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.try_from-3" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#555-557">source</a><a href="#method.try_from-3" class="anchor"></a><h4 class="code-header">fn <a class="fnname">try_from</a>(t: String) -&gt; Result&lt;Self, Self::Error&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="rustdoc-toggle implementors-toggle" open><summary><section id="impl-TryFrom%3CVec%3Cu8%2C%20Global%3E%3E-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#560-567">source</a><a href="#impl-TryFrom%3CVec%3Cu8%2C%20Global%3E%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl TryFrom&lt;Vec&lt;u8, Global&gt;&gt; for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Error-4" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Error-4" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Error</a> = <a class="struct" href="struct.InvalidHeaderValue.html" title="struct http::header::InvalidHeaderValue">InvalidHeaderValue</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.try_from-4" class="method trait-impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#564-566">source</a><a href="#method.try_from-4" class="anchor"></a><h4 class="code-header">fn <a class="fnname">try_from</a>(vec: Vec&lt;u8&gt;) -&gt; Result&lt;Self, Self::Error&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><section id="impl-Eq-for-HeaderValue" class="impl has-srclink"><a class="srclink rightside" href="../../src/http/header/value.rs.html#625">source</a><a href="#impl-Eq-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl Eq for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></div><h2 id="synthetic-implementations" class="small-section-header">Auto Trait Implementations<a href="#synthetic-implementations" class="anchor"></a></h2><div id="synthetic-implementations-list"><section id="impl-RefUnwindSafe-for-HeaderValue" class="impl has-srclink"><a href="#impl-RefUnwindSafe-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl RefUnwindSafe for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section><section id="impl-Send-for-HeaderValue" class="impl has-srclink"><a href="#impl-Send-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl Send for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section><section id="impl-Sync-for-HeaderValue" class="impl has-srclink"><a href="#impl-Sync-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl Sync for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section><section id="impl-Unpin-for-HeaderValue" class="impl has-srclink"><a href="#impl-Unpin-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl Unpin for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section><section id="impl-UnwindSafe-for-HeaderValue" class="impl has-srclink"><a href="#impl-UnwindSafe-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl UnwindSafe for <a class="struct" href="struct.HeaderValue.html" title="struct http::header::HeaderValue">HeaderValue</a></h3></section></div><h2 id="blanket-implementations" class="small-section-header">Blanket Implementations<a href="#blanket-implementations" class="anchor"></a></h2><div id="blanket-implementations-list"><details class="rustdoc-toggle implementors-toggle"><summary><section id="impl-Any-for-HeaderValue" class="impl has-srclink"><a href="#impl-Any-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;T&gt; Any for T<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;T: 'static + ?Sized,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.type_id" class="method trait-impl has-srclink"><a href="#method.type_id" class="anchor"></a><h4 class="code-header">fn <a class="fnname">type_id</a>(&amp;self) -&gt; TypeId</h4></section></summary><div class='docblock'>Gets the <code>TypeId</code> of <code>self</code>. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle"><summary><section id="impl-Borrow%3CT%3E-for-HeaderValue" class="impl has-srclink"><a href="#impl-Borrow%3CT%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;T&gt; Borrow&lt;T&gt; for T<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;T: ?Sized,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.borrow" class="method trait-impl has-srclink"><span class="since rightside" title="const unstable">const: <a href="https://github.com/rust-lang/rust/issues/91522" title="Tracking issue for const_borrow">unstable</a></span><a href="#method.borrow" class="anchor"></a><h4 class="code-header">fn <a class="fnname">borrow</a>(&amp;self) -&gt; &amp;T</h4></section></summary><div class='docblock'>Immutably borrows from an owned value. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle"><summary><section id="impl-BorrowMut%3CT%3E-for-HeaderValue" class="impl has-srclink"><a href="#impl-BorrowMut%3CT%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;T&gt; BorrowMut&lt;T&gt; for T<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;T: ?Sized,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.borrow_mut" class="method trait-impl has-srclink"><span class="since rightside" title="const unstable">const: <a href="https://github.com/rust-lang/rust/issues/91522" title="Tracking issue for const_borrow">unstable</a></span><a href="#method.borrow_mut" class="anchor"></a><h4 class="code-header">fn <a class="fnname">borrow_mut</a>(&amp;mut self) -&gt; &amp;mut T</h4></section></summary><div class='docblock'>Mutably borrows from an owned value. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle"><summary><section id="impl-From%3CT%3E-for-HeaderValue" class="impl has-srclink"><a href="#impl-From%3CT%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;T&gt; From&lt;T&gt; for T</h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.from-10" class="method trait-impl has-srclink"><span class="since rightside" title="const unstable">const: <a href="https://github.com/rust-lang/rust/issues/88674" title="Tracking issue for const_convert">unstable</a></span><a href="#method.from-10" class="anchor"></a><h4 class="code-header">fn <a class="fnname">from</a>(t: T) -&gt; T</h4></section></summary><div class="docblock"><p>Returns the argument unchanged.</p>
</div></details></div></details><details class="rustdoc-toggle implementors-toggle"><summary><section id="impl-Into%3CU%3E-for-HeaderValue" class="impl has-srclink"><a href="#impl-Into%3CU%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;T, U&gt; Into&lt;U&gt; for T<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;U: From&lt;T&gt;,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle method-toggle" open><summary><section id="method.into" class="method trait-impl has-srclink"><span class="since rightside" title="const unstable">const: <a href="https://github.com/rust-lang/rust/issues/88674" title="Tracking issue for const_convert">unstable</a></span><a href="#method.into" class="anchor"></a><h4 class="code-header">fn <a class="fnname">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>[From]&lt;T&gt; for U</code> chooses to do.</p>
</div></details></div></details><details class="rustdoc-toggle implementors-toggle"><summary><section id="impl-ToOwned-for-HeaderValue" class="impl has-srclink"><a href="#impl-ToOwned-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;T&gt; ToOwned for T<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;T: Clone,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Owned" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Owned" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Owned</a> = T</h4></section></summary><div class='docblock'>The resulting type after obtaining ownership.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.to_owned" class="method trait-impl has-srclink"><a href="#method.to_owned" class="anchor"></a><h4 class="code-header">fn <a class="fnname">to_owned</a>(&amp;self) -&gt; T</h4></section></summary><div class='docblock'>Creates owned data from borrowed data, usually by cloning. <a>Read more</a></div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.clone_into" class="method trait-impl has-srclink"><a href="#method.clone_into" class="anchor"></a><h4 class="code-header">fn <a class="fnname">clone_into</a>(&amp;self, target: &amp;mut T)</h4></section></summary><div class='docblock'>Uses borrowed data to replace owned data, usually by cloning. <a>Read more</a></div></details></div></details><details class="rustdoc-toggle implementors-toggle"><summary><section id="impl-TryFrom%3CU%3E-for-HeaderValue" class="impl has-srclink"><a href="#impl-TryFrom%3CU%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;T, U&gt; TryFrom&lt;U&gt; for T<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;U: Into&lt;T&gt;,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Error-6" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Error-6" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Error</a> = Infallible</h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.try_from-5" class="method trait-impl has-srclink"><span class="since rightside" title="const unstable">const: <a href="https://github.com/rust-lang/rust/issues/88674" title="Tracking issue for const_convert">unstable</a></span><a href="#method.try_from-5" class="anchor"></a><h4 class="code-header">fn <a class="fnname">try_from</a>(value: U) -&gt; Result&lt;T, &lt;T as TryFrom&lt;U&gt;&gt;::Error&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="rustdoc-toggle implementors-toggle"><summary><section id="impl-TryInto%3CU%3E-for-HeaderValue" class="impl has-srclink"><a href="#impl-TryInto%3CU%3E-for-HeaderValue" class="anchor"></a><h3 class="code-header">impl&lt;T, U&gt; TryInto&lt;U&gt; for T<span class="where fmt-newline">where<br>&nbsp;&nbsp;&nbsp;&nbsp;U: TryFrom&lt;T&gt;,</span></h3></section></summary><div class="impl-items"><details class="rustdoc-toggle" open><summary><section id="associatedtype.Error-5" class="associatedtype trait-impl has-srclink"><a href="#associatedtype.Error-5" class="anchor"></a><h4 class="code-header">type <a class="associatedtype">Error</a> = &lt;U as TryFrom&lt;T&gt;&gt;::Error</h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="rustdoc-toggle method-toggle" open><summary><section id="method.try_into" class="method trait-impl has-srclink"><span class="since rightside" title="const unstable">const: <a href="https://github.com/rust-lang/rust/issues/88674" title="Tracking issue for const_convert">unstable</a></span><a href="#method.try_into" class="anchor"></a><h4 class="code-header">fn <a class="fnname">try_into</a>(self) -&gt; Result&lt;U, &lt;U as TryFrom&lt;T&gt;&gt;::Error&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details></div></section></div></main><div id="rustdoc-vars" data-root-path="../../" data-current-crate="http" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.66.0-nightly (5c8bff74b 2022-10-21)" ></div></body></html>