<main><divclass="width-limiter"><navclass="sub"><formclass="search-form"><span></span><divid="sidebar-button"tabindex="-1"><ahref="../../clap/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">clap</a>::<wbr><ahref="index.html">builder</a>::<wbr><aclass="struct"href="#">ValueParser</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/clap_builder/builder/value_parser.rs.html#63">source</a> · <buttonid="toggle-all-docs"title="collapse all docs">[<span>−</span>]</button></span></div><preclass="rust item-decl"><code>pub struct ValueParser(<spanclass="comment">/* private fields */</span>);</code></pre><detailsclass="toggle top-doc"open><summaryclass="hideme"><span>Expand description</span></summary><divclass="docblock"><p>Parse/validate argument values</p>
<p>Specified with <ahref="../struct.Arg.html#method.value_parser"title="method clap::Arg::value_parser"><code>Arg::value_parser</code></a>.</p>
<p><code>ValueParser</code> defines how to convert a raw argument value into a validated and typed value for
use within an application.</p>
<p>See</p>
<ul>
<li><ahref="../macro.value_parser.html"title="macro clap::value_parser"><code>value_parser!</code></a> for automatically selecting an implementation for a given type</li>
<li><ahref="struct.ValueParser.html#method.new"title="associated function clap::builder::ValueParser::new"><code>ValueParser::new</code></a> for additional <ahref="trait.TypedValueParser.html"title="trait clap::builder::TypedValueParser"><code>TypedValueParser</code></a> that can be used</li>
<li><ahref="struct.EnumValueParser.html"title="struct clap::builder::EnumValueParser"><code>EnumValueParser</code></a> and <ahref="struct.PossibleValuesParser.html"title="struct clap::builder::PossibleValuesParser"><code>PossibleValuesParser</code></a> for static enumerated values</li>
<li><ahref="struct.BoolishValueParser.html"title="struct clap::builder::BoolishValueParser"><code>BoolishValueParser</code></a> and <ahref="struct.FalseyValueParser.html"title="struct clap::builder::FalseyValueParser"><code>FalseyValueParser</code></a> for alternative <code>bool</code> implementations</li>
<li><ahref="struct.RangedI64ValueParser.html"title="struct clap::builder::RangedI64ValueParser"><code>RangedI64ValueParser</code></a> and <ahref="struct.RangedU64ValueParser.html"title="struct clap::builder::RangedU64ValueParser"><code>RangedU64ValueParser</code></a></li>
<li><ahref="struct.BoolishValueParser.html"title="struct clap::builder::BoolishValueParser"><code>BoolishValueParser</code></a> for different human readable bool representations</li>
<li><ahref="struct.FalseyValueParser.html"title="struct clap::builder::FalseyValueParser"><code>FalseyValueParser</code></a> for assuming non-false is true</li>
) -><aclass="enum"href="https://doc.rust-lang.org/1.76.0/core/option/enum.Option.html"title="enum core::option::Option">Option</a><<aclass="struct"href="https://doc.rust-lang.org/1.76.0/alloc/boxed/struct.Box.html"title="struct alloc::boxed::Box">Box</a><dyn <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/iter/traits/iterator/trait.Iterator.html"title="trait core::iter::traits::iterator::Iterator">Iterator</a><Item = <aclass="struct"href="struct.PossibleValue.html"title="struct clap::builder::PossibleValue">PossibleValue</a>> + '_>></h4></section></summary><divclass="docblock"><p>Reflect on enumerated value properties</p>
<p>Error checking should not be done with this; it is mostly targeted at user-facing
applications like errors and completion.</p>
</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-Clone-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#578">source</a><ahref="#impl-Clone-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html"title="trait core::clone::Clone">Clone</a> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.clone"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#579">source</a><ahref="#method.clone"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html#tymethod.clone"class="fn">clone</a>(&self) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Returns a copy of the value. <ahref="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html#tymethod.clone">Read more</a></div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.clone_from"class="method trait-impl"><spanclass="rightside"><spanclass="since"title="Stable since Rust version 1.0.0">1.0.0</span> · <aclass="src"href="https://doc.rust-lang.org/1.76.0/src/core/clone.rs.html#169">source</a></span><ahref="#method.clone_from"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html#method.clone_from"class="fn">clone_from</a>(&mut self, source: <aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&Self</a>)</h4></section></summary><divclass='docblock'>Performs copy-assignment from <code>source</code>. <ahref="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html#method.clone_from">Read more</a></div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-Debug-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#566">source</a><ahref="#impl-Debug-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/fmt/trait.Debug.html"title="trait core::fmt::Debug">Debug</a> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</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/clap_builder/builder/value_parser.rs.html#567">source</a><ahref="#method.fmt"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/fmt/trait.Debug.html#tymethod.fmt"class="fn">fmt</a>(&self, f: &mut <aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/fmt/struct.Formatter.html"title="struct core::fmt::Formatter">Formatter</a><'_>) -><aclass="enum"href="https://doc.rust-lang.org/1.76.0/core/result/enum.Result.html"title="enum core::result::Result">Result</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.unit.html">()</a>, <aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/fmt/struct.Error.html"title="struct core::fmt::Error">Error</a>></h4></section></summary><divclass='docblock'>Formats the value using the given formatter. <ahref="https://doc.rust-lang.org/1.76.0/core/fmt/trait.Debug.html#tymethod.fmt">Read more</a></div></details></div></details><detailsclass="toggleimplementors-to
P: <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.Into.html"title="trait core::convert::Into">Into</a><<aclass="struct"href="struct.PossibleValue.html"title="struct clap::builder::PossibleValue">PossibleValue</a>>,</div></h3></section></summary><divclass="docblock"><p>Create a <ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a> with <ahref="struct.PossibleValuesParser.html"title="struct clap::builder::PossibleValuesParser"><code>PossibleValuesParser</code></a></p>
<p>See <ahref="struct.PossibleValuesParser.html"title="struct clap::builder::PossibleValuesParser"><code>PossibleValuesParser</code></a> for more flexibility in creating the
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from-5"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#524">source</a><ahref="#method.from-5"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(values: <aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.array.html">[P; C]</a>) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-From%3CP%3E-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#294-296">source</a><ahref="#impl-From%3CP%3E-for-ValueParser"class="anchor">§</a><h3class="code-header">impl<P><aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html"title="trait core::convert::From">From</a><P> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a><divclass="where">where
P: <aclass="trait"href="trait.TypedValueParser.html"title="trait clap::builder::TypedValueParser">TypedValueParser</a> + <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Send.html"title="trait core::marker::Send">Send</a> + <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sync.html"title="trait core::marker::Sync">Sync</a> + 'static,</div></h3></section></summary><divclass="docblock"><p>Convert a <ahref="trait.TypedValueParser.html"title="trait clap::builder::TypedValueParser"><code>TypedValueParser</code></a> to <ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a></p>
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from-3"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#298">source</a><ahref="#method.from-3"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(p: P) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-From%3CRange%3Ci64%3E%3E-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#333">source</a><ahref="#impl-From%3CRange%3Ci64%3E%3E-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html"title="trait core::convert::From">From</a><<aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.Range.html"title="struct core::ops::range::Range">Range</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section></summary><divclass="docblock"><p>Create an <code>i64</code><ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a> from a <code>N..M</code> range</p>
<p>See <ahref="struct.RangedI64ValueParser.html"title="struct clap::builder::RangedI64ValueParser"><code>RangedI64ValueParser</code></a> for more control over the output type.</p>
<p>See also <ahref="struct.RangedU64ValueParser.html"title="struct clap::builder::RangedU64ValueParser"><code>RangedU64ValueParser</code></a></p>
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#334">source</a><ahref="#method.from"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(value: <aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.Range.html"title="struct core::ops::range::Range">Range</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-From%3CRangeFrom%3Ci64%3E%3E-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#395">source</a><ahref="#impl-From%3CRangeFrom%3Ci64%3E%3E-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html"title="trait core::convert::From">From</a><<aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeFrom.html"title="struct core::ops::range::RangeFrom">RangeFrom</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section></summary><divclass="docblock"><p>Create an <code>i64</code><ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a> from a <code>N..</code> range</p>
<p>See <ahref="struct.RangedI64ValueParser.html"title="struct clap::builder::RangedI64ValueParser"><code>RangedI64ValueParser</code></a> for more control over the output type.</p>
<p>See also <ahref="struct.RangedU64ValueParser.html"title="struct clap::builder::RangedU64ValueParser"><code>RangedU64ValueParser</code></a></p>
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from-4"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#396">source</a><ahref="#method.from-4"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(value: <aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeFrom.html"title="struct core::ops::range::RangeFrom">RangeFrom</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-From%3CRangeFull%3E-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#488">source</a><ahref="#impl-From%3CRangeFull%3E-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html"title="trait core::convert::From">From</a><<aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeFull.html"title="struct core::ops::range::RangeFull">RangeFull</a>> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section></summary><divclass="docblock"><p>Create an <code>i64</code><ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a> from a <code>..</code> range</p>
<p>See <ahref="struct.RangedI64ValueParser.html"title="struct clap::builder::RangedI64ValueParser"><code>RangedI64ValueParser</code></a> for more control over the output type.</p>
<p>See also <ahref="struct.RangedU64ValueParser.html"title="struct clap::builder::RangedU64ValueParser"><code>RangedU64ValueParser</code></a></p>
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from-1"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#489">source</a><ahref="#method.from-1"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(value: <aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeFull.html"title="struct core::ops::range::RangeFull">RangeFull</a>) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-From%3CRangeInclusive%3Ci64%3E%3E-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#364">source</a><ahref="#impl-From%3CRangeInclusive%3Ci64%3E%3E-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html"title="trait core::convert::From">From</a><<aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeInclusive.html"title="struct core::ops::range::RangeInclusive">RangeInclusive</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section></summary><divclass="docblock"><p>Create an <code>i64</code><ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a> from a <code>N..=M</code> range</p>
<p>See <ahref="struct.RangedI64ValueParser.html"title="struct clap::builder::RangedI64ValueParser"><code>RangedI64ValueParser</code></a> for more control over the output type.</p>
<p>See also <ahref="struct.RangedU64ValueParser.html"title="struct clap::builder::RangedU64ValueParser"><code>RangedU64ValueParser</code></a></p>
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from-2"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#365">source</a><ahref="#method.from-2"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(value: <aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeInclusive.html"title="struct core::ops::range::RangeInclusive">RangeInclusive</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-From%3CRangeTo%3Ci64%3E%3E-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#426">source</a><ahref="#impl-From%3CRangeTo%3Ci64%3E%3E-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html"title="trait core::convert::From">From</a><<aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeTo.html"title="struct core::ops::range::RangeTo">RangeTo</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section></summary><divclass="docblock"><p>Create an <code>i64</code><ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a> from a <code>..M</code> range</p>
<p>See <ahref="struct.RangedI64ValueParser.html"title="struct clap::builder::RangedI64ValueParser"><code>RangedI64ValueParser</code></a> for more control over the output type.</p>
<p>See also <ahref="struct.RangedU64ValueParser.html"title="struct clap::builder::RangedU64ValueParser"><code>RangedU64ValueParser</code></a></p>
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from-7"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#427">source</a><ahref="#method.from-7"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(value: <aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeTo.html"title="struct core::ops::range::RangeTo">RangeTo</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-From%3CRangeToInclusive%3Ci64%3E%3E-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#457">source</a><ahref="#impl-From%3CRangeToInclusive%3Ci64%3E%3E-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html"title="trait core::convert::From">From</a><<aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeToInclusive.html"title="struct core::ops::range::RangeToInclusive">RangeToInclusive</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section></summary><divclass="docblock"><p>Create an <code>i64</code><ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a> from a <code>..=M</code> range</p>
<p>See <ahref="struct.RangedI64ValueParser.html"title="struct clap::builder::RangedI64ValueParser"><code>RangedI64ValueParser</code></a> for more control over the output type.</p>
<p>See also <ahref="struct.RangedU64ValueParser.html"title="struct clap::builder::RangedU64ValueParser"><code>RangedU64ValueParser</code></a></p>
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from-8"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#458">source</a><ahref="#method.from-8"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(value: <aclass="struct"href="https://doc.rust-lang.org/1.76.0/core/ops/range/struct.RangeToInclusive.html"title="struct core::ops::range::RangeToInclusive">RangeToInclusive</a><<aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.i64.html">i64</a>>) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-From%3CVec%3CP%3E%3E-for-ValueParser"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#556-558">source</a><ahref="#impl-From%3CVec%3CP%3E%3E-for-ValueParser"class="anchor">§</a><h3class="code-header">impl<P><aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html"title="trait core::convert::From">From</a><<aclass="struct"href="https://doc.rust-lang.org/1.76.0/alloc/vec/struct.Vec.html"title="struct alloc::vec::Vec">Vec</a><P>> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a><divclass="where">where
P: <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.Into.html"title="trait core::convert::Into">Into</a><<aclass="struct"href="struct.PossibleValue.html"title="struct clap::builder::PossibleValue">PossibleValue</a>>,</div></h3></section></summary><divclass="docblock"><p>Create a <ahref="struct.ValueParser.html"title="struct clap::builder::ValueParser"><code>ValueParser</code></a> with <ahref="struct.PossibleValuesParser.html"title="struct clap::builder::PossibleValuesParser"><code>PossibleValuesParser</code></a></p>
<p>See <ahref="struct.PossibleValuesParser.html"title="struct clap::builder::PossibleValuesParser"><code>PossibleValuesParser</code></a> for more flexibility in creating the
</div><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.from-6"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/value_parser.rs.html#560">source</a><ahref="#method.from-6"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.From.html#tymethod.from"class="fn">from</a>(values: <aclass="struct"href="https://doc.rust-lang.org/1.76.0/alloc/vec/struct.Vec.html"title="struct alloc::vec::Vec">Vec</a><P>) -><aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h4></section></summary><divclass='docblock'>Converts to this type from the input type.</div></details></div></details><detailsclass="toggle implementors-toggle"open><summary><sectionid="impl-IntoResettable%3CValueParser%3E-for-Option%3CValueParser%3E"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/resettable.rs.html#106">source</a><ahref="#impl-IntoResettable%3CValueParser%3E-for-Option%3CValueParser%3E"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="trait.IntoResettable.html"title="trait clap::builder::IntoResettable">IntoResettable</a><<aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a>> for <aclass="enum"href="https://doc.rust-lang.org/1.76.0/core/option/enum.Option.html"title="enum core::option::Option">Option</a><<aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a>></h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.into_resettable"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/resettable.rs.html#107">source</a><ahref="#method.into_resettable"class="anchor">§</a><h4class="code-header">fn <ahref="trait.IntoResettable.html#tymethod.into_resettable"class="fn">into_resettable</a>(self) -><aclass="enum"href="enum.Resettable.html"title="enum clap::builder::Resettable">Resettable</a><<aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a>></h4></section></summary><divclass='docblock'>Convert to the intended resettable type</div></details></div></details></div><h2id="synthetic-implementations"class="section-header">Auto Trait Implementations<ahref="#synthetic-implementations"class="anchor">§</a></h2><divid="synthetic-implementations-list"><sectionid="impl-RefUnwindSafe-for-ValueParser"class="impl"><ahref="#impl-RefUnwindSafe-for-ValueParser"class="anchor">§</a><h3class="code-header">impl !<aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/panic/unwind_safe/trait.RefUnwindSafe.html"title="trait core::panic::unwind_safe::RefUnwindSafe">RefUnwindSafe</a> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section><sectionid="impl-Send-for-ValueParser"class="impl"><ahref="#impl-Send-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Send.html"title="trait core::marker::Send">Send</a> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section><sectionid="impl-Sync-for-ValueParser"class="impl"><ahref="#impl-Sync-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Sync.html"title="trait core::marker::Sync">Sync</a> for <aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a></h3></section><sectionid="impl-Unpin-for-ValueParser"class="impl"><ahref="#impl-Unpin-for-ValueParser"class="anchor">§</a><h3class="code-header">impl <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/marker/trait.Unpin.html"title="traitcore::m
<p>That is, this conversion is whatever the implementation of
<code><ahref="https://doc.rust-lang.org/1.76.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><detailsclass="toggle implementors-toggle"><summary><sectionid="impl-IntoResettable%3CValueParser%3E-for-I"class="impl"><aclass="src rightside"href="../../src/clap_builder/builder/resettable.rs.html#178">source</a><ahref="#impl-IntoResettable%3CValueParser%3E-for-I"class="anchor">§</a><h3class="code-header">impl<I><aclass="trait"href="trait.IntoResettable.html"title="trait clap::builder::IntoResettable">IntoResettable</a><<aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a>> for I<divclass="where">where
I: <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.Into.html"title="trait core::convert::Into">Into</a><<aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a>>,</div></h3></section></summary><divclass="impl-items"><detailsclass="toggle method-toggle"open><summary><sectionid="method.into_resettable-1"class="method trait-impl"><aclass="src rightside"href="../../src/clap_builder/builder/resettable.rs.html#179">source</a><ahref="#method.into_resettable-1"class="anchor">§</a><h4class="code-header">fn <ahref="trait.IntoResettable.html#tymethod.into_resettable"class="fn">into_resettable</a>(self) -><aclass="enum"href="enum.Resettable.html"title="enum clap::builder::Resettable">Resettable</a><<aclass="struct"href="struct.ValueParser.html"title="struct clap::builder::ValueParser">ValueParser</a>></h4></section></summary><divclass='docblock'>Convert to the intended resettable type</div></details></div></details><detailsclass="toggle implementors-toggle"><summary><sectionid="impl-ToOwned-for-T"class="impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.76.0/src/alloc/borrow.rs.html#83-85">source</a><ahref="#impl-ToOwned-for-T"class="anchor">§</a><h3class="code-header">impl<T><aclass="trait"href="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html"title="trait alloc::borrow::ToOwned">ToOwned</a> for T<divclass="where">where
T: <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/clone/trait.Clone.html"title="trait core::clone::Clone">Clone</a>,</div></h3></section></summary><divclass="impl-items"><detailsclass="toggle"open><summary><sectionid="associatedtype.Owned"class="associatedtype trait-impl"><ahref="#associatedtype.Owned"class="anchor">§</a><h4class="code-header">type <ahref="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#associatedtype.Owned"class="associatedtype">Owned</a> = T</h4></section></summary><divclass='docblock'>The resulting type after obtaining ownership.</div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.to_owned"class="method trait-impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.76.0/src/alloc/borrow.rs.html#88">source</a><ahref="#method.to_owned"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#tymethod.to_owned"class="fn">to_owned</a>(&self) -> T</h4></section></summary><divclass='docblock'>Creates owned data from borrowed data, usually by cloning. <ahref="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#tymethod.to_owned">Read more</a></div></details><detailsclass="toggle method-toggle"open><summary><sectionid="method.clone_into"class="method trait-impl"><aclass="src rightside"href="https://doc.rust-lang.org/1.76.0/src/alloc/borrow.rs.html#92">source</a><ahref="#method.clone_into"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#method.clone_into"class="fn">clone_into</a>(&self, target: <aclass="primitive"href="https://doc.rust-lang.org/1.76.0/std/primitive.reference.html">&mut T</a>)</h4></section></summary><divclass='docblock'>Uses borrowed data to replace owned data, usually by cloning. <ahref="https://doc.rust-lang.org/1.76.0/alloc/borrow/trait.ToOwned.html#method.clone_into">Read more</a></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.76.0/src/core/convert/mod.rs.html#803-805">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.76.0/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.76.0/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"class="associatedtype trait-impl"><ahref="#associatedtype.Error"class="anchor">§</a><h4class="code-header">type <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#associatedtype.Error"class="associatedtype">Error</a> = <aclass="enum"href="https://doc.rust-lang.org/1.76.0/core/convert/enum.Infallible.html"title="enum core::convert::Infallible">Infallible</a></h4></section></summary><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.76.0/src/core/convert/mod.rs.html#810">source</a><ahref="#method.try_from"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#tymethod.try_from"class="fn">try_from</a>(value: U) -><aclass="enum"href="https://doc.rust-lang.org/1.76.0/core/result/enum.Result.html"title="enum core::result::Result">Result</a><T, <T as <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html"title="trait core::convert::TryFrom">TryFrom</a><U>>::<aclass="associatedtype"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#associatedtype.Error"title="type core::convert::TryFrom::Error">Error</a>></h4></section></summary><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.76.0/src/core/convert/mod.rs.html#788-790">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.76.0/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.76.0/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-1"class="associatedtype trait-impl"><ahref="#associatedtype.Error-1"class="anchor">§</a><h4class="code-header">type <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryInto.html#associatedtype.Error"class="associatedtype">Error</a> = <U as <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html"title="trait core::convert::TryFrom">TryFrom</a><T>>::<aclass="associatedtype"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#associatedtype.Error"title="type core::convert::TryFrom::Error">Error</a></h4></section></summary><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.76.0/src/core/convert/mod.rs.html#795">source</a><ahref="#method.try_into"class="anchor">§</a><h4class="code-header">fn <ahref="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryInto.html#tymethod.try_into"class="fn">try_into</a>(self) -><aclass="enum"href="https://doc.rust-lang.org/1.76.0/core/result/enum.Result.html"title="enum core::result::Result">Result</a><U, <U as <aclass="trait"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html"title="trait core::convert::TryFrom">TryFrom</a><T>>::<aclass="associatedtype"href="https://doc.rust-lang.org/1.76.0/core/convert/trait.TryFrom.html#associatedtype.Error"title="type core::convert::TryFrom::Error">Error</a>></h4></section></summary><divclass='docblock'>Performs the conversion.</div></details></div></details></div></section></div></main></body></html>