<!DOCTYPE html><htmllang="en"><head><metacharset="utf-8"><metaname="viewport"content="width=device-width, initial-scale=1.0"><metaname="generator"content="rustdoc"><metaname="description"content="A builder to create an iterator for recursively walking a directory."><title>WalkDir in walkdir - Rust</title><linkrel="preload"as="font"type="font/woff2"crossoriginhref="../static.files/SourceSerif4-Regular-46f98efaafac5295.ttf.woff2"><linkrel="preload"as="font"type="font/woff2"crossoriginhref="../static.files/FiraSans-Regular-018c141bf0843ffd.woff2"><linkrel="preload"as="font"type="font/woff2"crossoriginhref="../static.files/FiraSans-Medium-8f9a781e4970d388.woff2"><linkrel="preload"as="font"type="font/woff2"crossoriginhref="../static.files/SourceCodePro-Regular-562dcc5011b6de7d.ttf.woff2"><linkrel="preload"as="font"type="font/woff2"crossoriginhref="../static.files/SourceCodePro-Semibold-d899c5a5c4aeb14a.ttf.woff2"><linkrel="stylesheet"href="../static.files/normalize-76eba96aa4d2e634.css"><linkrel="stylesheet"href="../static.files/rustdoc-5bc39a1768837dd0.css"><metaname="rustdoc-vars"data-root-path="../"data-static-root-path="../static.files/"data-current-crate="walkdir"data-themes=""data-resource-suffix=""data-rustdoc-version="1.77.2 (25ef9e3d8 2024-04-09)"data-channel="1.77.2"data-search-js="search-dd67cee4cfa65049.js"data-settings-js="settings-4313503d2e1961c2.js"><scriptsrc="../static.files/storage-4c98445ec4002617.js"></script><scriptdefersrc="sidebar-items.js"></script><scriptdefersrc="../static.files/main-48f368f3872407c8.js"></script><noscript><linkrel="stylesheet"href="../static.files/noscript-04d5337699b92874.css"></noscript><linkrel="alternate icon"type="image/png"href="../static.files/favicon-16x16-8b506e7a72182f1c.png"><linkrel="alternate icon"type="image/png"href="../static.files/favicon-32x32-422f7d1d52889060.png"><linkrel="icon"type="image/svg+xml"href="../static.files/favicon-2c020d218678b618.svg"></head><bodyclass="rustdoc struct"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><navclass="mobile-topbar"><buttonclass="sidebar-menu-toggle"title="show sidebar"></button></nav><navclass="sidebar"><divclass="sidebar-crate"><h2><ahref="../walkdir/index.html">walkdir</a><spanclass="version">2.5.0</span></h2></div><h2class="location"><ahref="#">WalkDir</a></h2><divclass="sidebar-elems"><section><h3><ahref="#implementations">Methods</a></h3><ulclass="block method"><li><ahref="#method.contents_first">contents_first</a></li><li><ahref="#method.follow_links">follow_links</a></li><li><ahref="#method.follow_root_links">follow_root_links</a></li><li><ahref="#method.max_depth">max_depth</a></li><li><ahref="#method.max_open">max_open</a></li><li><ahref="#method.min_depth">min_depth</a></li><li><ahref="#method.new">new</a></li><li><ahref="#method.same_file_system">same_file_system</a></li><li><ahref="#method.sort_by">sort_by</a></li><li><ahref="#method.sort_by_file_name">sort_by_file_name</a></li><li><ahref="#method.sort_by_key">sort_by_key</a></li></ul><h3><ahref="#trait-implementations">Trait Implementations</a></h3><ulclass="block trait-implementation"><li><ahref="#impl-Debug-for-WalkDir">Debug</a></li><li><ahref="#impl-IntoIterator-for-WalkDir">IntoIterator</a></li></ul><h3><ahref="#synthetic-implementations">Auto Trait Implementations</a></h3><ulclass="block synthetic-implementation"><li><ahref="#impl-RefUnwindSafe-for-WalkDir">!RefUnwindSafe</a></li><li><ahref="#impl-UnwindSafe-for-WalkDir">!UnwindSafe</a></li><li><ahref="#impl-Send-for-WalkDir">Send</a></li><li><ahref="#impl-Sync-for-WalkDir">Sync</a></li><li><ahref="#impl-Unpin-for-WalkDir">Unpin</a></li></ul><h3><ahref="#blanket-implementations">Blanket Implementations</a></h3><ulclass="block blanket-implementation"><li><ahref="#impl-Any-for-T">Any</a></li><li><ahref="#impl-Borrow%3CT%3E-for-T">Borrow<T></a></li><li><ahref="#impl-BorrowMut%3CT%3E-for-T">BorrowMut<T></a></l
<main><divclass="width-limiter"><navclass="sub"><formclass="search-form"><span></span><divid="sidebar-button"tabindex="-1"><ahref="../walkdir/all.html"title="show sidebar"></a></div><inputclass="search-input"name="search"aria-label="Run search in the documentation"autocomplete="off"spellcheck="false"placeholder="Click or press ‘S’ to search, ‘?’ for more options…"type="search"><divid="help-button"tabindex="-1"><ahref="../help.html"title="help">?</a></div><divid="settings-menu"tabindex="-1"><ahref="../settings.html"title="settings"><imgwidth="22"height="22"alt="Change settings"src="../static.files/wheel-7b819b6101059cd0.svg"></a></div></form></nav><sectionid="main-content"class="content"><divclass="main-heading"><h1>Struct <ahref="index.html">walkdir</a>::<wbr><aclass="struct"href="#">WalkDir</a><buttonid="copy-path"title="Copy item path to clipboard"><imgsrc="../static.files/clipboard-7571035ce49a181d.svg"width="19"height="18"alt="Copy item path"></button></h1><spanclass="out-of-band"><aclass="src"href="../src/walkdir/lib.rs.html#234-237">source</a> · <buttonid="toggle-all-docs"title="collapse all docs">[<span>−</span>]</button></span></div><preclass="rust item-decl"><code>pub struct WalkDir { <spanclass="comment">/* private fields */</span> }</code></pre><detailsclass="toggle top-doc"open><summaryclass="hideme"><span>Expand description</span></summary><divclass="docblock"><p>A builder to create an iterator for recursively walking a directory.</p>
<p>Results are returned in depth first fashion, with directories yielded
before their contents. If <ahref="struct.WalkDir.html#method.contents_first"><code>contents_first</code></a> is true, contents are yielded
before their directories. The order is unspecified but if <ahref="struct.WalkDir.html#method.sort_by"><code>sort_by</code></a> is
given, directory entries are sorted according to this function. Directory
entries <code>.</code> and <code>..</code> are always omitted.</p>
<p>If an error occurs at any point during iteration, then it is returned in
place of its corresponding directory entry and iteration continues as
normal. If an error occurs while opening a directory for reading, then it
is not descended into (but the error is still yielded by the iterator).
Iteration may be stopped at any time. When the iterator is destroyed, all
<p>This type implements <ahref="https://doc.rust-lang.org/stable/std/iter/trait.IntoIterator.html"><code>IntoIterator</code></a> so that it may be used as the subject
of a <code>for</code> loop. You may need to call <ahref="https://doc.rust-lang.org/nightly/core/iter/trait.IntoIterator.html#tymethod.into_iter"><code>into_iter</code></a> explicitly if you want
to use iterator adapters such as <ahref="struct.IntoIter.html#method.filter_entry"><code>filter_entry</code></a>.</p>
<p>Idiomatic use of this type should use method chaining to set desired
options. For example, this only shows entries with a depth of <code>1</code>, <code>2</code> or
<code>3</code> (relative to <code>foo</code>):</p>
</div></details><h2id="implementations"class="section-header">Implementations<ahref="#implementations"class="anchor">§</a></h2><divid="implementations-list"><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-WalkDir"class="impl"><aclass="src rightside"href="../src/walkdir/lib.rs.html#281-534">source</a><ahref="#impl-WalkDir"class="anchor">§</a><h3class="code-header">impl <aclass="struct"href="struct.WalkDir.html"title="struct walkdir::WalkDir">WalkDir</a></h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.new"class="method"><aclass="src rightside"href="../src/walkdir/lib.rs.html#289-303">source</a><h4class="code-header">pub fn <ahref="#method.new"class="fn">new</a><P: <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.AsRef.html"title="trait core::convert::AsRef">AsRef</a><<aclass="struct"href="https://doc.rust-lang.org/1.77.2/std/path/struct.Path.html"title="struct std::path::Path">Path</a>>>(root: P) -> Self</h4></section></summary><divclass="docblock"><p>Create a builder for a recursive directory iterator starting at the
</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.min_depth"class="method"><aclass="src rightside"href="../src/walkdir/lib.rs.html#310-316">source</a><h4class="code-header">pub fn <ahref="#method.min_depth"class="fn">min_depth</a>(self, depth: <aclass="primitive"href="https://doc.rust-lang.org/1.77.2/std/primitive.usize.html">usize</a>) -> Self</h4></section></summary><divclass="docblock"><p>Set the minimum depth of entries yielded by the iterator.</p>
</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.max_depth"class="method"><aclass="src rightside"href="../src/walkdir/lib.rs.html#327-333">source</a><h4class="code-header">pub fn <ahref="#method.max_depth"class="fn">max_depth</a>(self, depth: <aclass="primitive"href="https://doc.rust-lang.org/1.77.2/std/primitive.usize.html">usize</a>) -> Self</h4></section></summary><divclass="docblock"><p>Set the maximum depth of entries yield by the iterator.</p>
</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.follow_root_links"class="method"><aclass="src rightside"href="../src/walkdir/lib.rs.html#365-368">source</a><h4class="code-header">pub fn <ahref="#method.follow_root_links"class="fn">follow_root_links</a>(self, yes: <aclass="primitive"href="https://doc.rust-lang.org/1.77.2/std/primitive.bool.html">bool</a>) -> Self</h4></section></summary><divclass="docblock"><p>Follow symbolic links if these are the root of the traversal.
</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.max_open"class="method"><aclass="src rightside"href="../src/walkdir/lib.rs.html#395-401">source</a><h4class="code-header">pub fn <ahref="#method.max_open"class="fn">max_open</a>(self, n: <aclass="primitive"href="https://doc.rust-lang.org/1.77.2/std/primitive.usize.html">usize</a>) -> Self</h4></section></summary><divclass="docblock"><p>Set the maximum number of simultaneously open file descriptors used
F: <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/ops/function/trait.FnMut.html"title="trait core::ops::function::FnMut">FnMut</a>(&<aclass="struct"href="struct.DirEntry.html"title="struct walkdir::DirEntry">DirEntry</a>, &<aclass="struct"href="struct.DirEntry.html"title="struct walkdir::DirEntry">DirEntry</a>) -><aclass="enum"href="https://doc.rust-lang.org/1.77.2/core/cmp/enum.Ordering.html"title="enum core::cmp::Ordering">Ordering</a> + <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/marker/trait.Send.html"title="trait core::marker::Send">Send</a> + <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/marker/trait.Sync.html"title="trait core::marker::Sync">Sync</a> + 'static,</div></h4></section></summary><divclass="docblock"><p>Set a function for sorting directory entries with a comparator
K: <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/cmp/trait.Ord.html"title="trait core::cmp::Ord">Ord</a>,</div></h4></section></summary><divclass="docblock"><p>Set a function for sorting directory entries with a key extraction
</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.contents_first"class="method"><aclass="src rightside"href="../src/walkdir/lib.rs.html#517-520">source</a><h4class="code-header">pub fn <ahref="#method.contents_first"class="fn">contents_first</a>(self, yes: <aclass="primitive"href="https://doc.rust-lang.org/1.77.2/std/primitive.bool.html">bool</a>) -> Self</h4></section></summary><divclass="docblock"><p>Yield a directory’s contents before the directory itself. By default,
</div></details></div></details></div><h2id="trait-implementations"class="section-header">Trait Implementations<ahref="#trait-implementations"class="anchor">§</a></h2><divid="trait-implementations-list"><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-Debug-for-WalkDir"class="impl"><aclass="src rightside"href="../src/walkdir/lib.rs.html#233">source</a><ahref="#impl-Debug-for-WalkDir"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/fmt/trait.Debug.html"title="trait core::fmt::Debug">Debug</a> for <aclass="struct"href="struct.WalkDir.html"title="struct walkdir::WalkDir">WalkDir</a></h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.fmt"class="method trait-impl"><aclass="src rightside"href="../src/walkdir/lib.rs.html#233">source</a><ahref="#method.fmt"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.77.2/core/fmt/trait.Debug.html#tymethod.fmt"class="fn">fmt</a>(&self, f: &mut <aclass="struct"href="https://doc.rust-lang.org/1.77.2/core/fmt/struct.Formatter.html"title="struct core::fmt::Formatter">Formatter</a><'_>) -><aclass="type"href="https://doc.rust-lang.org/1.77.2/core/fmt/type.Result.html"title="type core::fmt::Result">Result</a></h4></section></summary><divclass='docblock'>Formats the value using the given formatter. <ahref="https://doc.rust-lang.org/1.77.2/core/fmt/trait.Debug.html#tymethod.fmt">Read more</a></div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-IntoIterator-for-WalkDir"class="impl"><aclass="src rightside"href="../src/walkdir/lib.rs.html#536-552">source</a><ahref="#impl-IntoIterator-for-WalkDir"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/iter/traits/collect/trait.IntoIterator.html"title="trait core::iter::traits::collect::IntoIterator">IntoIterator</a> for <aclass="struct"href="struct.WalkDir.html"title="struct walkdir::WalkDir">WalkDir</a></h3></section></summary><divclass="impl-items"><detailsclass="toggle"open><summary><sectionid="associatedtype.Item"class="associatedtype trait-impl"><ahref="#associatedtype.Item"class="anchor">§</a><h4class="code-header">type <ahref="https://doc.rust-lang.org/1.77.2/core/iter/traits/collect/trait.IntoIterator.html#associatedtype.Item"class="associatedtype">Item</a> = <aclass="enum"href="https://doc.rust-lang.org/1.77.2/core/result/enum.Result.html"title="enum core::result::Result">Result</a><<aclass="struct"href="struct.DirEntry.html"title="struct walkdir::DirEntry">DirEntry</a>, <aclass="struct"href="struct.Error.html"title="struct walkdir::Error">Error</a>></h4></section></summary><divclass='docblock'>The type of the elements being iterated over.</div></details><detailsclass="toggle"open><summary><sectionid="associatedtype.IntoIter"class="associatedtype trait-impl"><ahref="#associatedtype.IntoIter"class="anchor">§</a><h4class="code-header">type <ahref="https://doc.rust-lang.org/1.77.2/core/iter/traits/collect/trait.IntoIterator.html#associatedtype.IntoIter"class="associatedtype">IntoIter</a> = <aclass="struct"href="struct.IntoIter.html"title="struct walkdir::IntoIter">IntoIter</a></h4></section></summary><divclass='docblock'>Which kind of iterator are we turning this into?</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.into_iter"class="method trait-impl"><aclass="src rightside"href="../src/walkdir/lib.rs.html#540-551">source</a><ahref="#method.into_iter"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.77.2/core/iter/traits/collect/trait.IntoIterator.html#tymethod.into_iter"class="fn">into_iter</a>(self) -><aclass="struct"href="struct.IntoIter.html"title="struct walkdir::IntoIter">IntoIter</a><ahref="#"class="tooltip"data-notable-ty="IntoIter">ⓘ</a></h4></section></
T: 'static + ?<aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/marker/trait.Sized.html"title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.type_id"class="method trait-impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/any.rs.html#141">source</a><ahref="#method.type_id"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.77.2/core/any/trait.Any.html#tymethod.type_id"class="fn">type_id</a>(&self) -><aclass="struct"href="https://doc.rust-lang.org/1.77.2/core/any/struct.TypeId.html"title="struct core::any::TypeId">TypeId</a></h4></section></summary><divclass='docblock'>Gets the <code>TypeId</code> of <code>self</code>. <ahref="https://doc.rust-lang.org/1.77.2/core/any/trait.Any.html#tymethod.type_id">Read more</a></div></details></div></details><detailsclass="toggle implementors-toggle"><summary><sectionid="impl-Borrow%3CT%3E-for-T"class="impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/borrow.rs.html#208">source</a><ahref="#impl-Borrow%3CT%3E-for-T"class="anchor">§</a><h3class="code-header">impl<T><aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/borrow/trait.Borrow.html"title="trait core::borrow::Borrow">Borrow</a><T> for T<divclass="where">where
T: ?<aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/marker/trait.Sized.html"title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.borrow"class="method trait-impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/borrow.rs.html#210">source</a><ahref="#method.borrow"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.77.2/core/borrow/trait.Borrow.html#tymethod.borrow"class="fn">borrow</a>(&self) -><aclass="primitive"href="https://doc.rust-lang.org/1.77.2/std/primitive.reference.html">&T</a></h4></section></summary><divclass='docblock'>Immutably borrows from an owned value. <ahref="https://doc.rust-lang.org/1.77.2/core/borrow/trait.Borrow.html#tymethod.borrow">Read more</a></div></details></div></details><detailsclass="toggle implementors-toggle"><summary><sectionid="impl-BorrowMut%3CT%3E-for-T"class="impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/borrow.rs.html#216">source</a><ahref="#impl-BorrowMut%3CT%3E-for-T"class="anchor">§</a><h3class="code-header">impl<T><aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/borrow/trait.BorrowMut.html"title="trait core::borrow::BorrowMut">BorrowMut</a><T> for T<divclass="where">where
T: ?<aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/marker/trait.Sized.html"title="trait core::marker::Sized">Sized</a>,</div></h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.borrow_mut"class="method trait-impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/borrow.rs.html#217">source</a><ahref="#method.borrow_mut"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.77.2/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut"class="fn">borrow_mut</a>(&mut self) -><aclass="primitive"href="https://doc.rust-lang.org/1.77.2/std/primitive.reference.html">&mut T</a></h4></section></summary><divclass='docblock'>Mutably borrows from an owned value. <ahref="https://doc.rust-lang.org/1.77.2/core/borrow/trait.BorrowMut.html#tymethod.borrow_mut">Read more</a></div></details></div></details><detailsclass="toggle implementors-toggle"><summary><sectionid="impl-From%3CT%3E-for-T"class="impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/convert/mod.rs.html#764">source</a><ahref="#impl-From%3CT%3E-for-T"class="anchor">§</a><h3class="code-header">impl<T><aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.From.html"title="trait core::convert::From">From</a><T> for T</h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from"class="method trait-impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/convert/mod.rs.html#767">source</a><ahref="#method.from"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.77.2/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(t: T) -> T</h4></section></summary><divclass="docblock"><p>Returns the argument unchanged.</p>
</div></details></div></details><detailsclass="toggle implementors-toggle"><summary><sectionid="impl-Into%3CU%3E-for-T"class="impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/convert/mod.rs.html#747-749">source</a><ahref="#impl-Into%3CU%3E-for-T"class="anchor">§</a><h3class="code-header">impl<T, U><aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.Into.html"title="trait core::convert::Into">Into</a><U> for T<divclass="where">where
<code><ahref="https://doc.rust-lang.org/1.77.2/core/convert/trait.From.html"title="trait core::convert::From">From</a><T> for U</code> chooses to do.</p>
</div></details></div></details><detailsclass="toggle implementors-toggle"><summary><sectionid="impl-TryFrom%3CU%3E-for-T"class="impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/convert/mod.rs.html#804-806">source</a><ahref="#impl-TryFrom%3CU%3E-for-T"class="anchor">§</a><h3class="code-header">impl<T, U><aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html"title="trait core::convert::TryFrom">TryFrom</a><U> for T<divclass="where">where
U: <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.Into.html"title="trait core::convert::Into">Into</a><T>,</div></h3></section></summary><divclass="impl-items"><detailsclass="toggle"open><summary><sectionid="associatedtype.Error-1"class="associatedtype trait-impl"><ahref="#associatedtype.Error-1"class="anchor">§</a><h4class="code-header">type <ahref="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html#associatedtype.Error"class="associatedtype">Error</a> = <aclass="enum"href="https://doc.rust-lang.org/1.77.2/core/convert/enum.Infallible.html"title="enum core::convert::Infallible">Infallible</a></h4></section></summary><divclass='docblock'>The type returned in the event of a conversion error.</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.try_from"class="method trait-impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/convert/mod.rs.html#811">source</a><ahref="#method.try_from"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html#tymethod.try_from"class="fn">try_from</a>(value: U) -><aclass="enum"href="https://doc.rust-lang.org/1.77.2/core/result/enum.Result.html"title="enum core::result::Result">Result</a><T, <T as <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html"title="trait core::convert::TryFrom">TryFrom</a><U>>::<aclass="associatedtype"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html#associatedtype.Error"title="type core::convert::TryFrom::Error">Error</a>></h4></section></summary><divclass='docblock'>Performs the conversion.</div></details></div></details><detailsclass="toggle implementors-toggle"><summary><sectionid="impl-TryInto%3CU%3E-for-T"class="impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/convert/mod.rs.html#789-791">source</a><ahref="#impl-TryInto%3CU%3E-for-T"class="anchor">§</a><h3class="code-header">impl<T, U><aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryInto.html"title="trait core::convert::TryInto">TryInto</a><U> for T<divclass="where">where
U: <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html"title="trait core::convert::TryFrom">TryFrom</a><T>,</div></h3></section></summary><divclass="impl-items"><detailsclass="toggle"open><summary><sectionid="associatedtype.Error"class="associatedtype trait-impl"><ahref="#associatedtype.Error"class="anchor">§</a><h4class="code-header">type <ahref="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryInto.html#associatedtype.Error"class="associatedtype">Error</a> = <U as <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html"title="trait core::convert::TryFrom">TryFrom</a><T>>::<aclass="associatedtype"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html#associatedtype.Error"title="type core::convert::TryFrom::Error">Error</a></h4></section></summary><divclass='docblock'>The type returned in the event of a conversion error.</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.try_into"class="method trait-impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.77.2/src/core/convert/mod.rs.html#796">source</a><ahref="#method.try_into"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryInto.html#tymethod.try_into"class="fn">try_into</a>(self) -><aclass="enum"href="https://doc.rust-lang.org/1.77.2/core/result/enum.Result.html"title="enum core::result::Result">Result</a><U, <U as <aclass="trait"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html"title="trait core::convert::TryFrom">TryFrom</a><T>>::<aclass="associatedtype"href="https://doc.rust-lang.org/1.77.2/core/convert/trait.TryFrom.html#associatedtype.Error"title="type core::convert::TryFrom::Error">Error</a>></h4></section></summary><divclass='docblock'>Performs the conversion.</div></details></div></details></div><scripttype="text/json"id="notable-traits-data">{"IntoIter":"<h3>Notable traits for <code><a class=\"struct\" href=\"struct.IntoIter.html\" title=\"struct walkdir::IntoIter\">IntoIter</a></code></h3><pre><code><div class=\"where\">impl <a class=\"trait\" href=\"https://doc.rust-lang.org/1.77.2/core/iter/traits/iterator/trait.Iterator.html\" title=\"trait core::iter::traits::iterator::Iterator\">Iterator</a> for <a class=\"struct\" href=\"struct.IntoIter.html\" title=\"struct walkdir::IntoIter\">IntoIter</a></div><div class=\"where\"> type <a href=\"https://doc.rust-lang.org/1.77.2/core/iter/traits/iterator/trait.Iterator.html#associatedtype.Item\" class=\"associatedtype\">Item</a> = <a class=\"type\" href=\"type.Result.html\" title=\"type walkdir::Result\">Result</a><<a class=\"struct\" href=\"struct.DirEntry.html\" title=\"struct walkdir::DirEntry\">DirEntry</a>>;</div>"}</script></section></div></main></body></html>