Imported Upstream version 1.57.0
[platform/upstream/boost.git] / doc / html / program_options / howto.html
index a94e5dc..ce0c864 100644 (file)
@@ -3,9 +3,9 @@
 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
 <title>How To</title>
 <link rel="stylesheet" href="../../../doc/src/boostbook.css" type="text/css">
-<meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
+<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
 <link rel="home" href="../index.html" title="The Boost C++ Libraries BoostBook Documentation Subset">
-<link rel="up" href="../program_options.html" title="Chapter&#160;18.&#160;Boost.Program_options">
+<link rel="up" href="../program_options.html" title="Chapter&#160;21.&#160;Boost.Program_options">
 <link rel="prev" href="overview.html" title="Library Overview">
 <link rel="next" href="design.html" title="Design Discussion">
 </head>
 <div class="section">
 <div class="titlepage"><div><div><h2 class="title" style="clear: both">
 <a name="program_options.howto"></a>How To</h2></div></div></div>
-<div class="toc"><dl>
-<dt><span class="section"><a href="howto.html#id2549735">Non-conventional Syntax</a></span></dt>
-<dt><span class="section"><a href="howto.html#id2549787">Response Files</a></span></dt>
-<dt><span class="section"><a href="howto.html#id2549865">Winmain Command Line</a></span></dt>
-<dt><span class="section"><a href="howto.html#id2549911">Option Groups and Hidden Options</a></span></dt>
-<dt><span class="section"><a href="howto.html#id2550043">Custom Validators</a></span></dt>
-<dt><span class="section"><a href="howto.html#id2550116">Unicode Support</a></span></dt>
-<dt><span class="section"><a href="howto.html#id2550293">Allowing Unknown Options</a></span></dt>
+<div class="toc"><dl class="toc">
+<dt><span class="section"><a href="howto.html#idp343350720">Non-conventional Syntax</a></span></dt>
+<dt><span class="section"><a href="howto.html#idp343356848">Response Files</a></span></dt>
+<dt><span class="section"><a href="howto.html#idp343364880">Winmain Command Line</a></span></dt>
+<dt><span class="section"><a href="howto.html#idp343370112">Option Groups and Hidden Options</a></span></dt>
+<dt><span class="section"><a href="howto.html#idp343385248">Custom Validators</a></span></dt>
+<dt><span class="section"><a href="howto.html#idp343394240">Unicode Support</a></span></dt>
+<dt><span class="section"><a href="howto.html#idp343413520">Allowing Unknown Options</a></span></dt>
 </dl></div>
 <p>This section describes how the library can be used in specific
   situations.</p>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id2549735"></a>Non-conventional Syntax</h3></div></div></div>
+<a name="idp343350720"></a>Non-conventional Syntax</h3></div></div></div>
 <p>Sometimes, standard command line syntaxes are not enough. For
     example, the gcc compiler has "-frtti" and -fno-rtti" options, and this
     syntax is not directly supported.
     </p>
-<a class="indexterm" name="id2549747"></a><p>For such cases, the library allows the user to provide an
+<a class="indexterm" name="idp343351968"></a><p>For such cases, the library allows the user to provide an
     <em class="firstterm">additional parser</em> -- a function which will be called on each
     command line element, before any processing by the library. If the
     additional parser recognises the syntax, it returns the option name and
@@ -80,8 +80,8 @@ store(command_line_parser(ac, av).options(desc).extra_parser(reg_foo)
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id2549787"></a>Response Files</h3></div></div></div>
-<a class="indexterm" name="id2549793"></a><p>Some operating system have very low limits of the command line
+<a name="idp343356848"></a>Response Files</h3></div></div></div>
+<a class="indexterm" name="idp343357520"></a><p>Some operating system have very low limits of the command line
       length. The common way to work around those limitations is using
       <em class="firstterm">response files</em>.  A response file is just a
       configuration file which uses the same syntax as the command line. If
@@ -148,7 +148,7 @@ if (vm.count("response-file")) {
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id2549865"></a>Winmain Command Line</h3></div></div></div>
+<a name="idp343364880"></a>Winmain Command Line</h3></div></div></div>
 <p>On the Windows operating system, GUI applications receive the
     command line as a single string, not split into elements. For that reason,
     the command line parser cannot be used directly. At least on some
@@ -170,11 +170,11 @@ store(command_line_parser(args).options(desc).run(), vm);
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id2549911"></a>Option Groups and Hidden Options</h3></div></div></div>
+<a name="idp343370112"></a>Option Groups and Hidden Options</h3></div></div></div>
 <p>Having a single instance of the <code class="computeroutput"><a class="link" href="../boost/program_options/options_description.html" title="Class options_description">options_description</a></code> class with all
     the program's options can be problematic:
       </p>
-<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
 <li class="listitem"><p>Some options make sense only for specific source, for example,
           configuration files.</p></li>
 <li class="listitem"><p>The user would prefer some structure in the generated help message.</p></li>
@@ -269,7 +269,7 @@ if (vm.count("num-threads")) {
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id2550043"></a>Custom Validators</h3></div></div></div>
+<a name="idp343385248"></a>Custom Validators</h3></div></div></div>
 <p>By default, the conversion of option's value from string into C++
       type is done using iostreams, which sometimes is not convenient. The
       library allows the user to customize the conversion for specific
@@ -332,10 +332,10 @@ void validate(boost::any&amp; v,
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id2550116"></a>Unicode Support</h3></div></div></div>
+<a name="idp343394240"></a>Unicode Support</h3></div></div></div>
 <p>To use the library with Unicode, you'd need to:
       </p>
-<div class="itemizedlist"><ul class="itemizedlist" type="disc">
+<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
 <li class="listitem"><p>Use Unicode-aware parsers for Unicode input</p></li>
 <li class="listitem"><p>Require Unicode support for options which need it</p></li>
 </ul></div>
@@ -402,14 +402,14 @@ $ export LC_CTYPE=ru_RU.KOI8-R
 </div>
 <div class="section">
 <div class="titlepage"><div><div><h3 class="title">
-<a name="id2550293"></a>Allowing Unknown Options</h3></div></div></div>
+<a name="idp343413520"></a>Allowing Unknown Options</h3></div></div></div>
 <p>Usually, the library throws an exception on unknown option names. This 
       behaviour can be changed. For example, only some part of your application uses 
-      <a class="link" href="../program_options.html" title="Chapter&#160;18.&#160;Boost.Program_options">Program_options</a>, and you wish to pass unrecognized options to another part of
+      <a class="link" href="../program_options.html" title="Chapter&#160;21.&#160;Boost.Program_options">Program_options</a>, and you wish to pass unrecognized options to another part of
       the program, or even to another application.</p>
 <p>To allow unregistered options on the command line, you need to use 
       the <code class="computeroutput"><a class="link" href="../boost/program_options/basic_command_line_parser.html" title="Class template basic_command_line_parser">basic_command_line_parser</a></code> class for parsing (not <code class="computeroutput"><a class="link" href="../boost/program_options/parse_command_line.html" title="Function template parse_command_line">parse_command_line</a></code>)
-      and call the <code class="computeroutput"><a class="link" href="../boost/program_options/basic_command_line_parser.html#id1139869-bb">allow_unregistered</a></code> 
+      and call the <code class="computeroutput"><a class="link" href="../boost/program_options/basic_command_line_parser.html#idp47257264-bb">allow_unregistered</a></code> 
       method of that class:
       </p>
 <pre class="programlisting">