Network programming assignment for University
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

OptionBuilder.html 38 KiB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737
  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <!-- NewPage -->
  3. <html lang="de">
  4. <head>
  5. <!-- Generated by javadoc -->
  6. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  7. <title>OptionBuilder (Apache Commons CLI 1.4 API)</title>
  8. <link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
  9. <script type="text/javascript" src="../../../../script.js"></script>
  10. </head>
  11. <body>
  12. <script type="text/javascript"><!--
  13. try {
  14. if (location.href.indexOf('is-external=true') == -1) {
  15. parent.document.title="OptionBuilder (Apache Commons CLI 1.4 API)";
  16. }
  17. }
  18. catch(err) {
  19. }
  20. //-->
  21. var methods = {"i0":41,"i1":41,"i2":41,"i3":41,"i4":41,"i5":41,"i6":41,"i7":41,"i8":41,"i9":41,"i10":41,"i11":41,"i12":41,"i13":41,"i14":41,"i15":41,"i16":41,"i17":41,"i18":41};
  22. var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],8:["t4","Concrete Methods"],32:["t6","Deprecated Methods"]};
  23. var altColor = "altColor";
  24. var rowColor = "rowColor";
  25. var tableTab = "tableTab";
  26. var activeTableTab = "activeTableTab";
  27. </script>
  28. <noscript>
  29. <div>JavaScript is disabled on your browser.</div>
  30. </noscript>
  31. <!-- ========= START OF TOP NAVBAR ======= -->
  32. <div class="topNav"><a name="navbar.top">
  33. <!-- -->
  34. </a>
  35. <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
  36. <a name="navbar.top.firstrow">
  37. <!-- -->
  38. </a>
  39. <ul class="navList" title="Navigation">
  40. <li><a href="../../../../org/apache/commons/cli/package-summary.html">Package</a></li>
  41. <li class="navBarCell1Rev">Class</li>
  42. <li><a href="class-use/OptionBuilder.html">Use</a></li>
  43. <li><a href="package-tree.html">Tree</a></li>
  44. <li><a href="../../../../deprecated-list.html">Deprecated</a></li>
  45. <li><a href="../../../../index-all.html">Index</a></li>
  46. <li><a href="../../../../help-doc.html">Help</a></li>
  47. </ul>
  48. </div>
  49. <div class="subNav">
  50. <ul class="navList">
  51. <li><a href="../../../../org/apache/commons/cli/Option.Builder.html" title="class in org.apache.commons.cli"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
  52. <li><a href="../../../../org/apache/commons/cli/OptionGroup.html" title="class in org.apache.commons.cli"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
  53. </ul>
  54. <ul class="navList">
  55. <li><a href="../../../../index.html?org/apache/commons/cli/OptionBuilder.html" target="_top">Frames</a></li>
  56. <li><a href="OptionBuilder.html" target="_top">No&nbsp;Frames</a></li>
  57. </ul>
  58. <ul class="navList" id="allclasses_navbar_top">
  59. <li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
  60. </ul>
  61. <div>
  62. <script type="text/javascript"><!--
  63. allClassesLink = document.getElementById("allclasses_navbar_top");
  64. if(window==top) {
  65. allClassesLink.style.display = "block";
  66. }
  67. else {
  68. allClassesLink.style.display = "none";
  69. }
  70. //-->
  71. </script>
  72. </div>
  73. <div>
  74. <ul class="subNavList">
  75. <li>Summary:&nbsp;</li>
  76. <li>Nested&nbsp;|&nbsp;</li>
  77. <li>Field&nbsp;|&nbsp;</li>
  78. <li>Constr&nbsp;|&nbsp;</li>
  79. <li><a href="#method.summary">Method</a></li>
  80. </ul>
  81. <ul class="subNavList">
  82. <li>Detail:&nbsp;</li>
  83. <li>Field&nbsp;|&nbsp;</li>
  84. <li>Constr&nbsp;|&nbsp;</li>
  85. <li><a href="#method.detail">Method</a></li>
  86. </ul>
  87. </div>
  88. <a name="skip.navbar.top">
  89. <!-- -->
  90. </a></div>
  91. <!-- ========= END OF TOP NAVBAR ========= -->
  92. <!-- ======== START OF CLASS DATA ======== -->
  93. <div class="header">
  94. <div class="subTitle">org.apache.commons.cli</div>
  95. <h2 title="Class OptionBuilder" class="title">Class OptionBuilder</h2>
  96. </div>
  97. <div class="contentContainer">
  98. <ul class="inheritance">
  99. <li><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
  100. <li>
  101. <ul class="inheritance">
  102. <li>org.apache.commons.cli.OptionBuilder</li>
  103. </ul>
  104. </li>
  105. </ul>
  106. <div class="description">
  107. <ul class="blockList">
  108. <li class="blockList">
  109. <hr>
  110. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;
  111. <div class="block"><span class="deprecationComment">since 1.3, use <a href="../../../../org/apache/commons/cli/Option.html#builder-java.lang.String-"><code>Option.builder(String)</code></a> instead</span></div>
  112. </div>
  113. <br>
  114. <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
  115. public final class <span class="typeNameLabel">OptionBuilder</span>
  116. extends <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre>
  117. <div class="block">OptionBuilder allows the user to create Options using descriptive methods.
  118. <p>
  119. Details on the Builder pattern can be found at
  120. <a href="http://c2.com/cgi-bin/wiki?BuilderPattern">http://c2.com/cgi-bin/wiki?BuilderPattern</a>.
  121. <p>
  122. This class is NOT thread safe. See <a href="https://issues.apache.org/jira/browse/CLI-209">CLI-209</a></div>
  123. <dl>
  124. <dt><span class="simpleTagLabel">Since:</span></dt>
  125. <dd>1.0</dd>
  126. <dt><span class="simpleTagLabel">Version:</span></dt>
  127. <dd>$Id: OptionBuilder.java 1677400 2015-05-03 13:46:08Z britter $</dd>
  128. </dl>
  129. </li>
  130. </ul>
  131. </div>
  132. <div class="summary">
  133. <ul class="blockList">
  134. <li class="blockList">
  135. <!-- ========== METHOD SUMMARY =========== -->
  136. <ul class="blockList">
  137. <li class="blockList"><a name="method.summary">
  138. <!-- -->
  139. </a>
  140. <h3>Method Summary</h3>
  141. <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
  142. <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t6" class="tableTab"><span><a href="javascript:show(32);">Deprecated Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
  143. <tr>
  144. <th class="colFirst" scope="col">Modifier and Type</th>
  145. <th class="colLast" scope="col">Method and Description</th>
  146. </tr>
  147. <tr id="i0" class="altColor">
  148. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/Option.html" title="class in org.apache.commons.cli">Option</a></code></td>
  149. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#create--">create</a></span>()</code>
  150. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  151. <div class="block">Create an Option using the current settings</div>
  152. </td>
  153. </tr>
  154. <tr id="i1" class="rowColor">
  155. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/Option.html" title="class in org.apache.commons.cli">Option</a></code></td>
  156. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#create-char-">create</a></span>(char&nbsp;opt)</code>
  157. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  158. <div class="block">Create an Option using the current settings and with
  159. the specified Option <code>char</code>.</div>
  160. </td>
  161. </tr>
  162. <tr id="i2" class="altColor">
  163. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/Option.html" title="class in org.apache.commons.cli">Option</a></code></td>
  164. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#create-java.lang.String-">create</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;opt)</code>
  165. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  166. <div class="block">Create an Option using the current settings and with
  167. the specified Option <code>char</code>.</div>
  168. </td>
  169. </tr>
  170. <tr id="i3" class="rowColor">
  171. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  172. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#hasArg--">hasArg</a></span>()</code>
  173. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  174. <div class="block">The next Option created will require an argument value.</div>
  175. </td>
  176. </tr>
  177. <tr id="i4" class="altColor">
  178. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  179. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#hasArg-boolean-">hasArg</a></span>(boolean&nbsp;hasArg)</code>
  180. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  181. <div class="block">The next Option created will require an argument value if
  182. <code>hasArg</code> is true.</div>
  183. </td>
  184. </tr>
  185. <tr id="i5" class="rowColor">
  186. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  187. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#hasArgs--">hasArgs</a></span>()</code>
  188. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  189. <div class="block">The next Option created can have unlimited argument values.</div>
  190. </td>
  191. </tr>
  192. <tr id="i6" class="altColor">
  193. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  194. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#hasArgs-int-">hasArgs</a></span>(int&nbsp;num)</code>
  195. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  196. <div class="block">The next Option created can have <code>num</code> argument values.</div>
  197. </td>
  198. </tr>
  199. <tr id="i7" class="rowColor">
  200. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  201. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#hasOptionalArg--">hasOptionalArg</a></span>()</code>
  202. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  203. <div class="block">The next Option can have an optional argument.</div>
  204. </td>
  205. </tr>
  206. <tr id="i8" class="altColor">
  207. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  208. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#hasOptionalArgs--">hasOptionalArgs</a></span>()</code>
  209. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  210. <div class="block">The next Option can have an unlimited number of optional arguments.</div>
  211. </td>
  212. </tr>
  213. <tr id="i9" class="rowColor">
  214. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  215. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#hasOptionalArgs-int-">hasOptionalArgs</a></span>(int&nbsp;numArgs)</code>
  216. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  217. <div class="block">The next Option can have the specified number of optional arguments.</div>
  218. </td>
  219. </tr>
  220. <tr id="i10" class="altColor">
  221. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  222. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#isRequired--">isRequired</a></span>()</code>
  223. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  224. <div class="block">The next Option created will be required.</div>
  225. </td>
  226. </tr>
  227. <tr id="i11" class="rowColor">
  228. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  229. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#isRequired-boolean-">isRequired</a></span>(boolean&nbsp;newRequired)</code>
  230. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  231. <div class="block">The next Option created will be required if <code>required</code>
  232. is true.</div>
  233. </td>
  234. </tr>
  235. <tr id="i12" class="altColor">
  236. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  237. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#withArgName-java.lang.String-">withArgName</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;name)</code>
  238. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  239. <div class="block">The next Option created will have the specified argument value name.</div>
  240. </td>
  241. </tr>
  242. <tr id="i13" class="rowColor">
  243. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  244. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#withDescription-java.lang.String-">withDescription</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;newDescription)</code>
  245. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  246. <div class="block">The next Option created will have the specified description</div>
  247. </td>
  248. </tr>
  249. <tr id="i14" class="altColor">
  250. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  251. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#withLongOpt-java.lang.String-">withLongOpt</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;newLongopt)</code>
  252. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  253. <div class="block">The next Option created will have the following long option value.</div>
  254. </td>
  255. </tr>
  256. <tr id="i15" class="rowColor">
  257. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  258. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#withType-java.lang.Class-">withType</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&lt;?&gt;&nbsp;newType)</code>
  259. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  260. <div class="block">The next Option created will have a value that will be an instance
  261. of <code>type</code>.</div>
  262. </td>
  263. </tr>
  264. <tr id="i16" class="altColor">
  265. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  266. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#withType-java.lang.Object-">withType</a></span>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&nbsp;newType)</code>
  267. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;
  268. <div class="block"><span class="deprecationComment">since 1.3, use <a href="../../../../org/apache/commons/cli/OptionBuilder.html#withType-java.lang.Class-"><code>withType(Class)</code></a> instead</span></div>
  269. </div>
  270. </td>
  271. </tr>
  272. <tr id="i17" class="rowColor">
  273. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  274. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#withValueSeparator--">withValueSeparator</a></span>()</code>
  275. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  276. <div class="block">The next Option created uses '<code>=</code>' as a means to
  277. separate argument values.</div>
  278. </td>
  279. </tr>
  280. <tr id="i18" class="altColor">
  281. <td class="colFirst"><code>static <a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a></code></td>
  282. <td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/commons/cli/OptionBuilder.html#withValueSeparator-char-">withValueSeparator</a></span>(char&nbsp;sep)</code>
  283. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  284. <div class="block">The next Option created uses <code>sep</code> as a means to
  285. separate argument values.</div>
  286. </td>
  287. </tr>
  288. </table>
  289. <ul class="blockList">
  290. <li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
  291. <!-- -->
  292. </a>
  293. <h3>Methods inherited from class&nbsp;java.lang.<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
  294. <code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li>
  295. </ul>
  296. </li>
  297. </ul>
  298. </li>
  299. </ul>
  300. </div>
  301. <div class="details">
  302. <ul class="blockList">
  303. <li class="blockList">
  304. <!-- ============ METHOD DETAIL ========== -->
  305. <ul class="blockList">
  306. <li class="blockList"><a name="method.detail">
  307. <!-- -->
  308. </a>
  309. <h3>Method Detail</h3>
  310. <a name="withLongOpt-java.lang.String-">
  311. <!-- -->
  312. </a>
  313. <ul class="blockList">
  314. <li class="blockList">
  315. <h4>withLongOpt</h4>
  316. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;withLongOpt(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;newLongopt)</pre>
  317. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  318. <div class="block">The next Option created will have the following long option value.</div>
  319. <dl>
  320. <dt><span class="paramLabel">Parameters:</span></dt>
  321. <dd><code>newLongopt</code> - the long option value</dd>
  322. <dt><span class="returnLabel">Returns:</span></dt>
  323. <dd>the OptionBuilder instance</dd>
  324. </dl>
  325. </li>
  326. </ul>
  327. <a name="hasArg--">
  328. <!-- -->
  329. </a>
  330. <ul class="blockList">
  331. <li class="blockList">
  332. <h4>hasArg</h4>
  333. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;hasArg()</pre>
  334. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  335. <div class="block">The next Option created will require an argument value.</div>
  336. <dl>
  337. <dt><span class="returnLabel">Returns:</span></dt>
  338. <dd>the OptionBuilder instance</dd>
  339. </dl>
  340. </li>
  341. </ul>
  342. <a name="hasArg-boolean-">
  343. <!-- -->
  344. </a>
  345. <ul class="blockList">
  346. <li class="blockList">
  347. <h4>hasArg</h4>
  348. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;hasArg(boolean&nbsp;hasArg)</pre>
  349. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  350. <div class="block">The next Option created will require an argument value if
  351. <code>hasArg</code> is true.</div>
  352. <dl>
  353. <dt><span class="paramLabel">Parameters:</span></dt>
  354. <dd><code>hasArg</code> - if true then the Option has an argument value</dd>
  355. <dt><span class="returnLabel">Returns:</span></dt>
  356. <dd>the OptionBuilder instance</dd>
  357. </dl>
  358. </li>
  359. </ul>
  360. <a name="withArgName-java.lang.String-">
  361. <!-- -->
  362. </a>
  363. <ul class="blockList">
  364. <li class="blockList">
  365. <h4>withArgName</h4>
  366. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;withArgName(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;name)</pre>
  367. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  368. <div class="block">The next Option created will have the specified argument value name.</div>
  369. <dl>
  370. <dt><span class="paramLabel">Parameters:</span></dt>
  371. <dd><code>name</code> - the name for the argument value</dd>
  372. <dt><span class="returnLabel">Returns:</span></dt>
  373. <dd>the OptionBuilder instance</dd>
  374. </dl>
  375. </li>
  376. </ul>
  377. <a name="isRequired--">
  378. <!-- -->
  379. </a>
  380. <ul class="blockList">
  381. <li class="blockList">
  382. <h4>isRequired</h4>
  383. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;isRequired()</pre>
  384. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  385. <div class="block">The next Option created will be required.</div>
  386. <dl>
  387. <dt><span class="returnLabel">Returns:</span></dt>
  388. <dd>the OptionBuilder instance</dd>
  389. </dl>
  390. </li>
  391. </ul>
  392. <a name="withValueSeparator-char-">
  393. <!-- -->
  394. </a>
  395. <ul class="blockList">
  396. <li class="blockList">
  397. <h4>withValueSeparator</h4>
  398. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;withValueSeparator(char&nbsp;sep)</pre>
  399. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  400. <div class="block">The next Option created uses <code>sep</code> as a means to
  401. separate argument values.
  402. <p>
  403. <b>Example:</b>
  404. <pre>
  405. Option opt = OptionBuilder.withValueSeparator('=')
  406. .create('D');
  407. String args = "-Dkey=value";
  408. CommandLine line = parser.parse(args);
  409. String propertyName = opt.getValue(0); // will be "key"
  410. String propertyValue = opt.getValue(1); // will be "value"
  411. </pre></div>
  412. <dl>
  413. <dt><span class="paramLabel">Parameters:</span></dt>
  414. <dd><code>sep</code> - The value separator to be used for the argument values.</dd>
  415. <dt><span class="returnLabel">Returns:</span></dt>
  416. <dd>the OptionBuilder instance</dd>
  417. </dl>
  418. </li>
  419. </ul>
  420. <a name="withValueSeparator--">
  421. <!-- -->
  422. </a>
  423. <ul class="blockList">
  424. <li class="blockList">
  425. <h4>withValueSeparator</h4>
  426. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;withValueSeparator()</pre>
  427. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  428. <div class="block">The next Option created uses '<code>=</code>' as a means to
  429. separate argument values.
  430. <b>Example:</b>
  431. <pre>
  432. Option opt = OptionBuilder.withValueSeparator()
  433. .create('D');
  434. CommandLine line = parser.parse(args);
  435. String propertyName = opt.getValue(0);
  436. String propertyValue = opt.getValue(1);
  437. </pre></div>
  438. <dl>
  439. <dt><span class="returnLabel">Returns:</span></dt>
  440. <dd>the OptionBuilder instance</dd>
  441. </dl>
  442. </li>
  443. </ul>
  444. <a name="isRequired-boolean-">
  445. <!-- -->
  446. </a>
  447. <ul class="blockList">
  448. <li class="blockList">
  449. <h4>isRequired</h4>
  450. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;isRequired(boolean&nbsp;newRequired)</pre>
  451. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  452. <div class="block">The next Option created will be required if <code>required</code>
  453. is true.</div>
  454. <dl>
  455. <dt><span class="paramLabel">Parameters:</span></dt>
  456. <dd><code>newRequired</code> - if true then the Option is required</dd>
  457. <dt><span class="returnLabel">Returns:</span></dt>
  458. <dd>the OptionBuilder instance</dd>
  459. </dl>
  460. </li>
  461. </ul>
  462. <a name="hasArgs--">
  463. <!-- -->
  464. </a>
  465. <ul class="blockList">
  466. <li class="blockList">
  467. <h4>hasArgs</h4>
  468. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;hasArgs()</pre>
  469. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  470. <div class="block">The next Option created can have unlimited argument values.</div>
  471. <dl>
  472. <dt><span class="returnLabel">Returns:</span></dt>
  473. <dd>the OptionBuilder instance</dd>
  474. </dl>
  475. </li>
  476. </ul>
  477. <a name="hasArgs-int-">
  478. <!-- -->
  479. </a>
  480. <ul class="blockList">
  481. <li class="blockList">
  482. <h4>hasArgs</h4>
  483. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;hasArgs(int&nbsp;num)</pre>
  484. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  485. <div class="block">The next Option created can have <code>num</code> argument values.</div>
  486. <dl>
  487. <dt><span class="paramLabel">Parameters:</span></dt>
  488. <dd><code>num</code> - the number of args that the option can have</dd>
  489. <dt><span class="returnLabel">Returns:</span></dt>
  490. <dd>the OptionBuilder instance</dd>
  491. </dl>
  492. </li>
  493. </ul>
  494. <a name="hasOptionalArg--">
  495. <!-- -->
  496. </a>
  497. <ul class="blockList">
  498. <li class="blockList">
  499. <h4>hasOptionalArg</h4>
  500. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;hasOptionalArg()</pre>
  501. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  502. <div class="block">The next Option can have an optional argument.</div>
  503. <dl>
  504. <dt><span class="returnLabel">Returns:</span></dt>
  505. <dd>the OptionBuilder instance</dd>
  506. </dl>
  507. </li>
  508. </ul>
  509. <a name="hasOptionalArgs--">
  510. <!-- -->
  511. </a>
  512. <ul class="blockList">
  513. <li class="blockList">
  514. <h4>hasOptionalArgs</h4>
  515. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;hasOptionalArgs()</pre>
  516. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  517. <div class="block">The next Option can have an unlimited number of optional arguments.</div>
  518. <dl>
  519. <dt><span class="returnLabel">Returns:</span></dt>
  520. <dd>the OptionBuilder instance</dd>
  521. </dl>
  522. </li>
  523. </ul>
  524. <a name="hasOptionalArgs-int-">
  525. <!-- -->
  526. </a>
  527. <ul class="blockList">
  528. <li class="blockList">
  529. <h4>hasOptionalArgs</h4>
  530. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;hasOptionalArgs(int&nbsp;numArgs)</pre>
  531. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  532. <div class="block">The next Option can have the specified number of optional arguments.</div>
  533. <dl>
  534. <dt><span class="paramLabel">Parameters:</span></dt>
  535. <dd><code>numArgs</code> - - the maximum number of optional arguments
  536. the next Option created can have.</dd>
  537. <dt><span class="returnLabel">Returns:</span></dt>
  538. <dd>the OptionBuilder instance</dd>
  539. </dl>
  540. </li>
  541. </ul>
  542. <a name="withType-java.lang.Object-">
  543. <!-- -->
  544. </a>
  545. <ul class="blockList">
  546. <li class="blockList">
  547. <h4>withType</h4>
  548. <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a>
  549. public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;withType(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&nbsp;newType)</pre>
  550. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;<span class="deprecationComment">since 1.3, use <a href="../../../../org/apache/commons/cli/OptionBuilder.html#withType-java.lang.Class-"><code>withType(Class)</code></a> instead</span></div>
  551. <div class="block">The next Option created will have a value that will be an instance
  552. of <code>type</code>.
  553. <p>
  554. <b>Note:</b> this method is kept for binary compatibility and the
  555. input type is supposed to be a <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang"><code>Class</code></a> object.</div>
  556. <dl>
  557. <dt><span class="paramLabel">Parameters:</span></dt>
  558. <dd><code>newType</code> - the type of the Options argument value</dd>
  559. <dt><span class="returnLabel">Returns:</span></dt>
  560. <dd>the OptionBuilder instance</dd>
  561. </dl>
  562. </li>
  563. </ul>
  564. <a name="withType-java.lang.Class-">
  565. <!-- -->
  566. </a>
  567. <ul class="blockList">
  568. <li class="blockList">
  569. <h4>withType</h4>
  570. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;withType(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&lt;?&gt;&nbsp;newType)</pre>
  571. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  572. <div class="block">The next Option created will have a value that will be an instance
  573. of <code>type</code>.</div>
  574. <dl>
  575. <dt><span class="paramLabel">Parameters:</span></dt>
  576. <dd><code>newType</code> - the type of the Options argument value</dd>
  577. <dt><span class="returnLabel">Returns:</span></dt>
  578. <dd>the OptionBuilder instance</dd>
  579. <dt><span class="simpleTagLabel">Since:</span></dt>
  580. <dd>1.3</dd>
  581. </dl>
  582. </li>
  583. </ul>
  584. <a name="withDescription-java.lang.String-">
  585. <!-- -->
  586. </a>
  587. <ul class="blockList">
  588. <li class="blockList">
  589. <h4>withDescription</h4>
  590. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/OptionBuilder.html" title="class in org.apache.commons.cli">OptionBuilder</a>&nbsp;withDescription(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;newDescription)</pre>
  591. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  592. <div class="block">The next Option created will have the specified description</div>
  593. <dl>
  594. <dt><span class="paramLabel">Parameters:</span></dt>
  595. <dd><code>newDescription</code> - a description of the Option's purpose</dd>
  596. <dt><span class="returnLabel">Returns:</span></dt>
  597. <dd>the OptionBuilder instance</dd>
  598. </dl>
  599. </li>
  600. </ul>
  601. <a name="create-char-">
  602. <!-- -->
  603. </a>
  604. <ul class="blockList">
  605. <li class="blockList">
  606. <h4>create</h4>
  607. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/Option.html" title="class in org.apache.commons.cli">Option</a>&nbsp;create(char&nbsp;opt)
  608. throws <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></pre>
  609. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  610. <div class="block">Create an Option using the current settings and with
  611. the specified Option <code>char</code>.</div>
  612. <dl>
  613. <dt><span class="paramLabel">Parameters:</span></dt>
  614. <dd><code>opt</code> - the character representation of the Option</dd>
  615. <dt><span class="returnLabel">Returns:</span></dt>
  616. <dd>the Option instance</dd>
  617. <dt><span class="throwsLabel">Throws:</span></dt>
  618. <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if <code>opt</code> is not
  619. a valid character. See Option.</dd>
  620. </dl>
  621. </li>
  622. </ul>
  623. <a name="create--">
  624. <!-- -->
  625. </a>
  626. <ul class="blockList">
  627. <li class="blockList">
  628. <h4>create</h4>
  629. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/Option.html" title="class in org.apache.commons.cli">Option</a>&nbsp;create()
  630. throws <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></pre>
  631. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  632. <div class="block">Create an Option using the current settings</div>
  633. <dl>
  634. <dt><span class="returnLabel">Returns:</span></dt>
  635. <dd>the Option instance</dd>
  636. <dt><span class="throwsLabel">Throws:</span></dt>
  637. <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if <code>longOpt</code> has not been set.</dd>
  638. </dl>
  639. </li>
  640. </ul>
  641. <a name="create-java.lang.String-">
  642. <!-- -->
  643. </a>
  644. <ul class="blockListLast">
  645. <li class="blockList">
  646. <h4>create</h4>
  647. <pre>public static&nbsp;<a href="../../../../org/apache/commons/cli/Option.html" title="class in org.apache.commons.cli">Option</a>&nbsp;create(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;opt)
  648. throws <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></pre>
  649. <div class="block"><span class="deprecatedLabel">Deprecated.</span>&nbsp;</div>
  650. <div class="block">Create an Option using the current settings and with
  651. the specified Option <code>char</code>.</div>
  652. <dl>
  653. <dt><span class="paramLabel">Parameters:</span></dt>
  654. <dd><code>opt</code> - the <code>java.lang.String</code> representation
  655. of the Option</dd>
  656. <dt><span class="returnLabel">Returns:</span></dt>
  657. <dd>the Option instance</dd>
  658. <dt><span class="throwsLabel">Throws:</span></dt>
  659. <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if <code>opt</code> is not
  660. a valid character. See Option.</dd>
  661. </dl>
  662. </li>
  663. </ul>
  664. </li>
  665. </ul>
  666. </li>
  667. </ul>
  668. </div>
  669. </div>
  670. <!-- ========= END OF CLASS DATA ========= -->
  671. <!-- ======= START OF BOTTOM NAVBAR ====== -->
  672. <div class="bottomNav"><a name="navbar.bottom">
  673. <!-- -->
  674. </a>
  675. <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
  676. <a name="navbar.bottom.firstrow">
  677. <!-- -->
  678. </a>
  679. <ul class="navList" title="Navigation">
  680. <li><a href="../../../../org/apache/commons/cli/package-summary.html">Package</a></li>
  681. <li class="navBarCell1Rev">Class</li>
  682. <li><a href="class-use/OptionBuilder.html">Use</a></li>
  683. <li><a href="package-tree.html">Tree</a></li>
  684. <li><a href="../../../../deprecated-list.html">Deprecated</a></li>
  685. <li><a href="../../../../index-all.html">Index</a></li>
  686. <li><a href="../../../../help-doc.html">Help</a></li>
  687. </ul>
  688. </div>
  689. <div class="subNav">
  690. <ul class="navList">
  691. <li><a href="../../../../org/apache/commons/cli/Option.Builder.html" title="class in org.apache.commons.cli"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
  692. <li><a href="../../../../org/apache/commons/cli/OptionGroup.html" title="class in org.apache.commons.cli"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
  693. </ul>
  694. <ul class="navList">
  695. <li><a href="../../../../index.html?org/apache/commons/cli/OptionBuilder.html" target="_top">Frames</a></li>
  696. <li><a href="OptionBuilder.html" target="_top">No&nbsp;Frames</a></li>
  697. </ul>
  698. <ul class="navList" id="allclasses_navbar_bottom">
  699. <li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
  700. </ul>
  701. <div>
  702. <script type="text/javascript"><!--
  703. allClassesLink = document.getElementById("allclasses_navbar_bottom");
  704. if(window==top) {
  705. allClassesLink.style.display = "block";
  706. }
  707. else {
  708. allClassesLink.style.display = "none";
  709. }
  710. //-->
  711. </script>
  712. </div>
  713. <div>
  714. <ul class="subNavList">
  715. <li>Summary:&nbsp;</li>
  716. <li>Nested&nbsp;|&nbsp;</li>
  717. <li>Field&nbsp;|&nbsp;</li>
  718. <li>Constr&nbsp;|&nbsp;</li>
  719. <li><a href="#method.summary">Method</a></li>
  720. </ul>
  721. <ul class="subNavList">
  722. <li>Detail:&nbsp;</li>
  723. <li>Field&nbsp;|&nbsp;</li>
  724. <li>Constr&nbsp;|&nbsp;</li>
  725. <li><a href="#method.detail">Method</a></li>
  726. </ul>
  727. </div>
  728. <a name="skip.navbar.bottom">
  729. <!-- -->
  730. </a></div>
  731. <!-- ======== END OF BOTTOM NAVBAR ======= -->
  732. <p class="legalCopy"><small>Copyright &#169; 2002&#x2013;2017 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
  733. </body>
  734. </html>