@@ -35,19 +35,21 @@ Licensed to the Apache Software Foundation (ASF) under one or more
3535 * Additionally, any left-over or unrecognized arguments, are available for further processing.
3636 */
3737public class CommandLine implements Serializable {
38+
3839 /**
3940 * A nested builder class to create {@code CommandLine} instance using descriptive methods.
4041 *
4142 * @since 1.4
4243 */
4344 public static final class Builder {
45+
4446 /**
4547 * CommandLine that is being build by this Builder.
4648 */
4749 private final CommandLine commandLine = new CommandLine ();
4850
4951 /**
50- * Add left-over unrecognized option/argument.
52+ * Adds left-over unrecognized option/argument.
5153 *
5254 * @param arg the unrecognized option/argument.
5355 *
@@ -59,7 +61,7 @@ public Builder addArg(final String arg) {
5961 }
6062
6163 /**
62- * Add an option to the command line. The values of the option are stored.
64+ * Adds an option to the command line. The values of the option are stored.
6365 *
6466 * @param opt the processed option.
6567 *
@@ -92,7 +94,7 @@ protected CommandLine() {
9294 }
9395
9496 /**
95- * Add left-over unrecognized option/argument.
97+ * Adds left-over unrecognized option/argument.
9698 *
9799 * @param arg the unrecognized option/argument.
98100 */
@@ -101,7 +103,7 @@ protected void addArg(final String arg) {
101103 }
102104
103105 /**
104- * Add an option to the command line. The values of the option are stored.
106+ * Adds an option to the command line. The values of the option are stored.
105107 *
106108 * @param opt the processed option.
107109 */
@@ -110,7 +112,7 @@ protected void addOption(final Option opt) {
110112 }
111113
112114 /**
113- * Retrieve any left-over non-recognized options and arguments
115+ * Gets any left-over non-recognized options and arguments
114116 *
115117 * @return remaining items passed in but not parsed as a {@code List}.
116118 */
@@ -119,7 +121,7 @@ public List<String> getArgList() {
119121 }
120122
121123 /**
122- * Retrieve any left-over non-recognized options and arguments
124+ * Gets any left-over non-recognized options and arguments
123125 *
124126 * @return remaining items passed in but not parsed as an array.
125127 */
@@ -128,7 +130,7 @@ public String[] getArgs() {
128130 }
129131
130132 /**
131- * Return the {@code Object} type of this {@code Option}.
133+ * Gets the {@code Object} type of this {@code Option}.
132134 *
133135 * @deprecated due to System.err message. Instead use getParsedOptionValue(char)
134136 * @param opt the name of the option.
@@ -140,7 +142,7 @@ public Object getOptionObject(final char opt) {
140142 }
141143
142144 /**
143- * Return the {@code Object} type of this {@code Option}.
145+ * Gets the {@code Object} type of this {@code Option}.
144146 *
145147 * @param opt the name of the option.
146148 * @return the type of this {@code Option}.
@@ -157,7 +159,7 @@ public Object getOptionObject(final String opt) {
157159 }
158160
159161 /**
160- * Retrieve the map of values associated to the option. This is convenient for options specifying Java properties like
162+ * Gets the map of values associated to the option. This is convenient for options specifying Java properties like
161163 * <code>-Dparam1=value1
162164 * -Dparam2=value2</code>. The first argument of the option is the key, and the 2nd argument is the value. If the option
163165 * has only one argument ({@code -Dfoo}) it is considered as a boolean flag and the value is {@code "true"}.
@@ -186,7 +188,7 @@ public Properties getOptionProperties(final Option option) {
186188 }
187189
188190 /**
189- * Retrieve the map of values associated to the option. This is convenient for options specifying Java properties like
191+ * Gets the map of values associated to the option. This is convenient for options specifying Java properties like
190192 * <code>-Dparam1=value1
191193 * -Dparam2=value2</code>. The first argument of the option is the key, and the 2nd argument is the value. If the option
192194 * has only one argument ({@code -Dfoo}) it is considered as a boolean flag and the value is {@code "true"}.
@@ -224,7 +226,7 @@ public Option[] getOptions() {
224226 }
225227
226228 /**
227- * Retrieve the first argument, if any, of this option.
229+ * Gets the first argument, if any, of this option.
228230 *
229231 * @param opt the character name of the option.
230232 * @return Value of the argument if option is set, and has an argument, otherwise null.
@@ -234,7 +236,7 @@ public String getOptionValue(final char opt) {
234236 }
235237
236238 /**
237- * Retrieve the argument, if any, of an option.
239+ * Gets the argument, if any, of an option.
238240 *
239241 * @param opt character name of the option
240242 * @param defaultValue is the default value to be returned if the option is not specified.
@@ -245,7 +247,7 @@ public String getOptionValue(final char opt, final String defaultValue) {
245247 }
246248
247249 /**
248- * Retrieve the first argument, if any, of this option.
250+ * Gets the first argument, if any, of this option.
249251 *
250252 * @param option the name of the option.
251253 * @return Value of the argument if option is set, and has an argument, otherwise null.
@@ -260,7 +262,7 @@ public String getOptionValue(final Option option) {
260262 }
261263
262264 /**
263- * Retrieve the first argument, if any, of an option.
265+ * Gets the first argument, if any, of an option.
264266 *
265267 * @param option name of the option.
266268 * @param defaultValue is the default value to be returned if the option is not specified.
@@ -273,7 +275,7 @@ public String getOptionValue(final Option option, final String defaultValue) {
273275 }
274276
275277 /**
276- * Retrieve the first argument, if any, of this option.
278+ * Gets the first argument, if any, of this option.
277279 *
278280 * @param opt the name of the option.
279281 * @return Value of the argument if option is set, and has an argument, otherwise null.
@@ -283,7 +285,7 @@ public String getOptionValue(final String opt) {
283285 }
284286
285287 /**
286- * Retrieve the first argument, if any, of an option.
288+ * Gets the first argument, if any, of an option.
287289 *
288290 * @param opt name of the option.
289291 * @param defaultValue is the default value to be returned if the option is not specified.
@@ -294,7 +296,7 @@ public String getOptionValue(final String opt, final String defaultValue) {
294296 }
295297
296298 /**
297- * Retrieves the array of values, if any, of an option.
299+ * Gets the array of values, if any, of an option.
298300 *
299301 * @param opt character name of the option.
300302 * @return Values of the argument if option is set, and has an argument, otherwise null.
@@ -304,7 +306,7 @@ public String[] getOptionValues(final char opt) {
304306 }
305307
306308 /**
307- * Retrieves the array of values, if any, of an option.
309+ * Gets the array of values, if any, of an option.
308310 *
309311 * @param option string name of the option.
310312 * @return Values of the argument if option is set, and has an argument, otherwise null.
@@ -323,7 +325,7 @@ public String[] getOptionValues(final Option option) {
323325 }
324326
325327 /**
326- * Retrieves the array of values, if any, of an option.
328+ * Gets the array of values, if any, of an option.
327329 *
328330 * @param opt string name of the option.
329331 * @return Values of the argument if option is set, and has an argument, otherwise null.
@@ -333,7 +335,7 @@ public String[] getOptionValues(final String opt) {
333335 }
334336
335337 /**
336- * Return a version of this {@code Option} converted to a particular type.
338+ * Gets a version of this {@code Option} converted to a particular type.
337339 *
338340 * @param opt the name of the option.
339341 * @return the value parsed into a particular object.
@@ -346,7 +348,7 @@ public Object getParsedOptionValue(final char opt) throws ParseException {
346348 }
347349
348350 /**
349- * Return a version of this {@code Option} converted to a particular type.
351+ * Gets a version of this {@code Option} converted to a particular type.
350352 *
351353 * @param option the name of the option.
352354 * @return the value parsed into a particular object.
@@ -366,7 +368,7 @@ public Object getParsedOptionValue(final Option option) throws ParseException {
366368 }
367369
368370 /**
369- * Return a version of this {@code Option} converted to a particular type.
371+ * Gets a version of this {@code Option} converted to a particular type.
370372 *
371373 * @param opt the name of the option.
372374 * @return the value parsed into a particular object.
0 commit comments