315 lines
136 KiB
HTML
315 lines
136 KiB
HTML
<!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<N, E, Ty>` is a graph datastructure using an associative array of its node weights `N`."><title>GraphMap in petgraph::graphmap - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-6b053e98.ttf.woff2,FiraSans-Regular-0fe48ade.woff2,FiraSans-Medium-e1aa3f0a.woff2,SourceCodePro-Regular-8badfe75.ttf.woff2,SourceCodePro-Semibold-aa29a496.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2" crossorigin href="../../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../../static.files/normalize-9960930a.css"><link rel="stylesheet" href="../../static.files/rustdoc-42caa33d.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.84.0 (9fc6b4312 2025-01-07)" data-channel="1.84.0" data-search-js="search-92e6798f.js" data-settings-js="settings-0f613d39.js" ><script src="../../static.files/storage-59e33391.js"></script><script defer src="sidebar-items.js"></script><script defer src="../../static.files/main-5f194d8c.js"></script><noscript><link rel="stylesheet" href="../../static.files/noscript-893ab5e7.css"></noscript><link rel="alternate icon" type="image/png" href="../../static.files/favicon-32x32-6580c154.png"><link rel="icon" type="image/svg+xml" href="../../static.files/favicon-044be391.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" title="show sidebar"></button></nav><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../../petgraph/index.html">petgraph</a><span class="version">0.6.5</span></h2></div><div class="sidebar-elems"><section id="rustdoc-toc"><h2 class="location"><a href="#">Graph<wbr>Map</a></h2><h3><a href="#implementations">Methods</a></h3><ul class="block method"><li><a href="#method.add_edge" title="add_edge">add_edge</a></li><li><a href="#method.add_node" title="add_node">add_node</a></li><li><a href="#method.all_edges" title="all_edges">all_edges</a></li><li><a href="#method.all_edges_mut" title="all_edges_mut">all_edges_mut</a></li><li><a href="#method.capacity" title="capacity">capacity</a></li><li><a href="#method.clear" title="clear">clear</a></li><li><a href="#method.contains_edge" title="contains_edge">contains_edge</a></li><li><a href="#method.contains_node" title="contains_node">contains_node</a></li><li><a href="#method.edge_count" title="edge_count">edge_count</a></li><li><a href="#method.edge_weight" title="edge_weight">edge_weight</a></li><li><a href="#method.edge_weight_mut" title="edge_weight_mut">edge_weight_mut</a></li><li><a href="#method.edges" title="edges">edges</a></li><li><a href="#method.edges_directed" title="edges_directed">edges_directed</a></li><li><a href="#method.from_edges" title="from_edges">from_edges</a></li><li><a href="#method.from_graph" title="from_graph">from_graph</a></li><li><a href="#method.into_graph" title="into_graph">into_graph</a></li><li><a href="#method.is_directed" title="is_directed">is_directed</a></li><li><a href="#method.neighbors" title="neighbors">neighbors</a></li><li><a href="#method.neighbors_directed" title="neighbors_directed">neighbors_directed</a></li><li><a href="#method.new" title="new">new</a></li><li><a href="#method.node_count" title="node_count">node_count</a></li><li><a href="#method.nodes" title="nodes">nodes</a></li><li><a href="#method.remove_edge" title="remove_edge">remove_edge</a></li><li><a href="#method.remove_node" title="remove_node">remove_node</a></li><li><a href="#method.with_capacity" title="with_capacity">with_capacity</a></li><li><a href="#method.with_capacity_and_hasher" title="with_capacity_and_hasher">with_capacity_and_hasher</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" title="Build">Build</a></li><li><a href="#impl-Clone-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Clone">Clone</a></li><li><a href="#impl-Create-for-GraphMap%3CN,+E,+Ty%3E" title="Create">Create</a></li><li><a href="#impl-Data-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Data">Data</a></li><li><a href="#impl-Debug-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Debug">Debug</a></li><li><a href="#impl-Default-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Default">Default</a></li><li><a href="#impl-Deserialize%3C'de%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Deserialize<'de>">Deserialize<'de></a></li><li><a href="#impl-EdgeCount-for-GraphMap%3CN,+E,+Ty,+S%3E" title="EdgeCount">EdgeCount</a></li><li><a href="#impl-EdgeIndexable-for-GraphMap%3CN,+E,+Ty,+S%3E" title="EdgeIndexable">EdgeIndexable</a></li><li><a href="#impl-Extend%3CItem%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Extend<Item>">Extend<Item></a></li><li><a href="#impl-FromElements-for-GraphMap%3CN,+E,+Ty%3E" title="FromElements">FromElements</a></li><li><a href="#impl-FromIterator%3CItem%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" title="FromIterator<Item>">FromIterator<Item></a></li><li><a href="#impl-GetAdjacencyMatrix-for-GraphMap%3CN,+E,+Ty,+S%3E" title="GetAdjacencyMatrix">GetAdjacencyMatrix</a></li><li><a href="#impl-GraphBase-for-GraphMap%3CN,+E,+Ty,+S%3E" title="GraphBase">GraphBase</a></li><li><a href="#impl-GraphProp-for-GraphMap%3CN,+E,+Ty,+S%3E" title="GraphProp">GraphProp</a></li><li><a href="#impl-Index%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Index<(N, N)>">Index<(N, N)></a></li><li><a href="#impl-IndexMut%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" title="IndexMut<(N, N)>">IndexMut<(N, N)></a></li><li><a href="#impl-IntoEdgeReferences-for-%26GraphMap%3CN,+E,+Ty,+S%3E" title="IntoEdgeReferences">IntoEdgeReferences</a></li><li><a href="#impl-IntoEdges-for-%26GraphMap%3CN,+E,+Ty,+S%3E" title="IntoEdges">IntoEdges</a></li><li><a href="#impl-IntoEdgesDirected-for-%26GraphMap%3CN,+E,+Ty,+S%3E" title="IntoEdgesDirected">IntoEdgesDirected</a></li><li><a href="#impl-IntoNeighbors-for-%26GraphMap%3CN,+E,+Ty,+S%3E" title="IntoNeighbors">IntoNeighbors</a></li><li><a href="#impl-IntoNeighborsDirected-for-%26GraphMap%3CN,+E,+Ty,+S%3E" title="IntoNeighborsDirected">IntoNeighborsDirected</a></li><li><a href="#impl-IntoNodeIdentifiers-for-%26GraphMap%3CN,+E,+Ty,+S%3E" title="IntoNodeIdentifiers">IntoNodeIdentifiers</a></li><li><a href="#impl-IntoNodeReferences-for-%26GraphMap%3CN,+E,+Ty,+S%3E" title="IntoNodeReferences">IntoNodeReferences</a></li><li><a href="#impl-NodeCompactIndexable-for-GraphMap%3CN,+E,+Ty,+S%3E" title="NodeCompactIndexable">NodeCompactIndexable</a></li><li><a href="#impl-NodeCount-for-GraphMap%3CN,+E,+Ty,+S%3E" title="NodeCount">NodeCount</a></li><li><a href="#impl-NodeIndexable-for-GraphMap%3CN,+E,+Ty,+S%3E" title="NodeIndexable">NodeIndexable</a></li><li><a href="#impl-Serialize-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Serialize">Serialize</a></li><li><a href="#impl-Visitable-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Visitable">Visitable</a></li></ul><h3><a href="#synthetic-implementations">Auto Trait Implementations</a></h3><ul class="block synthetic-implementation"><li><a href="#impl-Freeze-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Freeze">Freeze</a></li><li><a href="#impl-RefUnwindSafe-for-GraphMap%3CN,+E,+Ty,+S%3E" title="RefUnwindSafe">RefUnwindSafe</a></li><li><a href="#impl-Send-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Send">Send</a></li><li><a href="#impl-Sync-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Sync">Sync</a></li><li><a href="#impl-Unpin-for-GraphMap%3CN,+E,+Ty,+S%3E" title="Unpin">Unpin</a></li><li><a href="#impl-UnwindSafe-for-GraphMap%3CN,+E,+Ty,+S%3E" title="UnwindSafe">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" title="Any">Any</a></li><li><a href="#impl-Borrow%3CT%3E-for-T" title="Borrow<T>">Borrow<T></a></li><li><a href="#impl-BorrowMut%3CT%3E-for-T" title="BorrowMut<T>">BorrowMut<T></a></li><li><a href="#impl-CloneToUninit-for-T" title="CloneToUninit">CloneToUninit</a></li><li><a href="#impl-DeserializeOwned-for-T" title="DeserializeOwned">DeserializeOwned</a></li><li><a href="#impl-From%3CT%3E-for-T" title="From<T>">From<T></a></li><li><a href="#impl-Into%3CU%3E-for-T" title="Into<U>">Into<U></a></li><li><a href="#impl-ToOwned-for-T" title="ToOwned">ToOwned</a></li><li><a href="#impl-TryFrom%3CU%3E-for-T" title="TryFrom<U>">TryFrom<U></a></li><li><a href="#impl-TryInto%3CU%3E-for-T" title="TryInto<U>">TryInto<U></a></li></ul></section><div id="rustdoc-modnav"><h2><a href="index.html">In petgraph::<wbr>graphmap</a></h2></div></div></nav><div class="sidebar-resizer"></div><main><div class="width-limiter"><rustdoc-search></rustdoc-search><section id="main-content" class="content"><div class="main-heading"><span class="rustdoc-breadcrumbs"><a href="../index.html">petgraph</a>::<wbr><a href="index.html">graphmap</a></span><h1>Struct <span class="struct">GraphMap</span><button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"><a class="src" href="../../src/petgraph/graphmap.rs.html#67-74">Source</a> </span></div><pre class="rust item-decl"><code>pub struct GraphMap<N, E, Ty, S = <a class="struct" href="https://doc.rust-lang.org/1.84.0/std/hash/random/struct.RandomState.html" title="struct std::hash::random::RandomState">RandomState</a>><div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div>{ <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<N, E, Ty></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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#177-635">Source</a><a href="#impl-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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#184-189">Source</a><h4 class="code-header">pub fn <a href="#method.new" class="fn">new</a>() -> Self<div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/default/trait.Default.html" title="trait core::default::Default">Default</a>,</div></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#192-201">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.84.0/std/primitive.usize.html">usize</a>, edges: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.usize.html">usize</a>) -> Self<div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/default/trait.Default.html" title="trait core::default::Default">Default</a>,</div></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.with_capacity_and_hasher" class="method"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#204-213">Source</a><h4 class="code-header">pub fn <a href="#method.with_capacity_and_hasher" class="fn">with_capacity_and_hasher</a>(nodes: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.usize.html">usize</a>, edges: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.usize.html">usize</a>, hasher: S) -> Self<div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,</div></h4></section></summary><div class="docblock"><p>Create a new <code>GraphMap</code> with estimated capacity, and specified hasher.</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#216-218">Source</a><h4 class="code-header">pub fn <a href="#method.capacity" class="fn">capacity</a>(&self) -> (<a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.usize.html">usize</a>, <a class="primitive" href="https://doc.rust-lang.org/1.84.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#231-233">Source</a><h4 class="code-header">pub fn <a href="#method.is_directed" class="fn">is_directed</a>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#254-261">Source</a><h4 class="code-header">pub fn <a href="#method.from_edges" class="fn">from_edges</a><I>(iterable: I) -> Self<div class="where">where
|
||
I: <a class="trait" href="https://doc.rust-lang.org/1.84.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.84.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><E, NodeId = N>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/default/trait.Default.html" title="trait core::default::Default">Default</a>,</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::<<span class="kw">_</span>, ()>::from_edges(<span class="kw-2">&</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#264-266">Source</a><h4 class="code-header">pub fn <a href="#method.node_count" class="fn">node_count</a>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#269-271">Source</a><h4 class="code-header">pub fn <a href="#method.edge_count" class="fn">edge_count</a>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#274-277">Source</a><h4 class="code-header">pub fn <a href="#method.clear" class="fn">clear</a>(&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#280-283">Source</a><h4 class="code-header">pub fn <a href="#method.add_node" class="fn">add_node</a>(&mut self, n: N) -> 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#288-305">Source</a><h4 class="code-header">pub fn <a href="#method.remove_node" class="fn">remove_node</a>(&mut self, n: N) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#308-310">Source</a><h4 class="code-header">pub fn <a href="#method.contains_node" class="fn">contains_node</a>(&self, n: N) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#333-351">Source</a><h4 class="code-header">pub fn <a href="#method.add_edge" class="fn">add_edge</a>(&mut self, a: N, b: N, weight: E) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><E></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 aren’t 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#396-406">Source</a><h4 class="code-header">pub fn <a href="#method.remove_edge" class="fn">remove_edge</a>(&mut self, a: N, b: N) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><E></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 didn’t 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#409-411">Source</a><h4 class="code-header">pub fn <a href="#method.contains_edge" class="fn">contains_edge</a>(&self, a: N, b: N) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#416-420">Source</a><h4 class="code-header">pub fn <a href="#method.nodes" class="fn">nodes</a>(&self) -> <a class="struct" href="struct.Nodes.html" title="struct petgraph::graphmap::Nodes">Nodes</a><'_, N> <a href="#" class="tooltip" data-notable-ty="Nodes<'_, N>">ⓘ</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#442-450">Source</a><h4 class="code-header">pub fn <a href="#method.neighbors" class="fn">neighbors</a>(&self, a: N) -> <a class="struct" href="struct.Neighbors.html" title="struct petgraph::graphmap::Neighbors">Neighbors</a><'_, N, Ty> <a href="#" class="tooltip" data-notable-ty="Neighbors<'_, N, Ty>">ⓘ</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 doesn’t 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#462-472">Source</a><h4 class="code-header">pub fn <a href="#method.neighbors_directed" class="fn">neighbors_directed</a>(
|
||
&self,
|
||
a: N,
|
||
dir: <a class="enum" href="../enum.Direction.html" title="enum petgraph::Direction">Direction</a>,
|
||
) -> <a class="struct" href="struct.NeighborsDirected.html" title="struct petgraph::graphmap::NeighborsDirected">NeighborsDirected</a><'_, N, Ty> <a href="#" class="tooltip" data-notable-ty="NeighborsDirected<'_, N, Ty>">ⓘ</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 graph’s 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 doesn’t 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#482-488">Source</a><h4 class="code-header">pub fn <a href="#method.edges" class="fn">edges</a>(&self, a: N) -> <a class="struct" href="struct.Edges.html" title="struct petgraph::graphmap::Edges">Edges</a><'_, N, E, Ty, S> <a href="#" class="tooltip" data-notable-ty="Edges<'_, N, E, Ty, S>">ⓘ</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 doesn’t exist.<br>
|
||
Iterator element type is <code>(N, N, &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#502-509">Source</a><h4 class="code-header">pub fn <a href="#method.edges_directed" class="fn">edges_directed</a>(
|
||
&self,
|
||
a: N,
|
||
dir: <a class="enum" href="../enum.Direction.html" title="enum petgraph::Direction">Direction</a>,
|
||
) -> <a class="struct" href="struct.EdgesDirected.html" title="struct petgraph::graphmap::EdgesDirected">EdgesDirected</a><'_, N, E, Ty, S> <a href="#" class="tooltip" data-notable-ty="EdgesDirected<'_, N, E, Ty, S>">ⓘ</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 doesn’t exist.<br>
|
||
Iterator element type is <code>(N, N, &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#513-515">Source</a><h4 class="code-header">pub fn <a href="#method.edge_weight" class="fn">edge_weight</a>(&self, a: N, b: N) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.reference.html">&E</a>></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#519-521">Source</a><h4 class="code-header">pub fn <a href="#method.edge_weight_mut" class="fn">edge_weight_mut</a>(&mut self, a: N, b: N) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><<a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.reference.html">&mut E</a>></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#526-531">Source</a><h4 class="code-header">pub fn <a href="#method.all_edges" class="fn">all_edges</a>(&self) -> <a class="struct" href="struct.AllEdges.html" title="struct petgraph::graphmap::AllEdges">AllEdges</a><'_, N, E, Ty> <a href="#" class="tooltip" data-notable-ty="AllEdges<'_, N, E, Ty>">ⓘ</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, &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#537-542">Source</a><h4 class="code-header">pub fn <a href="#method.all_edges_mut" class="fn">all_edges_mut</a>(&mut self) -> <a class="struct" href="struct.AllEdgesMut.html" title="struct petgraph::graphmap::AllEdgesMut">AllEdgesMut</a><'_, N, E, Ty> <a href="#" class="tooltip" data-notable-ty="AllEdgesMut<'_, N, E, Ty>">ⓘ</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, &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#587-602">Source</a><h4 class="code-header">pub fn <a href="#method.into_graph" class="fn">into_graph</a><Ix>(self) -> <a class="struct" href="../graph/struct.Graph.html" title="struct petgraph::graph::Graph">Graph</a><N, E, Ty, Ix><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 graph’s 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#611-634">Source</a><h4 class="code-header">pub fn <a href="#method.from_graph" class="fn">from_graph</a><Ix>(graph: <a class="struct" href="../graph/struct.Graph.html" title="struct petgraph::graph::Graph">Graph</a><N, E, Ty, Ix>) -> 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.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/default/trait.Default.html" title="trait core::default::Default">Default</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<N, E, Ty> <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><N, E, Ty><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>(&mut self, weight: 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.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>(
|
||
&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>,
|
||
) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a><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 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>(
|
||
&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>,
|
||
) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#66">Source</a><a href="#impl-Clone-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>, E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>, Ty: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>, S> <a class="trait" href="https://doc.rust-lang.org/1.84.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><N, E, Ty, S><div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,</div></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#66">Source</a><a href="#method.clone" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html#tymethod.clone" class="fn">clone</a>(&self) -> <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S></h4></section></summary><div class='docblock'>Returns a copy of the value. <a href="https://doc.rust-lang.org/1.84.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.84.0/src/core/clone.rs.html#174">Source</a></span><a href="#method.clone_from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html#method.clone_from" class="fn">clone_from</a>(&mut self, source: &Self)</h4></section></summary><div class='docblock'>Performs copy-assignment from <code>source</code>. <a href="https://doc.rust-lang.org/1.84.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<N, E, Ty> <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><N, E, Ty><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.84.0/std/primitive.usize.html">usize</a>, edges: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.usize.html">usize</a>) -> Self</h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Data-for-GraphMap%3CN,+E,+Ty,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1114-1122">Source</a><a href="#impl-Data-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><div class="where">where
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.NodeWeight" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1120">Source</a><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 class="src rightside" href="../../src/petgraph/graphmap.rs.html#1121">Source</a><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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#76-82">Source</a><a href="#impl-Debug-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/cmp/trait.Eq.html" title="trait core::cmp::Eq">Eq</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.Hash.html" title="trait core::hash::Hash">Hash</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a>, E: <a class="trait" href="https://doc.rust-lang.org/1.84.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>, S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>> <a class="trait" href="https://doc.rust-lang.org/1.84.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><N, E, Ty, S></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#79-81">Source</a><a href="#method.fmt" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html#tymethod.fmt" class="fn">fmt</a>(&self, f: &mut <a class="struct" href="https://doc.rust-lang.org/1.84.0/core/fmt/struct.Formatter.html" title="struct core::fmt::Formatter">Formatter</a><'_>) -> <a class="type" href="https://doc.rust-lang.org/1.84.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.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#981-990">Source</a><a href="#impl-Default-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.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><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/default/trait.Default.html" title="trait core::default::Default">Default</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#987-989">Source</a><a href="#method.default" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/default/trait.Default.html#tymethod.default" class="fn">default</a>() -> Self</h4></section></summary><div class='docblock'>Returns the “default value” for a type. <a href="https://doc.rust-lang.org/1.84.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-Deserialize%3C'de%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#154-175">Source</a><a href="#impl-Deserialize%3C'de%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<'de, N, E, Ty, S> <a class="trait" href="../../serde/de/trait.Deserialize.html" title="trait serde::de::Deserialize">Deserialize</a><'de> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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> + <a class="trait" href="../../serde/de/trait.Deserialize.html" title="trait serde::de::Deserialize">Deserialize</a><'de>,
|
||
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a> + <a class="trait" href="../../serde/de/trait.Deserialize.html" title="trait serde::de::Deserialize">Deserialize</a><'de>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/default/trait.Default.html" title="trait core::default::Default">Default</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.deserialize" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#168-174">Source</a><a href="#method.deserialize" class="anchor">§</a><h4 class="code-header">fn <a href="../../serde/de/trait.Deserialize.html#tymethod.deserialize" class="fn">deserialize</a><D>(deserializer: D) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><Self, D::<a class="associatedtype" href="../../serde/de/trait.Deserializer.html#associatedtype.Error" title="type serde::de::Deserializer::Error">Error</a>><div class="where">where
|
||
D: <a class="trait" href="../../serde/de/trait.Deserializer.html" title="trait serde::de::Deserializer">Deserializer</a><'de>,</div></h4></section></summary><div class="docblock"><p>Deserializes into a new <code>GraphMap</code> from the same format as the standard
|
||
<code>Graph</code>. Needs feature <code>serde-1</code>.</p>
|
||
<p><strong>Warning</strong>: When deseralizing a graph that was not originally a <code>GraphMap</code>,
|
||
the restrictions from <a href="#method.from_graph"><code>from_graph</code></a> apply.</p>
|
||
<p>Note: The edge weights have to be <code>Clone</code> for this to work.</p>
|
||
</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-EdgeCount-for-GraphMap%3CN,+E,+Ty,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1310-1320">Source</a><a href="#impl-EdgeCount-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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#1317-1319">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>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1248-1271">Source</a><a href="#impl-EdgeIndexable-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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#1254-1256">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>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#1258-1260">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>(&self, ix: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.EdgeId" title="type petgraph::visit::GraphBase::EdgeId">EdgeId</a>) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#1262-1270">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>(&self, ix: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.usize.html">usize</a>) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#660-680">Source</a><a href="#impl-Extend%3CItem%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, Item, S> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.Extend.html" title="trait core::iter::traits::collect::Extend">Extend</a><Item> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><div class="where">where
|
||
Item: <a class="trait" href="../trait.IntoWeightedEdge.html" title="trait petgraph::IntoWeightedEdge">IntoWeightedEdge</a><E, NodeId = N>,
|
||
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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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#667-679">Source</a><a href="#method.extend" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.Extend.html#tymethod.extend" class="fn">extend</a><I>(&mut self, iterable: I)<div class="where">where
|
||
I: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a><Item = Item>,</div></h4></section></summary><div class='docblock'>Extends a collection with the contents of an iterator. <a href="https://doc.rust-lang.org/1.84.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.84.0/src/core/iter/traits/collect.rs.html#453">Source</a><a href="#method.extend_one" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.Extend.html#method.extend_one" class="fn">extend_one</a>(&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.84.0/src/core/iter/traits/collect.rs.html#461">Source</a><a href="#method.extend_reserve" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.Extend.html#method.extend_reserve" class="fn">extend_reserve</a>(&mut self, additional: <a class="primitive" href="https://doc.rust-lang.org/1.84.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.84.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<N, E, Ty> <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><N, E, Ty><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><I>(iterable: I) -> Self<div class="where">where
|
||
Self: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sized.html" title="trait core::marker::Sized">Sized</a>,
|
||
I: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a><Item = <a class="enum" href="../data/enum.Element.html" title="enum petgraph::data::Element">Element</a><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>>>,</div></h4></section></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-FromIterator%3CItem%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#638-655">Source</a><a href="#impl-FromIterator%3CItem%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, Item, S> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.FromIterator.html" title="trait core::iter::traits::collect::FromIterator">FromIterator</a><Item> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><div class="where">where
|
||
Item: <a class="trait" href="../trait.IntoWeightedEdge.html" title="trait petgraph::IntoWeightedEdge">IntoWeightedEdge</a><E, NodeId = N>,
|
||
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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/default/trait.Default.html" title="trait core::default::Default">Default</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#645-654">Source</a><a href="#method.from_iter" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.FromIterator.html#tymethod.from_iter" class="fn">from_iter</a><I>(iterable: I) -> Self<div class="where">where
|
||
I: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/iter/traits/collect/trait.IntoIterator.html" title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a><Item = Item>,</div></h4></section></summary><div class='docblock'>Creates a value from an iterator. <a href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1323-1336">Source</a><a href="#impl-GetAdjacencyMatrix-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><div class="where">where
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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 class="src rightside" href="../../src/petgraph/graphmap.rs.html#1329">Source</a><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.84.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#1331">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>(&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#1333-1335">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>(&self, _: &<a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.unit.html">()</a>, a: N, b: N) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1105-1112">Source</a><a href="#impl-GraphBase-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><div class="where">where
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/cmp/trait.PartialEq.html" title="trait core::cmp::PartialEq">PartialEq</a>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.NodeId" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1110">Source</a><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 class="src rightside" href="../../src/petgraph/graphmap.rs.html#1111">Source</a><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.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1139-1146">Source</a><a href="#impl-GraphProp-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.EdgeType" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1145">Source</a><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>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#952-964">Source</a><a href="#impl-Index%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/ops/index/trait.Index.html" title="trait core::ops::index::Index">Index</a><<a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.tuple.html">(N, N)</a>> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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 class="src rightside" href="../../src/petgraph/graphmap.rs.html#958">Source</a><a href="#associatedtype.Output" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/1.84.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#959-963">Source</a><a href="#method.index" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/ops/index/trait.Index.html#tymethod.index" class="fn">index</a>(&self, index: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.tuple.html">(N, N)</a>) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.reference.html">&E</a></h4></section></summary><div class='docblock'>Performs the indexing (<code>container[index]</code>) operation. <a href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#967-978">Source</a><a href="#impl-IndexMut%3C(N,+N)%3E-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/ops/index/trait.IndexMut.html" title="trait core::ops::index::IndexMut">IndexMut</a><<a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.tuple.html">(N, N)</a>> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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#973-977">Source</a><a href="#method.index_mut" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/ops/index/trait.IndexMut.html#tymethod.index_mut" class="fn">index_mut</a>(&mut self, index: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.tuple.html">(N, N)</a>) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.reference.html">&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.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1297-1308">Source</a><a href="#impl-IntoEdgeReferences-for-%26GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<'a, N, E: 'a, Ty, S> <a class="trait" href="../visit/trait.IntoEdgeReferences.html" title="trait petgraph::visit::IntoEdgeReferences">IntoEdgeReferences</a> for &'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.EdgeRef" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1303">Source</a><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.84.0/std/primitive.reference.html">&'a E</a>)</h4></section><section id="associatedtype.EdgeReferences" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1304">Source</a><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><'a, N, E, Ty></h4></section><section id="method.edge_references" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1305-1307">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) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1273-1283">Source</a><a href="#impl-IntoEdges-for-%26GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<'a, N, E: 'a, Ty, S> <a class="trait" href="../visit/trait.IntoEdges.html" title="trait petgraph::visit::IntoEdges">IntoEdges</a> for &'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.Edges" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1279">Source</a><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><'a, N, E, Ty, S></h4></section><section id="method.edges-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1280-1282">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>) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1285-1295">Source</a><a href="#impl-IntoEdgesDirected-for-%26GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<'a, N, E: 'a, Ty, S> <a class="trait" href="../visit/trait.IntoEdgesDirected.html" title="trait petgraph::visit::IntoEdgesDirected">IntoEdgesDirected</a> for &'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.EdgesDirected" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1291">Source</a><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><'a, N, E, Ty, S></h4></section><section id="method.edges_directed-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1292-1294">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>) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1224-1234">Source</a><a href="#impl-IntoNeighbors-for-%26GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<'a, N, E, Ty, S> <a class="trait" href="../visit/trait.IntoNeighbors.html" title="trait petgraph::visit::IntoNeighbors">IntoNeighbors</a> for &'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><div class="where">where
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.Neighbors" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1230">Source</a><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><'a, N, Ty></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#1231-1233">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>) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1236-1246">Source</a><a href="#impl-IntoNeighborsDirected-for-%26GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<'a, N, E, Ty, S> <a class="trait" href="../visit/trait.IntoNeighborsDirected.html" title="trait petgraph::visit::IntoNeighborsDirected">IntoNeighborsDirected</a> for &'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><div class="where">where
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.NeighborsDirected" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1242">Source</a><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><'a, N, Ty></h4></section><section id="method.neighbors_directed-1" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1243-1245">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>) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1165-1180">Source</a><a href="#impl-IntoNodeIdentifiers-for-%26GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<'a, N, E: 'a, Ty, S> <a class="trait" href="../visit/trait.IntoNodeIdentifiers.html" title="trait petgraph::visit::IntoNodeIdentifiers">IntoNodeIdentifiers</a> for &'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.NodeIdentifiers" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1171">Source</a><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><'a, N, E, Ty></h4></section><section id="method.node_identifiers" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1173-1179">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) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1148-1163">Source</a><a href="#impl-IntoNodeReferences-for-%26GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<'a, N, E, Ty, S> <a class="trait" href="../visit/trait.IntoNodeReferences.html" title="trait petgraph::visit::IntoNodeReferences">IntoNodeReferences</a> for &'a <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><section id="associatedtype.NodeRef" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1154">Source</a><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.84.0/std/primitive.reference.html">&'a N</a>)</h4></section><section id="associatedtype.NodeReferences" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1155">Source</a><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><'a, N, E, Ty></h4></section><section id="method.node_references" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1156-1162">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) -> 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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1182-1191">Source</a><a href="#impl-NodeCount-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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#1188-1190">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>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1193-1214">Source</a><a href="#impl-NodeIndexable-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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#1199-1201">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>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#1202-1204">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>(&self, ix: Self::<a class="associatedtype" href="../visit/trait.GraphBase.html#associatedtype.NodeId" title="type petgraph::visit::GraphBase::NodeId">NodeId</a>) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.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#1205-1213">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>(&self, ix: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.usize.html">usize</a>) -> 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-Serialize-for-GraphMap%3CN,+E,+Ty,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#131-151">Source</a><a href="#impl-Serialize-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="../../serde/ser/trait.Serialize.html" title="trait serde::ser::Serialize">Serialize</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><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> + <a class="trait" href="../../serde/ser/trait.Serialize.html" title="trait serde::ser::Serialize">Serialize</a>,
|
||
E: <a class="trait" href="../../serde/ser/trait.Serialize.html" title="trait serde::ser::Serialize">Serialize</a>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,
|
||
Self: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.serialize" class="method trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#143-150">Source</a><a href="#method.serialize" class="anchor">§</a><h4 class="code-header">fn <a href="../../serde/ser/trait.Serialize.html#tymethod.serialize" class="fn">serialize</a><Ser>(&self, serializer: Ser) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><Ser::<a class="associatedtype" href="../../serde/ser/trait.Serializer.html#associatedtype.Ok" title="type serde::ser::Serializer::Ok">Ok</a>, Ser::<a class="associatedtype" href="../../serde/ser/trait.Serializer.html#associatedtype.Error" title="type serde::ser::Serializer::Error">Error</a>><div class="where">where
|
||
Ser: <a class="trait" href="../../serde/ser/trait.Serializer.html" title="trait serde::ser::Serializer">Serializer</a>,</div></h4></section></summary><div class="docblock"><p>Serializes the given <code>GraphMap</code> into the same format as the standard
|
||
<code>Graph</code>. Needs feature <code>serde-1</code>.</p>
|
||
<p>Note: the graph has to be <code>Clone</code> for this to work.</p>
|
||
</div></details></div></details><details class="toggle implementors-toggle" open><summary><section id="impl-Visitable-for-GraphMap%3CN,+E,+Ty,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1124-1137">Source</a><a href="#impl-Visitable-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><div class="where">where
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Copy.html" title="trait core::marker::Copy">Copy</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/cmp/trait.Ord.html" title="trait core::cmp::Ord">Ord</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Map" class="associatedtype trait-impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1130">Source</a><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.84.0/std/collections/hash/set/struct.HashSet.html" title="struct std::collections::hash::set::HashSet">HashSet</a><N></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#1131-1133">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>(&self) -> <a class="struct" href="https://doc.rust-lang.org/1.84.0/std/collections/hash/set/struct.HashSet.html" title="struct std::collections::hash::set::HashSet">HashSet</a><N></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#1134-1136">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>(&self, map: &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,+S%3E" class="impl"><a class="src rightside" href="../../src/petgraph/graphmap.rs.html#1216-1222">Source</a><a href="#impl-NodeCompactIndexable-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <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><N, E, Ty, S><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>,
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html" title="trait core::hash::BuildHasher">BuildHasher</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-Freeze-for-GraphMap%3CN,+E,+Ty,+S%3E" class="impl"><a href="#impl-Freeze-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Freeze.html" title="trait core::marker::Freeze">Freeze</a> for <a class="struct" href="struct.GraphMap.html" title="struct petgraph::graphmap::GraphMap">GraphMap</a><N, E, Ty, S><div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Freeze.html" title="trait core::marker::Freeze">Freeze</a>,</div></h3></section><section id="impl-RefUnwindSafe-for-GraphMap%3CN,+E,+Ty,+S%3E" class="impl"><a href="#impl-RefUnwindSafe-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.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><N, E, Ty, S><div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.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.84.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.84.0/core/panic/unwind_safe/trait.RefUnwindSafe.html" title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a>,
|
||
E: <a class="trait" href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a href="#impl-Send-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.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><N, E, Ty, S><div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a>,
|
||
Ty: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a>,
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a>,
|
||
E: <a class="trait" href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a href="#impl-Sync-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.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><N, E, Ty, S><div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a>,
|
||
Ty: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a>,
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a>,
|
||
E: <a class="trait" href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a href="#impl-Unpin-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.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><N, E, Ty, S><div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a>,
|
||
Ty: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a>,
|
||
N: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Unpin.html" title="trait core::marker::Unpin">Unpin</a>,
|
||
E: <a class="trait" href="https://doc.rust-lang.org/1.84.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,+S%3E" class="impl"><a href="#impl-UnwindSafe-for-GraphMap%3CN,+E,+Ty,+S%3E" class="anchor">§</a><h3 class="code-header">impl<N, E, Ty, S> <a class="trait" href="https://doc.rust-lang.org/1.84.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><N, E, Ty, S><div class="where">where
|
||
S: <a class="trait" href="https://doc.rust-lang.org/1.84.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.84.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.84.0/core/panic/unwind_safe/trait.UnwindSafe.html" title="trait core::panic::unwind_safe::UnwindSafe">UnwindSafe</a>,
|
||
E: <a class="trait" href="https://doc.rust-lang.org/1.84.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.84.0/src/core/any.rs.html#138">Source</a><a href="#impl-Any-for-T" class="anchor">§</a><h3 class="code-header">impl<T> <a class="trait" href="https://doc.rust-lang.org/1.84.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.84.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.84.0/src/core/any.rs.html#139">Source</a><a href="#method.type_id" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/any/trait.Any.html#tymethod.type_id" class="fn">type_id</a>(&self) -> <a class="struct" href="https://doc.rust-lang.org/1.84.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.84.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.84.0/src/core/borrow.rs.html#209">Source</a><a href="#impl-Borrow%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl<T> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/borrow/trait.Borrow.html" title="trait core::borrow::Borrow">Borrow</a><T> for T<div class="where">where
|
||
T: ?<a class="trait" href="https://doc.rust-lang.org/1.84.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.84.0/src/core/borrow.rs.html#211">Source</a><a href="#method.borrow" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/borrow/trait.Borrow.html#tymethod.borrow" class="fn">borrow</a>(&self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.reference.html">&T</a></h4></section></summary><div class='docblock'>Immutably borrows from an owned value. <a href="https://doc.rust-lang.org/1.84.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.84.0/src/core/borrow.rs.html#217">Source</a><a href="#impl-BorrowMut%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl<T> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/borrow/trait.BorrowMut.html" title="trait core::borrow::BorrowMut">BorrowMut</a><T> for T<div class="where">where
|
||
T: ?<a class="trait" href="https://doc.rust-lang.org/1.84.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.84.0/src/core/borrow.rs.html#218">Source</a><a href="#method.borrow_mut" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut" class="fn">borrow_mut</a>(&mut self) -> <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.reference.html">&mut T</a></h4></section></summary><div class='docblock'>Mutably borrows from an owned value. <a href="https://doc.rust-lang.org/1.84.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-CloneToUninit-for-T" class="impl"><a class="src rightside" href="https://doc.rust-lang.org/1.84.0/src/core/clone.rs.html#273">Source</a><a href="#impl-CloneToUninit-for-T" class="anchor">§</a><h3 class="code-header">impl<T> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.CloneToUninit.html" title="trait core::clone::CloneToUninit">CloneToUninit</a> for T<div class="where">where
|
||
T: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a>,</div></h3></section></summary><div class="impl-items"><details class="toggle method-toggle" open><summary><section id="method.clone_to_uninit" class="method trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.84.0/src/core/clone.rs.html#275">Source</a><a href="#method.clone_to_uninit" class="anchor">§</a><h4 class="code-header">unsafe fn <a href="https://doc.rust-lang.org/1.84.0/core/clone/trait.CloneToUninit.html#tymethod.clone_to_uninit" class="fn">clone_to_uninit</a>(&self, dst: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.pointer.html">*mut </a><a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.u8.html">u8</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>clone_to_uninit</code>)</span></div></span><div class='docblock'>Performs copy-assignment from <code>self</code> to <code>dst</code>. <a href="https://doc.rust-lang.org/1.84.0/core/clone/trait.CloneToUninit.html#tymethod.clone_to_uninit">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.84.0/src/core/convert/mod.rs.html#765">Source</a><a href="#impl-From%3CT%3E-for-T" class="anchor">§</a><h3 class="code-header">impl<T> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.From.html" title="trait core::convert::From">From</a><T> 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.84.0/src/core/convert/mod.rs.html#768">Source</a><a href="#method.from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/convert/trait.From.html#tymethod.from" class="fn">from</a>(t: T) -> 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.84.0/src/core/convert/mod.rs.html#748-750">Source</a><a href="#impl-Into%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl<T, U> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a><U> for T<div class="where">where
|
||
U: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.From.html" title="trait core::convert::From">From</a><T>,</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.84.0/src/core/convert/mod.rs.html#758">Source</a><a href="#method.into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/convert/trait.Into.html#tymethod.into" class="fn">into</a>(self) -> 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.84.0/core/convert/trait.From.html" title="trait core::convert::From">From</a><T> 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.84.0/src/alloc/borrow.rs.html#82-84">Source</a><a href="#impl-ToOwned-for-T" class="anchor">§</a><h3 class="code-header">impl<T> <a class="trait" href="https://doc.rust-lang.org/1.84.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.84.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 class="src rightside" href="https://doc.rust-lang.org/1.84.0/src/alloc/borrow.rs.html#86">Source</a><a href="#associatedtype.Owned" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/1.84.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.84.0/src/alloc/borrow.rs.html#87">Source</a><a href="#method.to_owned" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/alloc/borrow/trait.ToOwned.html#tymethod.to_owned" class="fn">to_owned</a>(&self) -> T</h4></section></summary><div class='docblock'>Creates owned data from borrowed data, usually by cloning. <a href="https://doc.rust-lang.org/1.84.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.84.0/src/alloc/borrow.rs.html#91">Source</a><a href="#method.clone_into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/alloc/borrow/trait.ToOwned.html#method.clone_into" class="fn">clone_into</a>(&self, target: <a class="primitive" href="https://doc.rust-lang.org/1.84.0/std/primitive.reference.html">&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.84.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.84.0/src/core/convert/mod.rs.html#805-807">Source</a><a href="#impl-TryFrom%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl<T, U> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a><U> for T<div class="where">where
|
||
U: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a><T>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error-1" class="associatedtype trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.84.0/src/core/convert/mod.rs.html#809">Source</a><a href="#associatedtype.Error-1" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html#associatedtype.Error" class="associatedtype">Error</a> = <a class="enum" href="https://doc.rust-lang.org/1.84.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.84.0/src/core/convert/mod.rs.html#812">Source</a><a href="#method.try_from" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html#tymethod.try_from" class="fn">try_from</a>(value: U) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, <T as <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a><U>>::<a class="associatedtype" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a>></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.84.0/src/core/convert/mod.rs.html#790-792">Source</a><a href="#impl-TryInto%3CU%3E-for-T" class="anchor">§</a><h3 class="code-header">impl<T, U> <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryInto.html" title="trait core::convert::TryInto">TryInto</a><U> for T<div class="where">where
|
||
U: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a><T>,</div></h3></section></summary><div class="impl-items"><details class="toggle" open><summary><section id="associatedtype.Error" class="associatedtype trait-impl"><a class="src rightside" href="https://doc.rust-lang.org/1.84.0/src/core/convert/mod.rs.html#794">Source</a><a href="#associatedtype.Error" class="anchor">§</a><h4 class="code-header">type <a href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryInto.html#associatedtype.Error" class="associatedtype">Error</a> = <U as <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a><T>>::<a class="associatedtype" href="https://doc.rust-lang.org/1.84.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.84.0/src/core/convert/mod.rs.html#797">Source</a><a href="#method.try_into" class="anchor">§</a><h4 class="code-header">fn <a href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryInto.html#tymethod.try_into" class="fn">try_into</a>(self) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><U, <U as <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html" title="trait core::convert::TryFrom">TryFrom</a><T>>::<a class="associatedtype" href="https://doc.rust-lang.org/1.84.0/core/convert/trait.TryFrom.html#associatedtype.Error" title="type core::convert::TryFrom::Error">Error</a>></h4></section></summary><div class='docblock'>Performs the conversion.</div></details></div></details><section id="impl-DeserializeOwned-for-T" class="impl"><a class="src rightside" href="../../src/serde/de/mod.rs.html#614">Source</a><a href="#impl-DeserializeOwned-for-T" class="anchor">§</a><h3 class="code-header">impl<T> <a class="trait" href="../../serde/de/trait.DeserializeOwned.html" title="trait serde::de::DeserializeOwned">DeserializeOwned</a> for T<div class="where">where
|
||
T: for<'de> <a class="trait" href="../../serde/de/trait.Deserialize.html" title="trait serde::de::Deserialize">Deserialize</a><'de>,</div></h3></section></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><'a, N, E, Ty></code></h3><pre><code><div class=\"where\">impl<'a, N, E, Ty> <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.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><'a, N, E, Ty><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.84.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.84.0/std/primitive.reference.html\">&'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><'a, N, E, Ty></code></h3><pre><code><div class=\"where\">impl<'a, N, E, Ty> <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.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><'a, N, E, Ty><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.84.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.84.0/std/primitive.reference.html\">&'a mut E</a>);</div>","Edges<'_, N, E, Ty, S>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.Edges.html\" title=\"struct petgraph::graphmap::Edges\">Edges</a><'a, N, E, Ty, S></code></h3><pre><code><div class=\"where\">impl<'a, N, E, Ty, S> <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.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><'a, N, E, Ty, S><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>,\n S: <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html\" title=\"trait core::hash::BuildHasher\">BuildHasher</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.84.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.84.0/std/primitive.reference.html\">&'a E</a>);</div>","EdgesDirected<'_, N, E, Ty, S>":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.EdgesDirected.html\" title=\"struct petgraph::graphmap::EdgesDirected\">EdgesDirected</a><'a, N, E, Ty, S></code></h3><pre><code><div class=\"where\">impl<'a, N, E, Ty, S> <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.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><'a, N, E, Ty, S><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>,\n S: <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.0/core/hash/trait.BuildHasher.html\" title=\"trait core::hash::BuildHasher\">BuildHasher</a>,</div></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.84.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.84.0/std/primitive.reference.html\">&'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><'a, N, Ty></code></h3><pre><code><div class=\"where\">impl<'a, N, Ty> <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.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><'a, N, Ty><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.84.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><'a, N, Ty></code></h3><pre><code><div class=\"where\">impl<'a, N, Ty> <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.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><'a, N, Ty><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.84.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><'a, N></code></h3><pre><code><div class=\"where\">impl<'a, N> <a class=\"trait\" href=\"https://doc.rust-lang.org/1.84.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><'a, N><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.84.0/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = N;</div>"}</script></section></div></main></body></html> |