<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="generator" content="rustdoc">
    <meta name="description" content="API documentation for the Rust `HeaderView` struct in crate `ethcore`.">
    <meta name="keywords" content="rust, rustlang, rust-lang, HeaderView">

    <title>ethcore::views::HeaderView - Rust</title>

    <link rel="stylesheet" type="text/css" href="../../rustdoc.css">
    <link rel="stylesheet" type="text/css" href="../../main.css">
    

    
    
</head>
<body class="rustdoc">
    <!--[if lte IE 8]>
    <div class="warning">
        This old browser is unsupported and will most likely display funky
        things.
    </div>
    <![endif]-->

    

    <nav class="sidebar">
        
        <p class='location'><a href='../index.html'>ethcore</a>::<wbr><a href='index.html'>views</a></p><script>window.sidebarCurrent = {name: 'HeaderView', ty: 'struct', relpath: ''};</script><script defer src="sidebar-items.js"></script>
    </nav>

    <nav class="sub">
        <form class="search-form js-only">
            <div class="search-container">
                <input class="search-input" name="search"
                       autocomplete="off"
                       placeholder="Click or press ‘S’ to search, ‘?’ for more options…"
                       type="search">
            </div>
        </form>
    </nav>

    <section id='main' class="content struct">
<h1 class='fqn'><span class='in-band'>Struct <a href='../index.html'>ethcore</a>::<wbr><a href='index.html'>views</a>::<wbr><a class='struct' href=''>HeaderView</a></span><span class='out-of-band'><span id='render-detail'>
                   <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">
                       [<span class='inner'>&#x2212;</span>]
                   </a>
               </span><a id='src-4837' class='srclink' href='../../src/ethcore/ethcore/src/views/header.rs.html#24-26' title='goto source code'>[src]</a></span></h1>
<pre class='rust struct'>pub struct HeaderView&lt;'a&gt; { /* fields omitted */ }</pre><div class='docblock'><p>View onto block header rlp.</p>
</div><h2 id='methods'>Methods</h2><h3 class='impl'><span class='in-band'><code>impl&lt;'a&gt; <a class='struct' href='../../ethcore/views/struct.HeaderView.html' title='ethcore::views::HeaderView'>HeaderView</a>&lt;'a&gt;</code></span><span class='out-of-band'><div class='ghost'></div><a id='src-4840' class='srclink' href='../../src/ethcore/ethcore/src/views/header.rs.html#28-96' title='goto source code'>[src]</a></span></h3>
<div class='impl-items'><h4 id='method.new' class='method'><span id='new.v' class='invisible'><code>fn <a href='#method.new' class='fnname'>new</a>(bytes: <a class='primitive' href='https://doc.rust-lang.org/nightly/std/primitive.slice.html'>&amp;'a [</a><a class='primitive' href='https://doc.rust-lang.org/nightly/std/primitive.u8.html'>u8</a><a class='primitive' href='https://doc.rust-lang.org/nightly/std/primitive.slice.html'>]</a>) -&gt; <a class='struct' href='../../ethcore/views/struct.HeaderView.html' title='ethcore::views::HeaderView'>HeaderView</a>&lt;'a&gt;</code></span></h4>
<div class='docblock'><p>Creates new view onto header from raw bytes.</p>
</div><h4 id='method.new_from_rlp' class='method'><span id='new_from_rlp.v' class='invisible'><code>fn <a href='#method.new_from_rlp' class='fnname'>new_from_rlp</a>(rlp: <a class='struct' href='../../rlp/rlpin/struct.Rlp.html' title='rlp::rlpin::Rlp'>Rlp</a>&lt;'a&gt;) -&gt; <a class='struct' href='../../ethcore/views/struct.HeaderView.html' title='ethcore::views::HeaderView'>HeaderView</a>&lt;'a&gt;</code></span></h4>
<div class='docblock'><p>Creates new view onto header from rlp.</p>
</div><h4 id='method.hash' class='method'><span id='hash.v' class='invisible'><code>fn <a href='#method.hash' class='fnname'>hash</a>(&amp;self) -&gt; <a class='struct' href='../../ethcore_bigint/hash/struct.H256.html' title='ethcore_bigint::hash::H256'>H256</a></code></span></h4>
<div class='docblock'><p>Returns header hash.</p>
</div><h4 id='method.rlp' class='method'><span id='rlp.v' class='invisible'><code>fn <a href='#method.rlp' class='fnname'>rlp</a>(&amp;self) -&gt; &amp;<a class='struct' href='../../rlp/rlpin/struct.Rlp.html' title='rlp::rlpin::Rlp'>Rlp</a>&lt;'a&gt;</code></span></h4>
<div class='docblock'><p>Returns raw rlp.</p>
</div><h4 id='method.parent_hash' class='method'><span id='parent_hash.v' class='invisible'><code>fn <a href='#method.parent_hash' class='fnname'>parent_hash</a>(&amp;self) -&gt; <a class='struct' href='../../ethcore_bigint/hash/struct.H256.html' title='ethcore_bigint::hash::H256'>H256</a></code></span></h4>
<div class='docblock'><p>Returns parent hash.</p>
</div><h4 id='method.uncles_hash' class='method'><span id='uncles_hash.v' class='invisible'><code>fn <a href='#method.uncles_hash' class='fnname'>uncles_hash</a>(&amp;self) -&gt; <a class='struct' href='../../ethcore_bigint/hash/struct.H256.html' title='ethcore_bigint::hash::H256'>H256</a></code></span></h4>
<div class='docblock'><p>Returns uncles hash.</p>
</div><h4 id='method.author' class='method'><span id='author.v' class='invisible'><code>fn <a href='#method.author' class='fnname'>author</a>(&amp;self) -&gt; <a class='type' href='../../ethcore_util/type.Address.html' title='ethcore_util::Address'>Address</a></code></span></h4>
<div class='docblock'><p>Returns author.</p>
</div><h4 id='method.state_root' class='method'><span id='state_root.v' class='invisible'><code>fn <a href='#method.state_root' class='fnname'>state_root</a>(&amp;self) -&gt; <a class='struct' href='../../ethcore_bigint/hash/struct.H256.html' title='ethcore_bigint::hash::H256'>H256</a></code></span></h4>
<div class='docblock'><p>Returns state root.</p>
</div><h4 id='method.transactions_root' class='method'><span id='transactions_root.v' class='invisible'><code>fn <a href='#method.transactions_root' class='fnname'>transactions_root</a>(&amp;self) -&gt; <a class='struct' href='../../ethcore_bigint/hash/struct.H256.html' title='ethcore_bigint::hash::H256'>H256</a></code></span></h4>
<div class='docblock'><p>Returns transactions root.</p>
</div><h4 id='method.receipts_root' class='method'><span id='receipts_root.v' class='invisible'><code>fn <a href='#method.receipts_root' class='fnname'>receipts_root</a>(&amp;self) -&gt; <a class='struct' href='../../ethcore_bigint/hash/struct.H256.html' title='ethcore_bigint::hash::H256'>H256</a></code></span></h4>
<div class='docblock'><p>Returns block receipts root.</p>
</div><h4 id='method.log_bloom' class='method'><span id='log_bloom.v' class='invisible'><code>fn <a href='#method.log_bloom' class='fnname'>log_bloom</a>(&amp;self) -&gt; <a class='struct' href='../../ethcore_bigint/hash/struct.H2048.html' title='ethcore_bigint::hash::H2048'>H2048</a></code></span></h4>
<div class='docblock'><p>Returns block log bloom.</p>
</div><h4 id='method.difficulty' class='method'><span id='difficulty.v' class='invisible'><code>fn <a href='#method.difficulty' class='fnname'>difficulty</a>(&amp;self) -&gt; U256</code></span></h4>
<div class='docblock'><p>Returns block difficulty.</p>
</div><h4 id='method.number' class='method'><span id='number.v' class='invisible'><code>fn <a href='#method.number' class='fnname'>number</a>(&amp;self) -&gt; <a class='type' href='../../ethcore/header/type.BlockNumber.html' title='ethcore::header::BlockNumber'>BlockNumber</a></code></span></h4>
<div class='docblock'><p>Returns block number.</p>
</div><h4 id='method.gas_limit' class='method'><span id='gas_limit.v' class='invisible'><code>fn <a href='#method.gas_limit' class='fnname'>gas_limit</a>(&amp;self) -&gt; U256</code></span></h4>
<div class='docblock'><p>Returns block gas limit.</p>
</div><h4 id='method.gas_used' class='method'><span id='gas_used.v' class='invisible'><code>fn <a href='#method.gas_used' class='fnname'>gas_used</a>(&amp;self) -&gt; U256</code></span></h4>
<div class='docblock'><p>Returns block gas used.</p>
</div><h4 id='method.timestamp' class='method'><span id='timestamp.v' class='invisible'><code>fn <a href='#method.timestamp' class='fnname'>timestamp</a>(&amp;self) -&gt; <a class='primitive' href='https://doc.rust-lang.org/nightly/std/primitive.u64.html'>u64</a></code></span></h4>
<div class='docblock'><p>Returns timestamp.</p>
</div><h4 id='method.extra_data' class='method'><span id='extra_data.v' class='invisible'><code>fn <a href='#method.extra_data' class='fnname'>extra_data</a>(&amp;self) -&gt; <a class='type' href='../../ethcore_util/bytes/type.Bytes.html' title='ethcore_util::bytes::Bytes'>Bytes</a></code></span></h4>
<div class='docblock'><p>Returns block extra data.</p>
</div><h4 id='method.seal' class='method'><span id='seal.v' class='invisible'><code>fn <a href='#method.seal' class='fnname'>seal</a>(&amp;self) -&gt; <a class='struct' href='https://doc.rust-lang.org/nightly/collections/vec/struct.Vec.html' title='collections::vec::Vec'>Vec</a>&lt;<a class='type' href='../../ethcore_util/bytes/type.Bytes.html' title='ethcore_util::bytes::Bytes'>Bytes</a>&gt;</code></span></h4>
<div class='docblock'><p>Returns a vector of post-RLP-encoded seal fields.</p>
</div></div><h2 id='implementations'>Trait Implementations</h2><h3 class='impl'><span class='in-band'><code>impl&lt;'a&gt; <a class='trait' href='../../ethcore_util/sha3/trait.Hashable.html' title='ethcore_util::sha3::Hashable'>Hashable</a> for <a class='struct' href='../../ethcore/views/struct.HeaderView.html' title='ethcore::views::HeaderView'>HeaderView</a>&lt;'a&gt;</code></span><span class='out-of-band'><div class='ghost'></div><a id='src-4880' class='srclink' href='../../src/ethcore/ethcore/src/views/header.rs.html#98-102' title='goto source code'>[src]</a></span></h3>
<div class='impl-items'><h4 id='method.sha3' class='method'><span id='sha3.v' class='invisible'><code>fn <a href='../../ethcore_util/sha3/trait.Hashable.html#tymethod.sha3' class='fnname'>sha3</a>(&amp;self) -&gt; <a class='struct' href='../../ethcore_bigint/hash/struct.H256.html' title='ethcore_bigint::hash::H256'>H256</a></code></span></h4>
<div class='docblock'><p>Calculate SHA3 of this object.</p>
</div><h4 id='method.sha3_into' class='method'><span id='sha3_into.v' class='invisible'><code>fn <a href='../../ethcore_util/sha3/trait.Hashable.html#method.sha3_into' class='fnname'>sha3_into</a>(&amp;self, dest: <a class='primitive' href='https://doc.rust-lang.org/nightly/std/primitive.slice.html'>&amp;mut [</a><a class='primitive' href='https://doc.rust-lang.org/nightly/std/primitive.u8.html'>u8</a><a class='primitive' href='https://doc.rust-lang.org/nightly/std/primitive.slice.html'>]</a>)</code></span></h4>
<div class='docblock'><p>Calculate SHA3 of this object and place result into dest.</p>
</div></div></section>
    <section id='search' class="content hidden"></section>

    <section class="footer"></section>

    <aside id="help" class="hidden">
        <div>
            <h1 class="hidden">Help</h1>

            <div class="shortcuts">
                <h2>Keyboard Shortcuts</h2>

                <dl>
                    <dt>?</dt>
                    <dd>Show this help dialog</dd>
                    <dt>S</dt>
                    <dd>Focus the search field</dd>
                    <dt>&larrb;</dt>
                    <dd>Move up in search results</dd>
                    <dt>&rarrb;</dt>
                    <dd>Move down in search results</dd>
                    <dt>&#9166;</dt>
                    <dd>Go to active search result</dd>
                    <dt>+</dt>
                    <dd>Collapse/expand all sections</dd>
                </dl>
            </div>

            <div class="infos">
                <h2>Search Tricks</h2>

                <p>
                    Prefix searches with a type followed by a colon (e.g.
                    <code>fn:</code>) to restrict the search to a given type.
                </p>

                <p>
                    Accepted types are: <code>fn</code>, <code>mod</code>,
                    <code>struct</code>, <code>enum</code>,
                    <code>trait</code>, <code>type</code>, <code>macro</code>,
                    and <code>const</code>.
                </p>

                <p>
                    Search functions by type signature (e.g.
                    <code>vec -> usize</code> or <code>* -> vec</code>)
                </p>
            </div>
        </div>
    </aside>

    

    <script>
        window.rootPath = "../../";
        window.currentCrate = "ethcore";
    </script>
    <script src="../../jquery.js"></script>
    <script src="../../main.js"></script>
    <script defer src="../../search-index.js"></script>
</body>
</html>