difftastic/rustdoc/petgraph/graphmap/struct.GraphMap.html

258 lines
117 KiB
HTML

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!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="`GraphMap&lt;N, E, Ty&gt;` is a graph datastructure using an associative array of its node weights `N`."><title>GraphMap in petgraph::graphmap - Rust</title><link rel="preload" as="font" type="font/woff2" crossorigin href="../../static.files/SourceSerif4-Regular-46f98efaafac5295.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../static.files/FiraSans-Regular-018c141bf0843ffd.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../static.files/FiraSans-Medium-8f9a781e4970d388.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../static.files/SourceCodePro-Regular-562dcc5011b6de7d.ttf.woff2"><link rel="preload" as="font" type="font/woff2" crossorigin href="../../static.files/SourceCodePro-Semibold-d899c5a5c4aeb14a.ttf.woff2"><link rel="stylesheet" href="../../static.files/normalize-76eba96aa4d2e634.css"><link rel="stylesheet" href="../../static.files/rustdoc-ac92e1bbe349e143.css"><meta name="rustdoc-vars" data-root-path="../../" data-static-root-path="../../static.files/" data-current-crate="petgraph" data-themes="" data-resource-suffix="" data-rustdoc-version="1.76.0 (07dca489a 2024-02-04)" data-channel="1.76.0" data-search-js="search-2b6ce74ff89ae146.js" data-settings-js="settings-4313503d2e1961c2.js" ><script src="../../static.files/storage-f2adc0d6ca4d09fb.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../static.files/main-305769736d49e732.js"></script><noscript><link rel="stylesheet" href="../../static.files/noscript-feafe1bb7466e4bd.css"></noscript><link rel="alternate icon" type="image/png" href="../../static.files/favicon-16x16-8b506e7a72182f1c.png"><link rel="alternate icon" type="image/png" href="../../static.files/favicon-32x32-422f7d1d52889060.png"><link rel="icon" type="image/svg+xml" href="../../static.files/favicon-2c020d218678b618.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></nav><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../../petgraph/index.html">petgraph</a><span class="version">0.6.4</span></h2></div><h2 class="location"><a href="#">GraphMap</a></h2><div class="sidebar-elems"><section><h3><a href="#implementations">Methods</a></h3><ul class="block method"><li><a href="#method.add_edge">add_edge</a></li><li><a href="#method.add_node">add_node</a></li><li><a href="#method.all_edges">all_edges</a></li><li><a href="#method.all_edges_mut">all_edges_mut</a></li><li><a href="#method.capacity">capacity</a></li><li><a href="#method.clear">clear</a></li><li><a href="#method.contains_edge">contains_edge</a></li><li><a href="#method.contains_node">contains_node</a></li><li><a href="#method.edge_count">edge_count</a></li><li><a href="#method.edge_weight">edge_weight</a></li><li><a href="#method.edge_weight_mut">edge_weight_mut</a></li><li><a href="#method.edges">edges</a></li><li><a href="#method.edges_directed">edges_directed</a></li><li><a href="#method.from_edges">from_edges</a></li><li><a href="#method.from_graph">from_graph</a></li><li><a href="#method.into_graph">into_graph</a></li><li><a href="#method.is_directed">is_directed</a></li><li><a href="#method.neighbors">neighbors</a></li><li><a href="#method.neighbors_directed">neighbors_directed</a></li><li><a href="#method.new">new</a></li><li><a href="#method.node_count">node_count</a></li><li><a href="#method.nodes">nodes</a></li><li><a href="#method.remove_edge">remove_edge</a></li><li><a href="#method.remove_node">remove_node</a></li><li><a href="#method.with_capacity">with_capacity</a></li></ul><h3><a href="#trait-implementations">Trait Implementations</a></h3><ul class="block trait-implementation"><li><a href="#impl-Build-for-GraphMap%3CN,+E,+Ty%3E">Build</a></li><li><a href="#impl-Clone-for-GraphMap%3CN,+E,+Ty%3E">Clone</a></li><li><a href="#impl-Create-for-GraphMap%3CN,+E,+Ty%3E">Create</a></li><li><a href="#impl-Data-for-GraphMap%3CN,+E,+Ty%3E">Data</a></li><li><a href="#impl-Debug-for-GraphMap%3CN,+E,+Ty%3E">Debug</a></li><li><a href="#impl-Default-for-GraphMap%3CN,+E,+Ty%3E">Default</a></li><li><a href="#impl-EdgeCount-for-GraphMap%3CN,+E,+Ty%3E">EdgeCount</a></li><li><a href="#impl-EdgeIndexable-for-GraphMap%3CN,+E,+Ty%3E">EdgeIndexable</a></li><li><a href="#impl-Extend%3CItem%3E-for-GraphMap%3CN,+E,+Ty%3E">Extend&lt;Item&gt;</a></li><li><a href="#impl-FromElements-for-GraphMap%3CN,+E,+Ty%3E">FromElements</a></li><li><a href="#impl-FromIterator%3CItem%3E-for-GraphMap%3CN,+E,+Ty%3E">FromIterator&lt;Item&gt;</a></li><li><a href="#impl-GetAdjacencyMatrix-for-GraphMap%3CN,+E,+Ty%3E">GetAdjacencyMatrix</a></li><li><a href="#impl-GraphBase-for-GraphMap%3CN,+E,+Ty%3E">GraphBase</a></li><li><a href="#impl-GraphProp-for-GraphMap%3CN,+E,+Ty%3E">GraphProp</a></li><li><a href="#impl-Index%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty%3E">Index&lt;(N, N)&gt;</a></li><li><a href="#impl-IndexMut%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty%3E">IndexMut&lt;(N, N)&gt;</a></li><li><a href="#impl-IntoEdgeReferences-for-%26GraphMap%3CN,+E,+Ty%3E">IntoEdgeReferences</a></li><li><a href="#impl-IntoEdges-for-%26GraphMap%3CN,+E,+Ty%3E">IntoEdges</a></li><li><a href="#impl-IntoEdgesDirected-for-%26GraphMap%3CN,+E,+Ty%3E">IntoEdgesDirected</a></li><li><a href="#impl-IntoNeighbors-for-%26GraphMap%3CN,+E,+Ty%3E">IntoNeighbors</a></li><li><a href="#impl-IntoNeighborsDirected-for-%26GraphMap%3CN,+E,+Ty%3E">IntoNeighborsDirected</a></li><li><a href="#impl-IntoNodeIdentifiers-for-%26GraphMap%3CN,+E,+Ty%3E">IntoNodeIdentifiers</a></li><li><a href="#impl-IntoNodeReferences-for-%26GraphMap%3CN,+E,+Ty%3E">IntoNodeReferences</a></li><li><a href="#impl-NodeCompactIndexable-for-GraphMap%3CN,+E,+Ty%3E">NodeCompactIndexable</a></li><li><a href="#impl-NodeCount-for-GraphMap%3CN,+E,+Ty%3E">NodeCount</a></li><li><a href="#impl-NodeIndexable-for-GraphMap%3CN,+E,+Ty%3E">NodeIndexable</a></li><li><a href="#impl-Visitable-for-GraphMap%3CN,+E,+Ty%3E">Visitable</a></li></ul><h3><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul class="block synthetic-implementation"><li><a href="#impl-RefUnwindSafe-for-GraphMap%3CN,+E,+Ty%3E">RefUnwindSafe</a></li><li><a href="#impl-Send-for-GraphMap%3CN,+E,+Ty%3E">Send</a></li><li><a href="#impl-Sync-for-GraphMap%3CN,+E,+Ty%3E">Sync</a></li><li><a href="#impl-Unpin-for-GraphMap%3CN,+E,+Ty%3E">Unpin</a></li><li><a href="#impl-UnwindSafe-for-GraphMap%3CN,+E,+Ty%3E">UnwindSafe</a></li></ul><h3><a href="#blanket-implementations">Blanket Implementations</a></h3><ul class="block blanket-implementation"><li><a href="#impl-Any-for-T">Any</a></li><li><a href="#impl-Borrow%3CT%3E-for-T">Borrow&lt;T&gt;</a></li><li><a href="#impl-BorrowMut%3CT%3E-for-T">BorrowMut&lt;T&gt;</a></li><li><a href="#impl-From%3CT%3E-for-T">From&lt;T&gt;</a></li><li><a href="#impl-Into%3CU%3E-for-T">Into&lt;U&gt;</a></li><li><a href="#impl-ToOwned-for-T">ToOwned</a></li><li><a href="#impl-TryFrom%3CU%3E-for-T">TryFrom&lt;U&gt;</a></li><li><a href="#impl-TryInto%3CU%3E-for-T">TryInto&lt;U&gt;</a></li></ul></section><h2><a href="index.html">In petgraph::graphmap</a></h2></div></nav><div class="sidebar-resizer"></div>
<main><div class="width-limiter"><nav class="sub"><form class="search-form"><span></span><div id="sidebar-button" tabindex="-1"><a href="../../petgraph/all.html" title="show sidebar"></a></div><input class="search-input" name="search" aria-label="Run search in the documentation" autocomplete="off" spellcheck="false" placeholder="Click or press S to search, ? for more options…" type="search"><div id="help-button" tabindex="-1"><a href="../../help.html" title="help">?</a></div><div id="settings-menu" tabindex="-1"><a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../static.files/wheel-7b819b6101059cd0.svg"></a></div></form></nav><section id="main-content" class="content"><div class="main-heading"><h1>Struct <a href="../index.html">petgraph</a>::<wbr><a href="index.html">graphmap</a>::<wbr><a class="struct" href="#">GraphMap</a><button id="copy-path" title="Copy item path to clipboard"><img src="../../static.files/clipboard-7571035ce49a181d.svg" width="19" height="18" alt="Copy item path"></button></h1><span class="out-of-band"><a class="src" href="../../src/petgraph/graphmap.rs.html#61-65">source</a> · <button id="toggle-all-docs" title="collapse all docs">[<span>&#x2212;</span>]</button></span></div><pre class="rust item-decl"><code>pub struct GraphMap&lt;N, E, Ty&gt; { <span class="comment">/* private fields */</span> }</code></pre><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p><code>GraphMap&lt;N, E, Ty&gt;</code> is a graph datastructure using an associative array
of its node weights <code>N</code>.</p>
<p>It uses an combined adjacency list and sparse adjacency matrix
representation, using <strong>O(|V| + |E|)</strong> space, and allows testing for edge
existence in constant time.</p>
<p><code>GraphMap</code> is parameterized over:</p>
<ul>
<li>Associated data <code>N</code> for nodes and <code>E</code> for edges, called <em>weights</em>.</li>
<li>The node weight <code>N</code> must implement <code>Copy</code> and will be used as node
identifier, duplicated into several places in the data structure.
It must be suitable as a hash table key (implementing <code>Eq + Hash</code>).
The node type must also implement <code>Ord</code> so that the implementation can
order the pair (<code>a</code>, <code>b</code>) for an edge connecting any two nodes <code>a</code> and <code>b</code>.</li>
<li><code>E</code> can be of arbitrary type.</li>
<li>Edge type <code>Ty</code> that determines whether the graph edges are directed or
undirected.</li>
</ul>
<p>You can use the type aliases <code>UnGraphMap</code> and <code>DiGraphMap</code> for convenience.</p>
<p><code>GraphMap</code> does not allow parallel edges, but self loops are allowed.</p>
<p>Depends on crate feature <code>graphmap</code> (default).</p>
</div></details><h2 id="implementations" class="section-header">Implementations<a href="#implementations" class="anchor">§</a></h2><div id="implementations-list"><details class="toggle implementors-toggle" open><summary><section id="impl-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#164-556">source</a><a href="#impl-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.new" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#170-172">source</a><h4 class="code-header">pub fn <a href="#method.new" class="fn">new</a>() -&gt; Self</h4></section></summary><div class="docblock"><p>Create a new <code>GraphMap</code></p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.with_capacity" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#175-181">source</a><h4 class="code-header">pub fn <a href="#method.with_capacity" class="fn">with_capacity</a>(nodes: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>, edges: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>) -&gt; Self</h4></section></summary><div class="docblock"><p>Create a new <code>GraphMap</code> with estimated capacity.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.capacity" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#184-186">source</a><h4 class="code-header">pub fn <a href="#method.capacity" class="fn">capacity</a>(&amp;self) -&gt; (<a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>, <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>)</h4></section></summary><div class="docblock"><p>Return the current node and edge capacity of the graph.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.is_directed" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#199-201">source</a><h4 class="code-header">pub fn <a href="#method.is_directed" class="fn">is_directed</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Whether the graph has directed edges.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.from_edges" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#222-228">source</a><h4 class="code-header">pub fn <a href="#method.from_edges" class="fn">from_edges</a>&lt;I&gt;(iterable: I) -&gt; Self<div class="where">where
I: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a>,
I::<a class="associatedtype" href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.IntoIterator.html#associatedtype.Item" title="type core::iter::traits::collect::IntoIterator::Item">Item</a>: <a class="trait" href="../trait.IntoWeightedEdge.html" title="trait petgraph::IntoWeightedEdge">IntoWeightedEdge</a>&lt;E, NodeId = N&gt;,</div></h4></section></summary><div class="docblock"><p>Create a new <code>GraphMap</code> from an iterable of edges.</p>
<p>Node values are taken directly from the list.
Edge weights <code>E</code> may either be specified in the list,
or they are filled with default values.</p>
<p>Nodes are inserted automatically to match the edges.</p>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use </span>petgraph::graphmap::UnGraphMap;
<span class="comment">// Create a new undirected GraphMap.
// Use a type hint to have `()` be the edge weight type.
</span><span class="kw">let </span>gr = UnGraphMap::&lt;<span class="kw">_</span>, ()&gt;::from_edges(<span class="kw-2">&amp;</span>[
(<span class="number">0</span>, <span class="number">1</span>), (<span class="number">0</span>, <span class="number">2</span>), (<span class="number">0</span>, <span class="number">3</span>),
(<span class="number">1</span>, <span class="number">2</span>), (<span class="number">1</span>, <span class="number">3</span>),
(<span class="number">2</span>, <span class="number">3</span>),
]);</code></pre></div>
</div></details><details class="toggle method-toggle" open><summary><section id="method.node_count" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#231-233">source</a><h4 class="code-header">pub fn <a href="#method.node_count" class="fn">node_count</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a></h4></section></summary><div class="docblock"><p>Return the number of nodes in the graph.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.edge_count" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#236-238">source</a><h4 class="code-header">pub fn <a href="#method.edge_count" class="fn">edge_count</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a></h4></section></summary><div class="docblock"><p>Return the number of edges in the graph.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.clear" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#241-244">source</a><h4 class="code-header">pub fn <a href="#method.clear" class="fn">clear</a>(&amp;mut self)</h4></section></summary><div class="docblock"><p>Remove all nodes and edges</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.add_node" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#247-250">source</a><h4 class="code-header">pub fn <a href="#method.add_node" class="fn">add_node</a>(&amp;mut self, n: N) -&gt; N</h4></section></summary><div class="docblock"><p>Add node <code>n</code> to the graph.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.remove_node" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#255-272">source</a><h4 class="code-header">pub fn <a href="#method.remove_node" class="fn">remove_node</a>(&amp;mut self, n: N) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Return <code>true</code> if node <code>n</code> was removed.</p>
<p>Computes in <strong>O(V)</strong> time, due to the removal of edges with other nodes.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.contains_node" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#275-277">source</a><h4 class="code-header">pub fn <a href="#method.contains_node" class="fn">contains_node</a>(&amp;self, n: N) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Return <code>true</code> if the node is contained in the graph.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.add_edge" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#300-318">source</a><h4 class="code-header">pub fn <a href="#method.add_edge" class="fn">add_edge</a>(&amp;mut self, a: N, b: N, weight: E) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.76.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;E&gt;</h4></section></summary><div class="docblock"><p>Add an edge connecting <code>a</code> and <code>b</code> to the graph, with associated
data <code>weight</code>. For a directed graph, the edge is directed from <code>a</code>
to <code>b</code>.</p>
<p>Inserts nodes <code>a</code> and/or <code>b</code> if they arent already part of the graph.</p>
<p>Return <code>None</code> if the edge did not previously exist, otherwise,
the associated data is updated and the old value is returned
as <code>Some(old_weight)</code>.</p>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="comment">// Create a GraphMap with directed edges, and add one edge to it
</span><span class="kw">use </span>petgraph::graphmap::DiGraphMap;
<span class="kw">let </span><span class="kw-2">mut </span>g = DiGraphMap::new();
g.add_edge(<span class="string">"x"</span>, <span class="string">"y"</span>, -<span class="number">1</span>);
<span class="macro">assert_eq!</span>(g.node_count(), <span class="number">2</span>);
<span class="macro">assert_eq!</span>(g.edge_count(), <span class="number">1</span>);
<span class="macro">assert!</span>(g.contains_edge(<span class="string">"x"</span>, <span class="string">"y"</span>));
<span class="macro">assert!</span>(!g.contains_edge(<span class="string">"y"</span>, <span class="string">"x"</span>));</code></pre></div>
</div></details><details class="toggle method-toggle" open><summary><section id="method.remove_edge" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#363-373">source</a><h4 class="code-header">pub fn <a href="#method.remove_edge" class="fn">remove_edge</a>(&amp;mut self, a: N, b: N) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.76.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;E&gt;</h4></section></summary><div class="docblock"><p>Remove edge from <code>a</code> to <code>b</code> from the graph and return the edge weight.</p>
<p>Return <code>None</code> if the edge didnt exist.</p>
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="comment">// Create a GraphMap with undirected edges, and add and remove an edge.
</span><span class="kw">use </span>petgraph::graphmap::UnGraphMap;
<span class="kw">let </span><span class="kw-2">mut </span>g = UnGraphMap::new();
g.add_edge(<span class="string">"x"</span>, <span class="string">"y"</span>, -<span class="number">1</span>);
<span class="kw">let </span>edge_data = g.remove_edge(<span class="string">"y"</span>, <span class="string">"x"</span>);
<span class="macro">assert_eq!</span>(edge_data, <span class="prelude-val">Some</span>(-<span class="number">1</span>));
<span class="macro">assert_eq!</span>(g.edge_count(), <span class="number">0</span>);</code></pre></div>
</div></details><details class="toggle method-toggle" open><summary><section id="method.contains_edge" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#376-378">source</a><h4 class="code-header">pub fn <a href="#method.contains_edge" class="fn">contains_edge</a>(&amp;self, a: N, b: N) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.bool.html">bool</a></h4></section></summary><div class="docblock"><p>Return <code>true</code> if the edge connecting <code>a</code> with <code>b</code> is contained in the graph.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.nodes" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#383-387">source</a><h4 class="code-header">pub fn <a href="#method.nodes" class="fn">nodes</a>(&amp;self) -&gt; <a class="struct" href="struct.Nodes.html" title="struct petgraph::graphmap::Nodes">Nodes</a>&lt;'_, N&gt; <a href="#" class="tooltip" data-notable-ty="Nodes&lt;&#39;_, N&gt;"></a></h4></section></summary><div class="docblock"><p>Return an iterator over the nodes of the graph.</p>
<p>Iterator element type is <code>N</code>.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.neighbors" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#396-404">source</a><h4 class="code-header">pub fn <a href="#method.neighbors" class="fn">neighbors</a>(&amp;self, a: N) -&gt; <a class="struct" href="struct.Neighbors.html" title="struct petgraph::graphmap::Neighbors">Neighbors</a>&lt;'_, N, Ty&gt; <a href="#" class="tooltip" data-notable-ty="Neighbors&lt;&#39;_, N, Ty&gt;"></a></h4></section></summary><div class="docblock"><p>Return an iterator of all nodes with an edge starting from <code>a</code>.</p>
<ul>
<li><code>Directed</code>: Outgoing edges from <code>a</code>.</li>
<li><code>Undirected</code>: All edges from or to <code>a</code>.</li>
</ul>
<p>Produces an empty iterator if the node doesnt exist.<br>
Iterator element type is <code>N</code>.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.neighbors_directed" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#416-426">source</a><h4 class="code-header">pub fn <a href="#method.neighbors_directed" class="fn">neighbors_directed</a>(
&amp;self,
a: N,
dir: <a class="enum" href="../enum.Direction.html" title="enum petgraph::Direction">Direction</a>
) -&gt; <a class="struct" href="struct.NeighborsDirected.html" title="struct petgraph::graphmap::NeighborsDirected">NeighborsDirected</a>&lt;'_, N, Ty&gt; <a href="#" class="tooltip" data-notable-ty="NeighborsDirected&lt;&#39;_, N, Ty&gt;"></a></h4></section></summary><div class="docblock"><p>Return an iterator of all neighbors that have an edge between them and
<code>a</code>, in the specified direction.
If the graphs edges are undirected, this is equivalent to <em>.neighbors(a)</em>.</p>
<ul>
<li><code>Directed</code>, <code>Outgoing</code>: All edges from <code>a</code>.</li>
<li><code>Directed</code>, <code>Incoming</code>: All edges to <code>a</code>.</li>
<li><code>Undirected</code>: All edges from or to <code>a</code>.</li>
</ul>
<p>Produces an empty iterator if the node doesnt exist.<br>
Iterator element type is <code>N</code>.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.edges" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#436-442">source</a><h4 class="code-header">pub fn <a href="#method.edges" class="fn">edges</a>(&amp;self, a: N) -&gt; <a class="struct" href="struct.Edges.html" title="struct petgraph::graphmap::Edges">Edges</a>&lt;'_, N, E, Ty&gt; <a href="#" class="tooltip" data-notable-ty="Edges&lt;&#39;_, N, E, Ty&gt;"></a></h4></section></summary><div class="docblock"><p>Return an iterator of target nodes with an edge starting from <code>a</code>,
paired with their respective edge weights.</p>
<ul>
<li><code>Directed</code>: Outgoing edges from <code>a</code>.</li>
<li><code>Undirected</code>: All edges from or to <code>a</code>.</li>
</ul>
<p>Produces an empty iterator if the node doesnt exist.<br>
Iterator element type is <code>(N, N, &amp;E)</code>.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.edges_directed" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#456-463">source</a><h4 class="code-header">pub fn <a href="#method.edges_directed" class="fn">edges_directed</a>(
&amp;self,
a: N,
dir: <a class="enum" href="../enum.Direction.html" title="enum petgraph::Direction">Direction</a>
) -&gt; <a class="struct" href="struct.EdgesDirected.html" title="struct petgraph::graphmap::EdgesDirected">EdgesDirected</a>&lt;'_, N, E, Ty&gt; <a href="#" class="tooltip" data-notable-ty="EdgesDirected&lt;&#39;_, N, E, Ty&gt;"></a></h4></section></summary><div class="docblock"><p>Return an iterator of target nodes with an edge starting from <code>a</code>,
paired with their respective edge weights.</p>
<ul>
<li><code>Directed</code>, <code>Outgoing</code>: All edges from <code>a</code>.</li>
<li><code>Directed</code>, <code>Incoming</code>: All edges to <code>a</code>.</li>
<li><code>Undirected</code>, <code>Outgoing</code>: All edges connected to <code>a</code>, with <code>a</code> being the source of each
edge.</li>
<li><code>Undirected</code>, <code>Incoming</code>: All edges connected to <code>a</code>, with <code>a</code> being the target of each
edge.</li>
</ul>
<p>Produces an empty iterator if the node doesnt exist.<br>
Iterator element type is <code>(N, N, &amp;E)</code>.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.edge_weight" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#467-469">source</a><h4 class="code-header">pub fn <a href="#method.edge_weight" class="fn">edge_weight</a>(&amp;self, a: N, b: N) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.76.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;E</a>&gt;</h4></section></summary><div class="docblock"><p>Return a reference to the edge weight connecting <code>a</code> with <code>b</code>, or
<code>None</code> if the edge does not exist in the graph.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.edge_weight_mut" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#473-475">source</a><h4 class="code-header">pub fn <a href="#method.edge_weight_mut" class="fn">edge_weight_mut</a>(&amp;mut self, a: N, b: N) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.76.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;mut E</a>&gt;</h4></section></summary><div class="docblock"><p>Return a mutable reference to the edge weight connecting <code>a</code> with <code>b</code>, or
<code>None</code> if the edge does not exist in the graph.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.all_edges" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#480-485">source</a><h4 class="code-header">pub fn <a href="#method.all_edges" class="fn">all_edges</a>(&amp;self) -&gt; <a class="struct" href="struct.AllEdges.html" title="struct petgraph::graphmap::AllEdges">AllEdges</a>&lt;'_, N, E, Ty&gt; <a href="#" class="tooltip" data-notable-ty="AllEdges&lt;&#39;_, N, E, Ty&gt;"></a></h4></section></summary><div class="docblock"><p>Return an iterator over all edges of the graph with their weight in arbitrary order.</p>
<p>Iterator element type is <code>(N, N, &amp;E)</code></p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.all_edges_mut" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#491-496">source</a><h4 class="code-header">pub fn <a href="#method.all_edges_mut" class="fn">all_edges_mut</a>(&amp;mut self) -&gt; <a class="struct" href="struct.AllEdgesMut.html" title="struct petgraph::graphmap::AllEdgesMut">AllEdgesMut</a>&lt;'_, N, E, Ty&gt; <a href="#" class="tooltip" data-notable-ty="AllEdgesMut&lt;&#39;_, N, E, Ty&gt;"></a></h4></section></summary><div class="docblock"><p>Return an iterator over all edges of the graph in arbitrary order, with a mutable reference
to their weight.</p>
<p>Iterator element type is <code>(N, N, &amp;mut E)</code></p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.into_graph" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#509-524">source</a><h4 class="code-header">pub fn <a href="#method.into_graph" class="fn">into_graph</a>&lt;Ix&gt;(self) -&gt; <a class="struct" href="../graph/struct.Graph.html" title="struct petgraph::graph::Graph">Graph</a>&lt;N, E, Ty, Ix&gt;<div class="where">where
Ix: <a class="trait" href="../graph/trait.IndexType.html" title="trait petgraph::graph::IndexType">IndexType</a>,</div></h4></section></summary><div class="docblock"><p>Return a <code>Graph</code> that corresponds to this <code>GraphMap</code>.</p>
<ol>
<li>Note that node and edge indices in the <code>Graph</code> have nothing in common
with the <code>GraphMap</code>s node weights <code>N</code>. The node weights <code>N</code> are used as
node weights in the resulting <code>Graph</code>, too.</li>
<li>Note that the index type is user-chosen.</li>
</ol>
<p>Computes in <strong>O(|V| + |E|)</strong> time (average).</p>
<p><strong>Panics</strong> if the number of nodes or edges does not fit with
the resulting graphs index type.</p>
</div></details><details class="toggle method-toggle" open><summary><section id="method.from_graph" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#533-555">source</a><h4 class="code-header">pub fn <a href="#method.from_graph" class="fn">from_graph</a>&lt;Ix&gt;(graph: <a class="struct" href="../graph/struct.Graph.html" title="struct petgraph::graph::Graph">Graph</a>&lt;N, E, Ty, Ix&gt;) -&gt; Self<div class="where">where
Ix: <a class="trait" href="../graph/trait.IndexType.html" title="trait petgraph::graph::IndexType">IndexType</a>,
E: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,</div></h4></section></summary><div class="docblock"><p>Creates a <code>GraphMap</code> that corresponds to the given <code>Graph</code>.</p>
<p><strong>Warning</strong>: Nodes with the same weight are merged and only the last parallel edge
is kept. Node and edge indices of the <code>Graph</code> are lost. Only use this function
if the node weights are distinct and there are no parallel edges.</p>
<p>Computes in <strong>O(|V| + |E|)</strong> time (average).</p>
</div></details></div></details></div><h2 id="trait-implementations" class="section-header">Trait Implementations<a href="#trait-implementations" class="anchor">§</a></h2><div id="trait-implementations-list"><details class="toggle implementors-toggle" open><summary><section id="impl-Build-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/data.rs.html#189-220">source</a><a href="#impl-Build-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../data/trait.Build.html" title="trait petgraph::data::Build">Build</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,</div></h3></section></summary><div class="impl-items"><section id="method.add_node-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/data.rs.html#194-196">source</a><a href="#method.add_node-1" class="anchor">§</a><h4 class="code-header">fn <a href="../data/trait.Build.html#tymethod.add_node" class="fn">add_node</a>(&amp;mut self, weight: Self::<a class="associatedtype" href="../visit/trait.Data.html#associatedtype.NodeWeight" title="type petgraph::visit::Data::NodeWeight">NodeWeight</a>) -&gt; Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a></h4></section><details class="toggle method-toggle" open><summary><section id="method.add_edge-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/data.rs.html#197-210">source</a><a href="#method.add_edge-1" class="anchor">§</a><h4 class="code-header">fn <a href="../data/trait.Build.html#method.add_edge" class="fn">add_edge</a>(
&amp;mut self,
a: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>,
b: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>,
weight: Self::<a class="associatedtype" href="../visit/trait.Data.html#associatedtype.EdgeWeight" title="type petgraph::visit::Data::EdgeWeight">EdgeWeight</a>
) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.76.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.EdgeId" title="type petgraph::visit::GraphBase::EdgeId">EdgeId</a>&gt;</h4></section></summary><div class='docblock'>Add a new edge. If parallel edges (duplicate) are not allowed and
the edge already exists, return <code>None</code>.</div></details><details class="toggle method-toggle" open><summary><section id="method.update_edge" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/data.rs.html#211-219">source</a><a href="#method.update_edge" class="anchor">§</a><h4 class="code-header">fn <a href="../data/trait.Build.html#tymethod.update_edge" class="fn">update_edge</a>(
&amp;mut self,
a: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>,
b: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>,
weight: Self::<a class="associatedtype" href="../visit/trait.Data.html#associatedtype.EdgeWeight" title="type petgraph::visit::Data::EdgeWeight">EdgeWeight</a>
) -&gt; Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.EdgeId" title="type petgraph::visit::GraphBase::EdgeId">EdgeId</a></h4></section></summary><div class='docblock'>Add or update the edge from <code>a</code> to <code>b</code>. Return the id of the affected
edge.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Clone-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#60">source</a><a href="#impl-Clone-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>, E: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>, Ty: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.clone" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#60">source</a><a href="#method.clone" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html#tymethod.clone" class="fn">clone</a>(&amp;self) -&gt; <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;</h4></section></summary><div class='docblock'>Returns a copy of the value. <a href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html#tymethod.clone">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.clone_from" class="method trait-impl"><span class="rightside"><span class="since" title="Stable since Rust version 1.0.0">1.0.0</span> · <a class="src" href="https://doc.rust-lang.org/1.76.0/src/core/clone.rs.html#169">source</a></span><a href="#method.clone_from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html#method.clone_from" class="fn">clone_from</a>(&amp;mut self, source: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;Self</a>)</h4></section></summary><div class='docblock'>Performs copy-assignment from <code>source</code>. <a href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html#method.clone_from">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Create-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/data.rs.html#244-252">source</a><a href="#impl-Create-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../data/trait.Create.html" title="trait petgraph::data::Create">Create</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,</div></h3></section></summary><div class="impl-items"><section id="method.with_capacity-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/data.rs.html#249-251">source</a><a href="#method.with_capacity-1" class="anchor">§</a><h4 class="code-header">fn <a href="../data/trait.Create.html#tymethod.with_capacity" class="fn">with_capacity</a>(nodes: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>, edges: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>) -&gt; Self</h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Data-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1025-1032">source</a><a href="#impl-Data-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.Data.html" title="trait petgraph::visit::Data">Data</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/cmp/trait.PartialEq.html" title="trait core::cmp::PartialEq">PartialEq</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.NodeWeight" class="associatedtype trait-impl"><a href="#associatedtype.NodeWeight" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.Data.html#associatedtype.NodeWeight" class="associatedtype">NodeWeight</a> = N</h4></section><section id="associatedtype.EdgeWeight" class="associatedtype trait-impl"><a href="#associatedtype.EdgeWeight" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.Data.html#associatedtype.EdgeWeight" class="associatedtype">EdgeWeight</a> = E</h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Debug-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#67-71">source</a><a href="#impl-Debug-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/cmp/trait.Eq.html" title="trait core::cmp::Eq">Eq</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/hash/trait.Hash.html" title="trait core::hash::Hash">Hash</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a>, E: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a>, Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.fmt" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#68-70">source</a><a href="#method.fmt" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/fmt/trait.Debug.html#tymethod.fmt" class="fn">fmt</a>(&amp;self, f: &amp;mut <a class="struct" href="https://doc.rust-lang.org/1.76.0/core/fmt/struct.Formatter.html" title="struct core::fmt::Formatter">Formatter</a>&lt;'_&gt;) -&gt; <a class="type" href="https://doc.rust-lang.org/1.76.0/core/fmt/type.Result.html" title="type core::fmt::Result">Result</a></h4></section></summary><div class='docblock'>Formats the value using the given formatter. <a href="https://doc.rust-lang.org/1.76.0/core/fmt/trait.Debug.html#tymethod.fmt">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Default-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#894-902">source</a><a href="#impl-Default-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/default/trait.Default.html" title="trait core::default::Default">Default</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="docblock"><p>Create a new empty <code>GraphMap</code>.</p>
</div><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.default" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#899-901">source</a><a href="#method.default" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/default/trait.Default.html#tymethod.default" class="fn">default</a>() -&gt; Self</h4></section></summary><div class='docblock'>Returns the “default value” for a type. <a href="https://doc.rust-lang.org/1.76.0/core/default/trait.Default.html#tymethod.default">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-EdgeCount-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1209-1218">source</a><a href="#impl-EdgeCount-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.EdgeCount.html" title="trait petgraph::visit::EdgeCount">EdgeCount</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.edge_count-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1215-1217">source</a><a href="#method.edge_count-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.EdgeCount.html#tymethod.edge_count" class="fn">edge_count</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a></h4></section></summary><div class='docblock'>Return the number of edges in the graph.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-EdgeIndexable-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1150-1173">source</a><a href="#impl-EdgeIndexable-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.EdgeIndexable.html" title="trait petgraph::visit::EdgeIndexable">EdgeIndexable</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.edge_bound" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1155-1157">source</a><a href="#method.edge_bound" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.EdgeIndexable.html#tymethod.edge_bound" class="fn">edge_bound</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a></h4></section></summary><div class='docblock'>Return an upper bound of the edge indices in the graph
(suitable for the size of a bitmap).</div></details><details class="toggle method-toggle" open><summary><section id="method.to_index-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1159-1162">source</a><a href="#method.to_index-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.EdgeIndexable.html#tymethod.to_index" class="fn">to_index</a>(&amp;self, ix: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.EdgeId" title="type petgraph::visit::GraphBase::EdgeId">EdgeId</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a></h4></section></summary><div class='docblock'>Convert <code>a</code> to an integer index.</div></details><details class="toggle method-toggle" open><summary><section id="method.from_index-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1164-1172">source</a><a href="#method.from_index-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.EdgeIndexable.html#tymethod.from_index" class="fn">from_index</a>(&amp;self, ix: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>) -&gt; Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.EdgeId" title="type petgraph::visit::GraphBase::EdgeId">EdgeId</a></h4></section></summary><div class='docblock'>Convert <code>i</code> to an edge index. <code>i</code> must be a valid value in the graph.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Extend%3CItem%3E-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#580-599">source</a><a href="#impl-Extend%3CItem%3E-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty, Item&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.Extend.html" title="trait core::iter::traits::collect::Extend">Extend</a>&lt;Item&gt; for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
Item: <a class="trait" href="../trait.IntoWeightedEdge.html" title="trait petgraph::IntoWeightedEdge">IntoWeightedEdge</a>&lt;E, NodeId = N&gt;,
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="docblock"><p>Extend the graph from an iterable of edges.</p>
<p>Nodes are inserted automatically to match the edges.</p>
</div><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.extend" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#586-598">source</a><a href="#method.extend" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.Extend.html#tymethod.extend" class="fn">extend</a>&lt;I&gt;(&amp;mut self, iterable: I)<div class="where">where
I: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a>&lt;Item = Item&gt;,</div></h4></section></summary><div class='docblock'>Extends a collection with the contents of an iterator. <a href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.Extend.html#tymethod.extend">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.extend_one" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/iter/traits/collect.rs.html#376">source</a><a href="#method.extend_one" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.Extend.html#method.extend_one" class="fn">extend_one</a>(&amp;mut self, item: A)</h4></section></summary><span class="item-info"><div class="stab unstable"><span class="emoji">🔬</span><span>This is a nightly-only experimental API. (<code>extend_one</code>)</span></div></span><div class='docblock'>Extends a collection with exactly one element.</div></details><details class="toggle method-toggle" open><summary><section id="method.extend_reserve" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/iter/traits/collect.rs.html#384">source</a><a href="#method.extend_reserve" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.Extend.html#method.extend_reserve" class="fn">extend_reserve</a>(&amp;mut self, additional: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>)</h4></section></summary><span class="item-info"><div class="stab unstable"><span class="emoji">🔬</span><span>This is a nightly-only experimental API. (<code>extend_one</code>)</span></div></span><div class='docblock'>Reserves capacity in a collection for the given number of additional elements. <a href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.Extend.html#method.extend_reserve">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-FromElements-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/data.rs.html#355-367">source</a><a href="#impl-FromElements-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../data/trait.FromElements.html" title="trait petgraph::data::FromElements">FromElements</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,</div></h3></section></summary><div class="impl-items"><section id="method.from_elements" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/data.rs.html#360-366">source</a><a href="#method.from_elements" class="anchor">§</a><h4 class="code-header">fn <a href="../data/trait.FromElements.html#method.from_elements" class="fn">from_elements</a>&lt;I&gt;(iterable: I) -&gt; Self<div class="where">where
Self: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,
I: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a>&lt;Item = <a class="enum" href="../data/enum.Element.html" title="enum petgraph::data::Element">Element</a>&lt;Self::<a class="associatedtype" href="../visit/trait.Data.html#associatedtype.NodeWeight" title="type petgraph::visit::Data::NodeWeight">NodeWeight</a>, Self::<a class="associatedtype" href="../visit/trait.Data.html#associatedtype.EdgeWeight" title="type petgraph::visit::Data::EdgeWeight">EdgeWeight</a>&gt;&gt;,</div></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-FromIterator%3CItem%3E-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#559-575">source</a><a href="#impl-FromIterator%3CItem%3E-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty, Item&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.FromIterator.html" title="trait core::iter::traits::collect::FromIterator">FromIterator</a>&lt;Item&gt; for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
Item: <a class="trait" href="../trait.IntoWeightedEdge.html" title="trait petgraph::IntoWeightedEdge">IntoWeightedEdge</a>&lt;E, NodeId = N&gt;,
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="docblock"><p>Create a new <code>GraphMap</code> from an iterable of edges.</p>
</div><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from_iter" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#565-574">source</a><a href="#method.from_iter" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.FromIterator.html#tymethod.from_iter" class="fn">from_iter</a>&lt;I&gt;(iterable: I) -&gt; Self<div class="where">where
I: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a>&lt;Item = Item&gt;,</div></h4></section></summary><div class='docblock'>Creates a value from an iterator. <a href="https://doc.rust-lang.org/1.76.0/core/iter/traits/collect/trait.FromIterator.html#tymethod.from_iter">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-GetAdjacencyMatrix-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1221-1233">source</a><a href="#impl-GetAdjacencyMatrix-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.GetAdjacencyMatrix.html" title="trait petgraph::visit::GetAdjacencyMatrix">GetAdjacencyMatrix</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/hash/trait.Hash.html" title="trait core::hash::Hash">Hash</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="docblock"><p>The <code>GraphMap</code> keeps an adjacency matrix internally.</p>
</div><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.AdjMatrix" class="associatedtype trait-impl"><a href="#associatedtype.AdjMatrix" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.GetAdjacencyMatrix.html#associatedtype.AdjMatrix" class="associatedtype">AdjMatrix</a> = <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.unit.html">()</a></h4></section></summary><div class='docblock'>The associated adjacency matrix type</div></details><details class="toggle method-toggle" open><summary><section id="method.adjacency_matrix" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1228">source</a><a href="#method.adjacency_matrix" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.GetAdjacencyMatrix.html#tymethod.adjacency_matrix" class="fn">adjacency_matrix</a>(&amp;self)</h4></section></summary><div class='docblock'>Create the adjacency matrix</div></details><details class="toggle method-toggle" open><summary><section id="method.is_adjacent" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1230-1232">source</a><a href="#method.is_adjacent" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.GetAdjacencyMatrix.html#tymethod.is_adjacent" class="fn">is_adjacent</a>(&amp;self, _: &amp;<a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.unit.html">()</a>, a: N, b: N) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.bool.html">bool</a></h4></section></summary><div class='docblock'>Return true if there is an edge from <code>a</code> to <code>b</code>, false otherwise. <a href="../visit/trait.GetAdjacencyMatrix.html#tymethod.is_adjacent">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-GraphBase-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1017-1023">source</a><a href="#impl-GraphBase-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.GraphBase.html" title="trait petgraph::visit::GraphBase">GraphBase</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/cmp/trait.PartialEq.html" title="trait core::cmp::PartialEq">PartialEq</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.NodeId" class="associatedtype trait-impl"><a href="#associatedtype.NodeId" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.GraphBase.html#associatedtype.NodeId" class="associatedtype">NodeId</a> = N</h4></section></summary><div class='docblock'>node identifier</div></details><details class="toggle" open><summary><section id="associatedtype.EdgeId" class="associatedtype trait-impl"><a href="#associatedtype.EdgeId" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.GraphBase.html#associatedtype.EdgeId" class="associatedtype">EdgeId</a> = <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.tuple.html">(N, N)</a></h4></section></summary><div class='docblock'>edge identifier</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-GraphProp-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1048-1054">source</a><a href="#impl-GraphProp-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.GraphProp.html" title="trait petgraph::visit::GraphProp">GraphProp</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.EdgeType" class="associatedtype trait-impl"><a href="#associatedtype.EdgeType" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.GraphProp.html#associatedtype.EdgeType" class="associatedtype">EdgeType</a> = Ty</h4></section></summary><div class='docblock'>The kind of edges in the graph.</div></details><section id="method.is_directed-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/visit/mod.rs.html#329-331">source</a><a href="#method.is_directed-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.GraphProp.html#method.is_directed" class="fn">is_directed</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.bool.html">bool</a></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Index%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#867-878">source</a><a href="#impl-Index%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/ops/index/trait.Index.html" title="trait core::ops::index::Index">Index</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.tuple.html">(N, N)</a>&gt; for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="docblock"><p>Index <code>GraphMap</code> by node pairs to access edge weights.</p>
</div><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Output" class="associatedtype trait-impl"><a href="#associatedtype.Output" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/1.76.0/core/ops/index/trait.Index.html#associatedtype.Output" class="associatedtype">Output</a> = E</h4></section></summary><div class='docblock'>The returned type after indexing.</div></details><details class="toggle method-toggle" open><summary><section id="method.index" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#873-877">source</a><a href="#method.index" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/ops/index/trait.Index.html#tymethod.index" class="fn">index</a>(&amp;self, index: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.tuple.html">(N, N)</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;E</a></h4></section></summary><div class='docblock'>Performs the indexing (<code>container[index]</code>) operation. <a href="https://doc.rust-lang.org/1.76.0/core/ops/index/trait.Index.html#tymethod.index">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-IndexMut%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#881-891">source</a><a href="#impl-IndexMut%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/ops/index/trait.IndexMut.html" title="trait core::ops::index::IndexMut">IndexMut</a>&lt;<a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.tuple.html">(N, N)</a>&gt; for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="docblock"><p>Index <code>GraphMap</code> by node pairs to access edge weights.</p>
</div><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.index_mut" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#886-890">source</a><a href="#method.index_mut" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/ops/index/trait.IndexMut.html#tymethod.index_mut" class="fn">index_mut</a>(&amp;mut self, index: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.tuple.html">(N, N)</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;mut E</a></h4></section></summary><div class='docblock'>Performs the mutable indexing (<code>container[index]</code>) operation. <a href="https://doc.rust-lang.org/1.76.0/core/ops/index/trait.IndexMut.html#tymethod.index_mut">Read more</a></div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-IntoEdgeReferences-for-%26GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1197-1207">source</a><a href="#impl-IntoEdgeReferences-for-%26GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;'a, N, E: 'a, Ty&gt; <a class="trait" href="../visit/trait.IntoEdgeReferences.html" title="trait petgraph::visit::IntoEdgeReferences">IntoEdgeReferences</a> for &amp;'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a> + 'a,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.EdgeRef" class="associatedtype trait-impl"><a href="#associatedtype.EdgeRef" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoEdgeReferences.html#associatedtype.EdgeRef" class="associatedtype">EdgeRef</a> = (N, N, <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;'a E</a>)</h4></section><section id="associatedtype.EdgeReferences" class="associatedtype trait-impl"><a href="#associatedtype.EdgeReferences" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoEdgeReferences.html#associatedtype.EdgeReferences" class="associatedtype">EdgeReferences</a> = <a class="struct" href="struct.AllEdges.html" title="struct petgraph::graphmap::AllEdges">AllEdges</a>&lt;'a, N, E, Ty&gt;</h4></section><section id="method.edge_references" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1204-1206">source</a><a href="#method.edge_references" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.IntoEdgeReferences.html#tymethod.edge_references" class="fn">edge_references</a>(self) -&gt; Self::<a class="associatedtype" href="../visit/trait.IntoEdgeReferences.html#associatedtype.EdgeReferences" title="type petgraph::visit::IntoEdgeReferences::EdgeReferences">EdgeReferences</a></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-IntoEdges-for-%26GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1175-1184">source</a><a href="#impl-IntoEdges-for-%26GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;'a, N, E: 'a, Ty&gt; <a class="trait" href="../visit/trait.IntoEdges.html" title="trait petgraph::visit::IntoEdges">IntoEdges</a> for &amp;'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a> + 'a,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.Edges" class="associatedtype trait-impl"><a href="#associatedtype.Edges" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoEdges.html#associatedtype.Edges" class="associatedtype">Edges</a> = <a class="struct" href="struct.Edges.html" title="struct petgraph::graphmap::Edges">Edges</a>&lt;'a, N, E, Ty&gt;</h4></section><section id="method.edges-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1181-1183">source</a><a href="#method.edges-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.IntoEdges.html#tymethod.edges" class="fn">edges</a>(self, a: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>) -&gt; Self::<a class="associatedtype" href="../visit/trait.IntoEdges.html#associatedtype.Edges" title="type petgraph::visit::IntoEdges::Edges">Edges</a></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-IntoEdgesDirected-for-%26GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1186-1195">source</a><a href="#impl-IntoEdgesDirected-for-%26GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;'a, N, E: 'a, Ty&gt; <a class="trait" href="../visit/trait.IntoEdgesDirected.html" title="trait petgraph::visit::IntoEdgesDirected">IntoEdgesDirected</a> for &amp;'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a> + 'a,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.EdgesDirected" class="associatedtype trait-impl"><a href="#associatedtype.EdgesDirected" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoEdgesDirected.html#associatedtype.EdgesDirected" class="associatedtype">EdgesDirected</a> = <a class="struct" href="struct.EdgesDirected.html" title="struct petgraph::graphmap::EdgesDirected">EdgesDirected</a>&lt;'a, N, E, Ty&gt;</h4></section><section id="method.edges_directed-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1192-1194">source</a><a href="#method.edges_directed-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.IntoEdgesDirected.html#tymethod.edges_directed" class="fn">edges_directed</a>(self, a: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>, dir: <a class="enum" href="../enum.Direction.html" title="enum petgraph::Direction">Direction</a>) -&gt; Self::<a class="associatedtype" href="../visit/trait.IntoEdgesDirected.html#associatedtype.EdgesDirected" title="type petgraph::visit::IntoEdgesDirected::EdgesDirected">EdgesDirected</a></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-IntoNeighbors-for-%26GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1128-1137">source</a><a href="#impl-IntoNeighbors-for-%26GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;'a, N, E, Ty&gt; <a class="trait" href="../visit/trait.IntoNeighbors.html" title="trait petgraph::visit::IntoNeighbors">IntoNeighbors</a> for &amp;'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/hash/trait.Hash.html" title="trait core::hash::Hash">Hash</a> + 'a,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.Neighbors" class="associatedtype trait-impl"><a href="#associatedtype.Neighbors" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoNeighbors.html#associatedtype.Neighbors" class="associatedtype">Neighbors</a> = <a class="struct" href="struct.Neighbors.html" title="struct petgraph::graphmap::Neighbors">Neighbors</a>&lt;'a, N, Ty&gt;</h4></section><details class="toggle method-toggle" open><summary><section id="method.neighbors-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1134-1136">source</a><a href="#method.neighbors-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.IntoNeighbors.html#tymethod.neighbors" class="fn">neighbors</a>(self, n: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>) -&gt; Self::<a class="associatedtype" href="../visit/trait.IntoNeighbors.html#associatedtype.Neighbors" title="type petgraph::visit::IntoNeighbors::Neighbors">Neighbors</a></h4></section></summary><div class='docblock'>Return an iterator of the neighbors of node <code>a</code>.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-IntoNeighborsDirected-for-%26GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1139-1148">source</a><a href="#impl-IntoNeighborsDirected-for-%26GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;'a, N, E, Ty&gt; <a class="trait" href="../visit/trait.IntoNeighborsDirected.html" title="trait petgraph::visit::IntoNeighborsDirected">IntoNeighborsDirected</a> for &amp;'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/hash/trait.Hash.html" title="trait core::hash::Hash">Hash</a> + 'a,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.NeighborsDirected" class="associatedtype trait-impl"><a href="#associatedtype.NeighborsDirected" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoNeighborsDirected.html#associatedtype.NeighborsDirected" class="associatedtype">NeighborsDirected</a> = <a class="struct" href="struct.NeighborsDirected.html" title="struct petgraph::graphmap::NeighborsDirected">NeighborsDirected</a>&lt;'a, N, Ty&gt;</h4></section><section id="method.neighbors_directed-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1145-1147">source</a><a href="#method.neighbors_directed-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.IntoNeighborsDirected.html#tymethod.neighbors_directed" class="fn">neighbors_directed</a>(self, n: N, dir: <a class="enum" href="../enum.Direction.html" title="enum petgraph::Direction">Direction</a>) -&gt; Self::<a class="associatedtype" href="../visit/trait.IntoNeighborsDirected.html#associatedtype.NeighborsDirected" title="type petgraph::visit::IntoNeighborsDirected::NeighborsDirected">NeighborsDirected</a></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-IntoNodeIdentifiers-for-%26GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1072-1086">source</a><a href="#impl-IntoNodeIdentifiers-for-%26GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;'a, N, E: 'a, Ty&gt; <a class="trait" href="../visit/trait.IntoNodeIdentifiers.html" title="trait petgraph::visit::IntoNodeIdentifiers">IntoNodeIdentifiers</a> for &amp;'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.NodeIdentifiers" class="associatedtype trait-impl"><a href="#associatedtype.NodeIdentifiers" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoNodeIdentifiers.html#associatedtype.NodeIdentifiers" class="associatedtype">NodeIdentifiers</a> = <a class="struct" href="struct.NodeIdentifiers.html" title="struct petgraph::graphmap::NodeIdentifiers">NodeIdentifiers</a>&lt;'a, N, E, Ty&gt;</h4></section><section id="method.node_identifiers" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1079-1085">source</a><a href="#method.node_identifiers" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.IntoNodeIdentifiers.html#tymethod.node_identifiers" class="fn">node_identifiers</a>(self) -&gt; Self::<a class="associatedtype" href="../visit/trait.IntoNodeIdentifiers.html#associatedtype.NodeIdentifiers" title="type petgraph::visit::IntoNodeIdentifiers::NodeIdentifiers">NodeIdentifiers</a></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-IntoNodeReferences-for-%26GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1056-1070">source</a><a href="#impl-IntoNodeReferences-for-%26GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;'a, N, E, Ty&gt; <a class="trait" href="../visit/trait.IntoNodeReferences.html" title="trait petgraph::visit::IntoNodeReferences">IntoNodeReferences</a> for &amp;'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.NodeRef" class="associatedtype trait-impl"><a href="#associatedtype.NodeRef" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoNodeReferences.html#associatedtype.NodeRef" class="associatedtype">NodeRef</a> = (N, <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;'a N</a>)</h4></section><section id="associatedtype.NodeReferences" class="associatedtype trait-impl"><a href="#associatedtype.NodeReferences" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.IntoNodeReferences.html#associatedtype.NodeReferences" class="associatedtype">NodeReferences</a> = <a class="struct" href="struct.NodeReferences.html" title="struct petgraph::graphmap::NodeReferences">NodeReferences</a>&lt;'a, N, E, Ty&gt;</h4></section><section id="method.node_references" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1063-1069">source</a><a href="#method.node_references" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.IntoNodeReferences.html#tymethod.node_references" class="fn">node_references</a>(self) -&gt; Self::<a class="associatedtype" href="../visit/trait.IntoNodeReferences.html#associatedtype.NodeReferences" title="type petgraph::visit::IntoNodeReferences::NodeReferences">NodeReferences</a></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-NodeCount-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1088-1096">source</a><a href="#impl-NodeCount-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.NodeCount.html" title="trait petgraph::visit::NodeCount">NodeCount</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><section id="method.node_count-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1093-1095">source</a><a href="#method.node_count-1" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.NodeCount.html#tymethod.node_count" class="fn">node_count</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-NodeIndexable-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1098-1119">source</a><a href="#impl-NodeIndexable-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.NodeIndexable.html" title="trait petgraph::visit::NodeIndexable">NodeIndexable</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.node_bound" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1103-1105">source</a><a href="#method.node_bound" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.NodeIndexable.html#tymethod.node_bound" class="fn">node_bound</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a></h4></section></summary><div class='docblock'>Return an upper bound of the node indices in the graph
(suitable for the size of a bitmap).</div></details><details class="toggle method-toggle" open><summary><section id="method.to_index" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1106-1109">source</a><a href="#method.to_index" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.NodeIndexable.html#tymethod.to_index" class="fn">to_index</a>(&amp;self, ix: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a></h4></section></summary><div class='docblock'>Convert <code>a</code> to an integer index.</div></details><details class="toggle method-toggle" open><summary><section id="method.from_index" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1110-1118">source</a><a href="#method.from_index" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.NodeIndexable.html#tymethod.from_index" class="fn">from_index</a>(&amp;self, ix: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.usize.html">usize</a>) -&gt; Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a></h4></section></summary><div class='docblock'>Convert <code>i</code> to a node index. <code>i</code> must be a valid value in the graph.</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Visitable-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1034-1046">source</a><a href="#impl-Visitable-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.Visitable.html" title="trait petgraph::visit::Visitable">Visitable</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> + <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/hash/trait.Hash.html" title="trait core::hash::Hash">Hash</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Map" class="associatedtype trait-impl"><a href="#associatedtype.Map" class="anchor">§</a><h4 class="code-header">type <a href="../visit/trait.Visitable.html#associatedtype.Map" class="associatedtype">Map</a> = <a class="struct" href="https://doc.rust-lang.org/1.76.0/std/collections/hash/set/struct.HashSet.html" title="struct std::collections::hash::set::HashSet">HashSet</a>&lt;N&gt;</h4></section></summary><div class='docblock'>The associated map type</div></details><details class="toggle method-toggle" open><summary><section id="method.visit_map" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1040-1042">source</a><a href="#method.visit_map" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.Visitable.html#tymethod.visit_map" class="fn">visit_map</a>(&amp;self) -&gt; <a class="struct" href="https://doc.rust-lang.org/1.76.0/std/collections/hash/set/struct.HashSet.html" title="struct std::collections::hash::set::HashSet">HashSet</a>&lt;N&gt;</h4></section></summary><div class='docblock'>Create a new visitor map</div></details><details class="toggle method-toggle" open><summary><section id="method.reset_map" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1043-1045">source</a><a href="#method.reset_map" class="anchor">§</a><h4 class="code-header">fn <a href="../visit/trait.Visitable.html#tymethod.reset_map" class="fn">reset_map</a>(&amp;self, map: &amp;mut Self::<a class="associatedtype" href="../visit/trait.Visitable.html#associatedtype.Map" title="type petgraph::visit::Visitable::Map">Map</a>)</h4></section></summary><div class='docblock'>Reset the visitor map (and resize to new size of graph if needed)</div></details></div></details><section id="impl-NodeCompactIndexable-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1121-1126">source</a><a href="#impl-NodeCompactIndexable-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="../visit/trait.NodeCompactIndexable.html" title="trait petgraph::visit::NodeCompactIndexable">NodeCompactIndexable</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
N: <a class="trait" href="trait.NodeTrait.html" title="trait petgraph::graphmap::NodeTrait">NodeTrait</a>,
Ty: <a class="trait" href="../trait.EdgeType.html" title="trait petgraph::EdgeType">EdgeType</a>,</div></h3></section></div><h2 id="synthetic-implementations" class="section-header">Auto Trait Implementations<a href="#synthetic-implementations" class="anchor">§</a></h2><div id="synthetic-implementations-list"><section id="impl-RefUnwindSafe-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a href="#impl-RefUnwindSafe-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
E: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a>,
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a>,
Ty: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a>,</div></h3></section><section id="impl-Send-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a href="#impl-Send-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
E: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a>,
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a>,
Ty: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a>,</div></h3></section><section id="impl-Sync-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a href="#impl-Sync-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
E: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a>,
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a>,
Ty: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a>,</div></h3></section><section id="impl-Unpin-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a href="#impl-Unpin-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
E: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a>,
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a>,
Ty: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a>,</div></h3></section><section id="impl-UnwindSafe-for-GraphMap%3CN,+E,+Ty%3E" class="impl"><a href="#impl-UnwindSafe-for-GraphMap%3CN,+E,+Ty%3E" class="anchor">§</a><h3 class="code-header">impl&lt;N, E, Ty&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a>&lt;N, E, Ty&gt;<div class="where">where
E: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a>,
N: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a>,
Ty: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a>,</div></h3></section></div><h2 id="blanket-implementations" class="section-header">Blanket Implementations<a href="#blanket-implementations" class="anchor">§</a></h2><div id="blanket-implementations-list"><details class="toggle implementors-toggle"><summary><section id="impl-Any-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/any.rs.html#140">source</a><a href="#impl-Any-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/any/trait.Any.html" title="trait core::any::Any">Any</a> for T<div class="where">where
T: 'static + ?<a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.type_id" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/any.rs.html#141">source</a><a href="#method.type_id" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/any/trait.Any.html#tymethod.type_id" class="fn">type_id</a>(&amp;self) -&gt; <a class="struct" href="https://doc.rust-lang.org/1.76.0/core/any/struct.TypeId.html" title="struct core::any::TypeId">TypeId</a></h4></section></summary><div class='docblock'>Gets the <code>TypeId</code> of <code>self</code>. <a href="https://doc.rust-lang.org/1.76.0/core/any/trait.Any.html#tymethod.type_id">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Borrow%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/borrow.rs.html#208">source</a><a href="#impl-Borrow%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/borrow/trait.Borrow.html" title="trait core::borrow::Borrow">Borrow</a>&lt;T&gt; for T<div class="where">where
T: ?<a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.borrow" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/borrow.rs.html#210">source</a><a href="#method.borrow" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/borrow/trait.Borrow.html#tymethod.borrow" class="fn">borrow</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;T</a></h4></section></summary><div class='docblock'>Immutably borrows from an owned value. <a href="https://doc.rust-lang.org/1.76.0/core/borrow/trait.Borrow.html#tymethod.borrow">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-BorrowMut%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/borrow.rs.html#216">source</a><a href="#impl-BorrowMut%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/borrow/trait.BorrowMut.html" title="trait core::borrow::BorrowMut">BorrowMut</a>&lt;T&gt; for T<div class="where">where
T: ?<a class="trait" href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.borrow_mut" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/borrow.rs.html#217">source</a><a href="#method.borrow_mut" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut" class="fn">borrow_mut</a>(&amp;mut self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;mut T</a></h4></section></summary><div class='docblock'>Mutably borrows from an owned value. <a href="https://doc.rust-lang.org/1.76.0/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-From%3CT%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/convert/mod.rs.html#763">source</a><a href="#impl-From%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt; for T</h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.from" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/convert/mod.rs.html#766">source</a><a href="#method.from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(t: T) -&gt; T</h4></section></summary><div class="docblock"><p>Returns the argument unchanged.</p>
</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-Into%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/convert/mod.rs.html#747-749">source</a><a href="#impl-Into%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;U&gt; for T<div class="where">where
U: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.into" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/convert/mod.rs.html#756">source</a><a href="#method.into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/convert/trait.Into.html#tymethod.into" class="fn">into</a>(self) -&gt; U</h4></section></summary><div class="docblock"><p>Calls <code>U::from(self)</code>.</p>
<p>That is, this conversion is whatever the implementation of
<code><a href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html" title="trait core::convert::From">From</a>&lt;T&gt; for U</code> chooses to do.</p>
</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-ToOwned-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/alloc/borrow.rs.html#83-85">source</a><a href="#impl-ToOwned-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html" title="trait alloc::borrow::ToOwned">ToOwned</a> for T<div class="where">where
T: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Owned" class="associatedtype trait-impl"><a href="#associatedtype.Owned" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#associatedtype.Owned" class="associatedtype">Owned</a> = T</h4></section></summary><div class='docblock'>The resulting type after obtaining ownership.</div></details><details class="toggle method-toggle" open><summary><section id="method.to_owned" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/alloc/borrow.rs.html#88">source</a><a href="#method.to_owned" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#tymethod.to_owned" class="fn">to_owned</a>(&amp;self) -&gt; T</h4></section></summary><div class='docblock'>Creates owned data from borrowed data, usually by cloning. <a href="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#tymethod.to_owned">Read more</a></div></details><details class="toggle method-toggle" open><summary><section id="method.clone_into" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/alloc/borrow.rs.html#92">source</a><a href="#method.clone_into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#method.clone_into" class="fn">clone_into</a>(&amp;self, target: <a class="primitive" href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&amp;mut T</a>)</h4></section></summary><div class='docblock'>Uses borrowed data to replace owned data, usually by cloning. <a href="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#method.clone_into">Read more</a></div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-TryFrom%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/convert/mod.rs.html#803-805">source</a><a href="#impl-TryFrom%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;U&gt; for T<div class="where">where
U: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error" class="associatedtype trait-impl"><a href="#associatedtype.Error" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#associatedtype.Error" class="associatedtype">Error</a> = <a class="enum" href="https://doc.rust-lang.org/1.76.0/core/convert/enum.Infallible.html" title="enum core::convert::Infallible">Infallible</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="toggle method-toggle" open><summary><section id="method.try_from" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/convert/mod.rs.html#810">source</a><a href="#method.try_from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#tymethod.try_from" class="fn">try_from</a>(value: U) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.76.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;T, &lt;T as <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;U&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><details class="toggle implementors-toggle"><summary><section id="impl-TryInto%3CU%3E-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/convert/mod.rs.html#788-790">source</a><a href="#impl-TryInto%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl&lt;T, U&gt; <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryInto.html" title="trait core::convert::TryInto">TryInto</a>&lt;U&gt; for T<div class="where">where
U: <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error-1" class="associatedtype trait-impl"><a href="#associatedtype.Error-1" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryInto.html#associatedtype.Error" class="associatedtype">Error</a> = &lt;U as <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a></h4></section></summary><div class='docblock'>The type returned in the event of a conversion error.</div></details><details class="toggle method-toggle" open><summary><section id="method.try_into" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.76.0/src/core/convert/mod.rs.html#795">source</a><a href="#method.try_into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryInto.html#tymethod.try_into" class="fn">try_into</a>(self) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.76.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;U, &lt;U as <a class="trait" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a>&lt;T&gt;&gt;::<a class="associatedtype" href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a>&gt;</h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details></div><script type="text/json" id="notable-traits-data">{"AllEdges<'_, N, E, Ty>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.AllEdges.html\" title=\"struct petgraph::graphmap::AllEdges\">AllEdges</a>&lt;'a, N, E, Ty&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a, N, E, Ty&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.AllEdges.html\" title=\"struct petgraph::graphmap::AllEdges\">AllEdges</a>&lt;'a, N, E, Ty&gt;<div class=\"where\">where\n N: 'a + <a class=\"trait\" href=\"trait.NodeTrait.html\" title=\"trait petgraph::graphmap::NodeTrait\">NodeTrait</a>,\n E: 'a,\n Ty: <a class=\"trait\" href=\"../trait.EdgeType.html\" title=\"trait petgraph::EdgeType\">EdgeType</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = (N, N, <a class=\"primitive\" href=\"https://doc.rust-lang.org/1.76.0/std/primitive.reference.html\">&amp;'a E</a>);</div>","AllEdgesMut<'_, N, E, Ty>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.AllEdgesMut.html\" title=\"struct petgraph::graphmap::AllEdgesMut\">AllEdgesMut</a>&lt;'a, N, E, Ty&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a, N, E, Ty&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.AllEdgesMut.html\" title=\"struct petgraph::graphmap::AllEdgesMut\">AllEdgesMut</a>&lt;'a, N, E, Ty&gt;<div class=\"where\">where\n N: 'a + <a class=\"trait\" href=\"trait.NodeTrait.html\" title=\"trait petgraph::graphmap::NodeTrait\">NodeTrait</a>,\n E: 'a,\n Ty: <a class=\"trait\" href=\"../trait.EdgeType.html\" title=\"trait petgraph::EdgeType\">EdgeType</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = (N, N, <a class=\"primitive\" href=\"https://doc.rust-lang.org/1.76.0/std/primitive.reference.html\">&amp;'a mut E</a>);</div>","Edges<'_, N, E, Ty>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.Edges.html\" title=\"struct petgraph::graphmap::Edges\">Edges</a>&lt;'a, N, E, Ty&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a, N, E, Ty&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.Edges.html\" title=\"struct petgraph::graphmap::Edges\">Edges</a>&lt;'a, N, E, Ty&gt;<div class=\"where\">where\n N: 'a + <a class=\"trait\" href=\"trait.NodeTrait.html\" title=\"trait petgraph::graphmap::NodeTrait\">NodeTrait</a>,\n E: 'a,\n Ty: <a class=\"trait\" href=\"../trait.EdgeType.html\" title=\"trait petgraph::EdgeType\">EdgeType</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = (N, N, <a class=\"primitive\" href=\"https://doc.rust-lang.org/1.76.0/std/primitive.reference.html\">&amp;'a E</a>);</div>","EdgesDirected<'_, N, E, Ty>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.EdgesDirected.html\" title=\"struct petgraph::graphmap::EdgesDirected\">EdgesDirected</a>&lt;'a, N, E, Ty&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a, N, E, Ty&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.EdgesDirected.html\" title=\"struct petgraph::graphmap::EdgesDirected\">EdgesDirected</a>&lt;'a, N, E, Ty&gt;<div class=\"where\">where\n N: 'a + <a class=\"trait\" href=\"trait.NodeTrait.html\" title=\"trait petgraph::graphmap::NodeTrait\">NodeTrait</a>,\n E: 'a,\n Ty: <a class=\"trait\" href=\"../trait.EdgeType.html\" title=\"trait petgraph::EdgeType\">EdgeType</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = (N, N, <a class=\"primitive\" href=\"https://doc.rust-lang.org/1.76.0/std/primitive.reference.html\">&amp;'a E</a>);</div>","Neighbors<'_, N, Ty>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.Neighbors.html\" title=\"struct petgraph::graphmap::Neighbors\">Neighbors</a>&lt;'a, N, Ty&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a, N, Ty&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.Neighbors.html\" title=\"struct petgraph::graphmap::Neighbors\">Neighbors</a>&lt;'a, N, Ty&gt;<div class=\"where\">where\n N: <a class=\"trait\" href=\"trait.NodeTrait.html\" title=\"trait petgraph::graphmap::NodeTrait\">NodeTrait</a>,\n Ty: <a class=\"trait\" href=\"../trait.EdgeType.html\" title=\"trait petgraph::EdgeType\">EdgeType</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = N;</div>","NeighborsDirected<'_, N, Ty>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.NeighborsDirected.html\" title=\"struct petgraph::graphmap::NeighborsDirected\">NeighborsDirected</a>&lt;'a, N, Ty&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a, N, Ty&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.NeighborsDirected.html\" title=\"struct petgraph::graphmap::NeighborsDirected\">NeighborsDirected</a>&lt;'a, N, Ty&gt;<div class=\"where\">where\n N: <a class=\"trait\" href=\"trait.NodeTrait.html\" title=\"trait petgraph::graphmap::NodeTrait\">NodeTrait</a>,\n Ty: <a class=\"trait\" href=\"../trait.EdgeType.html\" title=\"trait petgraph::EdgeType\">EdgeType</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = N;</div>","Nodes<'_, N>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.Nodes.html\" title=\"struct petgraph::graphmap::Nodes\">Nodes</a>&lt;'a, N&gt;</code></h3><pre><code><div class=\"where\">impl&lt;'a, N&gt; <a class=\"trait\" href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.Nodes.html\" title=\"struct petgraph::graphmap::Nodes\">Nodes</a>&lt;'a, N&gt;<div class=\"where\">where\n N: 'a + <a class=\"trait\" href=\"trait.NodeTrait.html\" title=\"trait petgraph::graphmap::NodeTrait\">NodeTrait</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = N;</div>"}</script></section></div></main></body></html>