This commit is contained in:
dabreegster 2022-08-26 16:03:30 +00:00
parent 9ffa3cb981
commit f62eb34864
7 changed files with 30 additions and 18 deletions

View File

@ -5,6 +5,6 @@
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_gui::tools::title_screen::built_info</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../../map_gui/index.html"><img class="rust-logo" src="../../../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press S to search, ? for more options…" type="search"><button type="button" id="help-button" title="help">?</button><div id="settings-menu" tabindex="-1">
<a href="../../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../../wheel.svg"></a></div>
</div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
<h1 class="fqn"><span class="in-band">Constant <a href="../../../index.html">map_gui</a>::<wbr><a href="../../index.html">tools</a>::<wbr><a href="../index.html">title_screen</a>::<wbr><a href="index.html">built_info</a>::<wbr><a class="constant" href="#">BUILT_TIME_UTC</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../../src/map_gui/home/runner/work/abstreet/abstreet/target/debug/build/map_gui-75a1a9aea4e34b56/out/built.rs.html#78">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="docblock item-decl"><pre class="rust const"><code>pub const BUILT_TIME_UTC: &amp;<a class="primitive" href="https://doc.rust-lang.org/1.63.0/std/primitive.str.html">str</a> = r&quot;Fri, 26 Aug 2022 13:31:12 +0000&quot;;</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>The build time in RFC2822, UTC.</p>
<h1 class="fqn"><span class="in-band">Constant <a href="../../../index.html">map_gui</a>::<wbr><a href="../../index.html">tools</a>::<wbr><a href="../index.html">title_screen</a>::<wbr><a href="index.html">built_info</a>::<wbr><a class="constant" href="#">BUILT_TIME_UTC</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../../src/map_gui/home/runner/work/abstreet/abstreet/target/debug/build/map_gui-75a1a9aea4e34b56/out/built.rs.html#78">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="docblock item-decl"><pre class="rust const"><code>pub const BUILT_TIME_UTC: &amp;<a class="primitive" href="https://doc.rust-lang.org/1.63.0/std/primitive.str.html">str</a> = r&quot;Fri, 26 Aug 2022 16:02:24 +0000&quot;;</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>The build time in RFC2822, UTC.</p>
</div></details></section></div></main><div id="rustdoc-vars" data-root-path="../../../../" data-current-crate="map_gui" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.63.0 (4b91a6ea7 2022-08-08)" ></div>
</body></html>

View File

@ -5,7 +5,7 @@
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_model::connectivity</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../map_model/index.html"><img class="rust-logo" src="../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press S to search, ? for more options…" type="search"><button type="button" id="help-button" title="help">?</button><div id="settings-menu" tabindex="-1">
<a href="../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../wheel.svg"></a></div>
</div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">map_model</a>::<wbr><a href="index.html">connectivity</a>::<wbr><a class="fn" href="#">vehicle_cost</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/map_model/pathfind/vehicles.rs.html#282-372">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn vehicle_cost(<br>&nbsp;&nbsp;&nbsp;&nbsp;dr: <a class="struct" href="../objects/road/struct.DirectedRoadID.html" title="struct map_model::objects::road::DirectedRoadID">DirectedRoadID</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;mvmnt: <a class="struct" href="../objects/movement/struct.MovementID.html" title="struct map_model::objects::movement::MovementID">MovementID</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;constraints: <a class="enum" href="../pathfind/enum.PathConstraints.html" title="enum map_model::pathfind::PathConstraints">PathConstraints</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;params: &amp;<a class="struct" href="../pathfind/struct.RoutingParams.html" title="struct map_model::pathfind::RoutingParams">RoutingParams</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;map: &amp;<a class="struct" href="../struct.Map.html" title="struct map_model::Map">Map</a><br>) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.63.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="struct" href="../../geom/duration/struct.Duration.html" title="struct geom::duration::Duration">Duration</a>&gt;</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>This returns the pathfinding cost of crossing one road and turn, in units of time. It factors
<h1 class="fqn"><span class="in-band">Function <a href="../index.html">map_model</a>::<wbr><a href="index.html">connectivity</a>::<wbr><a class="fn" href="#">vehicle_cost</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../src/map_model/pathfind/vehicles.rs.html#288-378">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn vehicle_cost(<br>&nbsp;&nbsp;&nbsp;&nbsp;dr: <a class="struct" href="../objects/road/struct.DirectedRoadID.html" title="struct map_model::objects::road::DirectedRoadID">DirectedRoadID</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;mvmnt: <a class="struct" href="../objects/movement/struct.MovementID.html" title="struct map_model::objects::movement::MovementID">MovementID</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;constraints: <a class="enum" href="../pathfind/enum.PathConstraints.html" title="enum map_model::pathfind::PathConstraints">PathConstraints</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;params: &amp;<a class="struct" href="../pathfind/struct.RoutingParams.html" title="struct map_model::pathfind::RoutingParams">RoutingParams</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;map: &amp;<a class="struct" href="../struct.Map.html" title="struct map_model::Map">Map</a><br>) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.63.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="struct" href="../../geom/duration/struct.Duration.html" title="struct geom::duration::Duration">Duration</a>&gt;</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>This returns the pathfinding cost of crossing one road and turn, in units of time. It factors
in the ideal time to cross the space and penalties for entering an access-restricted zone,
taking an unprotected turn, or going up a steep hill for some vehicle types. If this returns
<code>None</code>, then the movement isnt actually allowed.</p>

View File

@ -5,5 +5,5 @@
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_model::pathfind::vehicles</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_model/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press S to search, ? for more options…" type="search"><button type="button" id="help-button" title="help">?</button><div id="settings-menu" tabindex="-1">
<a href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div>
</div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_model</a>::<wbr><a href="../index.html">pathfind</a>::<wbr><a href="index.html">vehicles</a>::<wbr><a class="fn" href="#">make_input_graph</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_model/pathfind/vehicles.rs.html#196-276">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn make_input_graph(<br>&nbsp;&nbsp;&nbsp;&nbsp;constraints: <a class="enum" href="../enum.PathConstraints.html" title="enum map_model::pathfind::PathConstraints">PathConstraints</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;nodes: &amp;<a class="struct" href="../node_map/struct.NodeMap.html" title="struct map_model::pathfind::node_map::NodeMap">NodeMap</a>&lt;<a class="enum" href="enum.Node.html" title="enum map_model::pathfind::vehicles::Node">Node</a>&gt;, <br>&nbsp;&nbsp;&nbsp;&nbsp;uber_turns: &amp;[<a class="struct" href="../uber_turns/struct.UberTurnV2.html" title="struct map_model::pathfind::uber_turns::UberTurnV2">UberTurnV2</a>], <br>&nbsp;&nbsp;&nbsp;&nbsp;params: &amp;<a class="struct" href="../struct.RoutingParams.html" title="struct map_model::pathfind::RoutingParams">RoutingParams</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;map: &amp;<a class="struct" href="../../struct.Map.html" title="struct map_model::Map">Map</a><br>) -&gt; InputGraph</code></pre></div></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_model" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.63.0 (4b91a6ea7 2022-08-08)" ></div>
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_model</a>::<wbr><a href="../index.html">pathfind</a>::<wbr><a href="index.html">vehicles</a>::<wbr><a class="fn" href="#">make_input_graph</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_model/pathfind/vehicles.rs.html#196-282">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>fn make_input_graph(<br>&nbsp;&nbsp;&nbsp;&nbsp;constraints: <a class="enum" href="../enum.PathConstraints.html" title="enum map_model::pathfind::PathConstraints">PathConstraints</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;nodes: &amp;<a class="struct" href="../node_map/struct.NodeMap.html" title="struct map_model::pathfind::node_map::NodeMap">NodeMap</a>&lt;<a class="enum" href="enum.Node.html" title="enum map_model::pathfind::vehicles::Node">Node</a>&gt;, <br>&nbsp;&nbsp;&nbsp;&nbsp;uber_turns: &amp;[<a class="struct" href="../uber_turns/struct.UberTurnV2.html" title="struct map_model::pathfind::uber_turns::UberTurnV2">UberTurnV2</a>], <br>&nbsp;&nbsp;&nbsp;&nbsp;params: &amp;<a class="struct" href="../struct.RoutingParams.html" title="struct map_model::pathfind::RoutingParams">RoutingParams</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;map: &amp;<a class="struct" href="../../struct.Map.html" title="struct map_model::Map">Map</a><br>) -&gt; InputGraph</code></pre></div></section></div></main><div id="rustdoc-vars" data-root-path="../../../" data-current-crate="map_model" data-themes="ayu,dark,light" data-resource-suffix="" data-rustdoc-version="1.63.0 (4b91a6ea7 2022-08-08)" ></div>
</body></html>

View File

@ -5,7 +5,7 @@
</a><div class="sidebar-elems"><h2 class="location"><a href="index.html">In map_model::pathfind::vehicles</a></h2></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_model/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press S to search, ? for more options…" type="search"><button type="button" id="help-button" title="help">?</button><div id="settings-menu" tabindex="-1">
<a href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div>
</div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_model</a>::<wbr><a href="../index.html">pathfind</a>::<wbr><a href="index.html">vehicles</a>::<wbr><a class="fn" href="#">vehicle_cost</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_model/pathfind/vehicles.rs.html#282-372">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn vehicle_cost(<br>&nbsp;&nbsp;&nbsp;&nbsp;dr: <a class="struct" href="../../objects/road/struct.DirectedRoadID.html" title="struct map_model::objects::road::DirectedRoadID">DirectedRoadID</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;mvmnt: <a class="struct" href="../../objects/movement/struct.MovementID.html" title="struct map_model::objects::movement::MovementID">MovementID</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;constraints: <a class="enum" href="../enum.PathConstraints.html" title="enum map_model::pathfind::PathConstraints">PathConstraints</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;params: &amp;<a class="struct" href="../struct.RoutingParams.html" title="struct map_model::pathfind::RoutingParams">RoutingParams</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;map: &amp;<a class="struct" href="../../struct.Map.html" title="struct map_model::Map">Map</a><br>) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.63.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="struct" href="../../../geom/duration/struct.Duration.html" title="struct geom::duration::Duration">Duration</a>&gt;</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>This returns the pathfinding cost of crossing one road and turn, in units of time. It factors
<h1 class="fqn"><span class="in-band">Function <a href="../../index.html">map_model</a>::<wbr><a href="../index.html">pathfind</a>::<wbr><a href="index.html">vehicles</a>::<wbr><a class="fn" href="#">vehicle_cost</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_model/pathfind/vehicles.rs.html#288-378">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><div class="docblock item-decl"><pre class="rust fn"><code>pub fn vehicle_cost(<br>&nbsp;&nbsp;&nbsp;&nbsp;dr: <a class="struct" href="../../objects/road/struct.DirectedRoadID.html" title="struct map_model::objects::road::DirectedRoadID">DirectedRoadID</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;mvmnt: <a class="struct" href="../../objects/movement/struct.MovementID.html" title="struct map_model::objects::movement::MovementID">MovementID</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;constraints: <a class="enum" href="../enum.PathConstraints.html" title="enum map_model::pathfind::PathConstraints">PathConstraints</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;params: &amp;<a class="struct" href="../struct.RoutingParams.html" title="struct map_model::pathfind::RoutingParams">RoutingParams</a>, <br>&nbsp;&nbsp;&nbsp;&nbsp;map: &amp;<a class="struct" href="../../struct.Map.html" title="struct map_model::Map">Map</a><br>) -&gt; <a class="enum" href="https://doc.rust-lang.org/1.63.0/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="struct" href="../../../geom/duration/struct.Duration.html" title="struct geom::duration::Duration">Duration</a>&gt;</code></pre></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>This returns the pathfinding cost of crossing one road and turn, in units of time. It factors
in the ideal time to cross the space and penalties for entering an access-restricted zone,
taking an unprotected turn, or going up a steep hill for some vehicle types. If this returns
<code>None</code>, then the movement isnt actually allowed.</p>

View File

@ -5,7 +5,7 @@
</a><h2 class="location"><a href="#">Module vehicles</a></h2><div class="sidebar-elems"><section><div class="block"><ul><li><a href="#structs">Structs</a></li><li><a href="#enums">Enums</a></li><li><a href="#functions">Functions</a></li></ul></div></section></div></nav><main><div class="width-limiter"><div class="sub-container"><a class="sub-logo-container" href="../../../map_model/index.html"><img class="rust-logo" src="../../../rust-logo.svg" alt="logo"></a><nav class="sub"><form class="search-form"><div class="search-container"><span></span><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press S to search, ? for more options…" type="search"><button type="button" id="help-button" title="help">?</button><div id="settings-menu" tabindex="-1">
<a href="../../../settings.html" title="settings"><img width="22" height="22" alt="Change settings" src="../../../wheel.svg"></a></div>
</div></form></nav></div><section id="main-content" class="content"><div class="main-heading">
<h1 class="fqn"><span class="in-band">Module <a href="../../index.html">map_model</a>::<wbr><a href="../index.html">pathfind</a>::<wbr><a class="mod" href="#">vehicles</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_model/pathfind/vehicles.rs.html#1-372">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Pathfinding for cars, bikes, buses, and trains using contraction hierarchies</p>
<h1 class="fqn"><span class="in-band">Module <a href="../../index.html">map_model</a>::<wbr><a href="../index.html">pathfind</a>::<wbr><a class="mod" href="#">vehicles</a><button id="copy-path" onclick="copy_path(this)" title="Copy item path to clipboard"><img src="../../../clipboard.svg" width="19" height="18" alt="Copy item path"></button></span></h1><span class="out-of-band"><a class="srclink" href="../../../src/map_model/pathfind/vehicles.rs.html#1-378">source</a> · <a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class="inner">&#x2212;</span>]</a></span></div><details class="rustdoc-toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Pathfinding for cars, bikes, buses, and trains using contraction hierarchies</p>
</div></details><h2 id="structs" class="small-section-header"><a href="#structs">Structs</a></h2>
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="struct" href="struct.VehiclePathfinder.html" title="map_model::pathfind::vehicles::VehiclePathfinder struct">VehiclePathfinder</a></div><div class="item-right docblock-short"></div></div></div><h2 id="enums" class="small-section-header"><a href="#enums">Enums</a></h2>
<div class="item-table"><div class="item-row"><div class="item-left module-item"><a class="enum" href="enum.Node.html" title="map_model::pathfind::vehicles::Node enum">Node</a></div><div class="item-right docblock-short"></div></div></div><h2 id="functions" class="small-section-header"><a href="#functions">Functions</a></h2>

View File

@ -180,7 +180,7 @@
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">RUSTDOC_VERSION</span>: <span class="kw-2">&amp;</span><span class="ident">str</span> <span class="op">=</span> <span class="string">r&quot;rustdoc 1.63.0 (4b91a6ea7 2022-08-08)&quot;</span>;
<span class="attribute">#[<span class="ident">doc</span><span class="op">=</span><span class="string">r#&quot;The build time in RFC2822, UTC.&quot;#</span>]</span>
<span class="attribute">#[<span class="ident">allow</span>(<span class="ident">dead_code</span>)]</span>
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">BUILT_TIME_UTC</span>: <span class="kw-2">&amp;</span><span class="ident">str</span> <span class="op">=</span> <span class="string">r&quot;Fri, 26 Aug 2022 13:31:12 +0000&quot;</span>;
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">BUILT_TIME_UTC</span>: <span class="kw-2">&amp;</span><span class="ident">str</span> <span class="op">=</span> <span class="string">r&quot;Fri, 26 Aug 2022 16:02:24 +0000&quot;</span>;
<span class="attribute">#[<span class="ident">doc</span><span class="op">=</span><span class="string">r#&quot;The target architecture, given by `CARGO_CFG_TARGET_ARCH`.&quot;#</span>]</span>
<span class="attribute">#[<span class="ident">allow</span>(<span class="ident">dead_code</span>)]</span>
<span class="kw">pub</span> <span class="kw">const</span> <span class="ident">CFG_TARGET_ARCH</span>: <span class="kw-2">&amp;</span><span class="ident">str</span> <span class="op">=</span> <span class="string">r&quot;x86_64&quot;</span>;

View File

@ -376,6 +376,12 @@
<span id="370">370</span>
<span id="371">371</span>
<span id="372">372</span>
<span id="373">373</span>
<span id="374">374</span>
<span id="375">375</span>
<span id="376">376</span>
<span id="377">377</span>
<span id="378">378</span>
</pre><pre class="rust"><code><span class="doccomment">//! Pathfinding for cars, bikes, buses, and trains using contraction hierarchies</span>
<span class="kw">use</span> <span class="ident">std::collections::HashMap</span>;
@ -622,15 +628,20 @@
<span class="kw">let</span> <span class="ident">ut</span> <span class="op">=</span> <span class="kw-2">&amp;</span><span class="ident">uber_turns</span>[<span class="kw-2">*</span><span class="ident">idx</span>];
<span class="kw">let</span> <span class="kw-2">mut</span> <span class="ident">sum_cost</span> <span class="op">=</span> <span class="ident">Duration::ZERO</span>;
<span class="kw">let</span> <span class="kw-2">mut</span> <span class="ident">ok</span> <span class="op">=</span> <span class="bool-val">true</span>;
<span class="kw">for</span> <span class="ident">mvmnt</span> <span class="kw">in</span> <span class="kw-2">&amp;</span><span class="ident">ut</span>.<span class="ident">path</span> {
<span class="kw">if</span> <span class="kw">let</span> <span class="prelude-val">Some</span>(<span class="ident">cost</span>) <span class="op">=</span>
<span class="ident">vehicle_cost</span>(<span class="ident">mvmnt</span>.<span class="ident">from</span>, <span class="kw-2">*</span><span class="ident">mvmnt</span>, <span class="ident">constraints</span>, <span class="ident">params</span>, <span class="ident">map</span>)
{
<span class="ident">sum_cost</span> <span class="op">+</span><span class="op">=</span> <span class="ident">cost</span>;
} <span class="kw">else</span> {
<span class="macro">error!</span>(<span class="string">&quot;A vehicle isn&#39;t allowed to cross {:?}, but it&#39;s part of an uber-turn and happening anyway&quot;</span>, <span class="ident">mvmnt</span>);
<span class="comment">// A vehicle isn&#39;t allowed to do one of the steps inside the</span>
<span class="comment">// uber-turn. So just toss out the entire uber-turn from the graph.</span>
<span class="ident">ok</span> <span class="op">=</span> <span class="bool-val">false</span>;
<span class="kw">break</span>;
}
}
<span class="kw">if</span> <span class="ident">ok</span> {
<span class="ident">input_graph</span>.<span class="ident">add_edge</span>(
<span class="ident">from</span>,
<span class="ident">nodes</span>.<span class="ident">get</span>(<span class="ident">Node::UberTurn</span>(<span class="kw-2">*</span><span class="ident">idx</span>)),
@ -647,6 +658,7 @@
}
}
}
}
<span class="ident">nodes</span>.<span class="ident">guarantee_node_ordering</span>(<span class="kw-2">&amp;mut</span> <span class="ident">input_graph</span>);
<span class="ident">input_graph</span>.<span class="ident">freeze</span>();