Skip to content

Commit 0469773

Browse files
Krishna MohanKrishna Mohan
authored andcommitted
adding period to javadocs
1 parent 16bc204 commit 0469773

1 file changed

Lines changed: 68 additions & 68 deletions

File tree

src/main/java/org/apache/commons/cli/CommandLine.java

Lines changed: 68 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -53,35 +53,35 @@ protected CommandLine()
5353
{
5454
// nothing to do
5555
}
56-
57-
/**
56+
57+
/**
5858
* Query to see if an option has been set.
5959
*
60-
* @param opt the option to check
61-
* @return true if set, false if not
60+
* @param opt the option to check.
61+
* @return true if set, false if not.
6262
* @since 1.5
6363
*/
6464
public boolean hasOption(final Option opt)
6565
{
6666
return options.contains(opt);
6767
}
6868

69-
/**
69+
/**
7070
* Query to see if an option has been set.
7171
*
72-
* @param opt Short name of the option
73-
* @return true if set, false if not
72+
* @param opt Short name of the option.
73+
* @return true if set, false if not.
7474
*/
7575
public boolean hasOption(final String opt)
7676
{
7777
return hasOption(resolveOption(opt));
7878
}
79-
80-
/**
79+
80+
/**
8181
* Query to see if an option has been set.
8282
*
83-
* @param opt character name of the option
84-
* @return true if set, false if not
83+
* @param opt character name of the option.
84+
* @return true if set, false if not.
8585
*/
8686
public boolean hasOption(final char opt)
8787
{
@@ -91,8 +91,8 @@ public boolean hasOption(final char opt)
9191
/**
9292
* Return the <code>Object</code> type of this <code>Option</code>.
9393
*
94-
* @param opt the name of the option
95-
* @return the type of this <code>Option</code>
94+
* @param opt the name of the option.
95+
* @return the type of this <code>Option</code>.
9696
* @deprecated due to System.err message. Instead use getParsedOptionValue(String)
9797
*/
9898
@Deprecated
@@ -108,12 +108,12 @@ public Object getOptionObject(final String opt)
108108
return null;
109109
}
110110
}
111-
111+
112112
/**
113-
* Return a version of this <code>Option</code> converted to a particular type.
113+
* Return a version of this <code>Option</code> converted to a particular type.
114114
*
115-
* @param option the name of the option
116-
* @return the value parsed into a particular object
115+
* @param option the name of the option.
116+
* @return the value parsed into a particular object.
117117
* @throws ParseException if there are problems turning the option value into the desired type
118118
* @see PatternOptionBuilder
119119
* @since 1.5
@@ -133,10 +133,10 @@ public Object getParsedOptionValue(final Option option) throws ParseException
133133
}
134134

135135
/**
136-
* Return a version of this <code>Option</code> converted to a particular type.
136+
* Return a version of this <code>Option</code> converted to a particular type.
137137
*
138-
* @param opt the name of the option
139-
* @return the value parsed into a particular object
138+
* @param opt the name of the option.
139+
* @return the value parsed into a particular object.
140140
* @throws ParseException if there are problems turning the option value into the desired type
141141
* @see PatternOptionBuilder
142142
* @since 1.2
@@ -145,12 +145,12 @@ public Object getParsedOptionValue(final String opt) throws ParseException
145145
{
146146
return getParsedOptionValue(resolveOption(opt));
147147
}
148-
148+
149149
/**
150-
* Return a version of this <code>Option</code> converted to a particular type.
150+
* Return a version of this <code>Option</code> converted to a particular type.
151151
*
152-
* @param opt the name of the option
153-
* @return the value parsed into a particular object
152+
* @param opt the name of the option.
153+
* @return the value parsed into a particular object.
154154
* @throws ParseException if there are problems turning the option value into the desired type
155155
* @see PatternOptionBuilder
156156
* @since 1.5
@@ -164,18 +164,18 @@ public Object getParsedOptionValue(final char opt) throws ParseException
164164
* Return the <code>Object</code> type of this <code>Option</code>.
165165
*
166166
* @deprecated due to System.err message. Instead use getParsedOptionValue(char)
167-
* @param opt the name of the option
168-
* @return the type of opt
167+
* @param opt the name of the option.
168+
* @return the type of opt.
169169
*/
170170
public Object getOptionObject(final char opt)
171171
{
172172
return getOptionObject(String.valueOf(opt));
173173
}
174-
175-
/**
174+
175+
/**
176176
* Retrieve the first argument, if any, of this option.
177177
*
178-
* @param option the name of the option
178+
* @param option the name of the option.
179179
* @return Value of the argument if option is set, and has an argument,
180180
* otherwise null.
181181
* @since 1.5
@@ -190,10 +190,10 @@ public String getOptionValue(final Option option)
190190
return (values == null) ? null : values[0];
191191
}
192192

193-
/**
193+
/**
194194
* Retrieve the first argument, if any, of this option.
195195
*
196-
* @param opt the name of the option
196+
* @param opt the name of the option.
197197
* @return Value of the argument if option is set, and has an argument,
198198
* otherwise null.
199199
*/
@@ -202,22 +202,22 @@ public String getOptionValue(final String opt)
202202
return getOptionValue(resolveOption(opt));
203203
}
204204

205-
/**
205+
/**
206206
* Retrieve the first argument, if any, of this option.
207207
*
208-
* @param opt the character name of the option
208+
* @param opt the character name of the option.
209209
* @return Value of the argument if option is set, and has an argument,
210210
* otherwise null.
211211
*/
212212
public String getOptionValue(final char opt)
213213
{
214214
return getOptionValue(String.valueOf(opt));
215215
}
216-
217-
/**
216+
217+
/**
218218
* Retrieves the array of values, if any, of an option.
219219
*
220-
* @param option string name of the option
220+
* @param option string name of the option.
221221
* @return Values of the argument if option is set, and has an argument,
222222
* otherwise null.
223223
* @since 1.5
@@ -237,10 +237,10 @@ public String[] getOptionValues(final Option option)
237237
return values.isEmpty() ? null : values.toArray(new String[values.size()]);
238238
}
239239

240-
/**
240+
/**
241241
* Retrieves the array of values, if any, of an option.
242242
*
243-
* @param opt string name of the option
243+
* @param opt string name of the option.
244244
* @return Values of the argument if option is set, and has an argument,
245245
* otherwise null.
246246
*/
@@ -251,9 +251,9 @@ public String[] getOptionValues(final String opt)
251251

252252
/**
253253
* Retrieves the option object given the long or short option as a String
254-
*
255-
* @param opt short or long name of the option
256-
* @return Canonicalized option
254+
*
255+
* @param opt short or long name of the option.
256+
* @return Canonicalized option.
257257
*/
258258
private Option resolveOption(String opt)
259259
{
@@ -274,24 +274,24 @@ private Option resolveOption(String opt)
274274
return null;
275275
}
276276

277-
/**
277+
/**
278278
* Retrieves the array of values, if any, of an option.
279279
*
280-
* @param opt character name of the option
280+
* @param opt character name of the option.
281281
* @return Values of the argument if option is set, and has an argument,
282282
* otherwise null.
283283
*/
284284
public String[] getOptionValues(final char opt)
285285
{
286286
return getOptionValues(String.valueOf(opt));
287287
}
288-
289-
/**
288+
289+
/**
290290
* Retrieve the first argument, if any, of an option.
291291
*
292-
* @param option name of the option
292+
* @param option name of the option.
293293
* @param defaultValue is the default value to be returned if the option
294-
* is not specified
294+
* is not specified.
295295
* @return Value of the argument if option is set, and has an argument,
296296
* otherwise <code>defaultValue</code>.
297297
* @since 1.5
@@ -302,12 +302,12 @@ public String getOptionValue(final Option option, final String defaultValue)
302302
return (answer != null) ? answer : defaultValue;
303303
}
304304

305-
/**
305+
/**
306306
* Retrieve the first argument, if any, of an option.
307307
*
308-
* @param opt name of the option
308+
* @param opt name of the option.
309309
* @param defaultValue is the default value to be returned if the option
310-
* is not specified
310+
* is not specified.
311311
* @return Value of the argument if option is set, and has an argument,
312312
* otherwise <code>defaultValue</code>.
313313
*/
@@ -316,20 +316,20 @@ public String getOptionValue(final String opt, final String defaultValue)
316316
return getOptionValue(resolveOption(opt), defaultValue);
317317
}
318318

319-
/**
319+
/**
320320
* Retrieve the argument, if any, of an option.
321321
*
322322
* @param opt character name of the option
323323
* @param defaultValue is the default value to be returned if the option
324-
* is not specified
324+
* is not specified.
325325
* @return Value of the argument if option is set, and has an argument,
326326
* otherwise <code>defaultValue</code>.
327327
*/
328328
public String getOptionValue(final char opt, final String defaultValue)
329329
{
330330
return getOptionValue(String.valueOf(opt), defaultValue);
331331
}
332-
332+
333333
/**
334334
* Retrieve the map of values associated to the option. This is convenient
335335
* for options specifying Java properties like <tt>-Dparam1=value1
@@ -338,9 +338,9 @@ public String getOptionValue(final char opt, final String defaultValue)
338338
* (<tt>-Dfoo</tt>) it is considered as a boolean flag and the value is
339339
* <tt>"true"</tt>.
340340
*
341-
* @param option name of the option
341+
* @param option name of the option.
342342
* @return The Properties mapped by the option, never <tt>null</tt>
343-
* even if the option doesn't exists
343+
* even if the option doesn't exists.
344344
* @since 1.5
345345
*/
346346
public Properties getOptionProperties(final Option option)
@@ -376,9 +376,9 @@ else if (values.size() == 1)
376376
* (<tt>-Dfoo</tt>) it is considered as a boolean flag and the value is
377377
* <tt>"true"</tt>.
378378
*
379-
* @param opt name of the option
379+
* @param opt name of the option.
380380
* @return The Properties mapped by the option, never <tt>null</tt>
381-
* even if the option doesn't exists
381+
* even if the option doesn't exists.
382382
* @since 1.2
383383
*/
384384
public Properties getOptionProperties(final String opt)
@@ -406,10 +406,10 @@ else if (values.size() == 1)
406406
return props;
407407
}
408408

409-
/**
409+
/**
410410
* Retrieve any left-over non-recognized options and arguments
411411
*
412-
* @return remaining items passed in but not parsed as an array
412+
* @return remaining items passed in but not parsed as an array.
413413
*/
414414
public String[] getArgs()
415415
{
@@ -420,7 +420,7 @@ public String[] getArgs()
420420
return answer;
421421
}
422422

423-
/**
423+
/**
424424
* Retrieve any left-over non-recognized options and arguments
425425
*
426426
* @return remaining items passed in but not parsed as a <code>List</code>.
@@ -430,24 +430,24 @@ public List<String> getArgList()
430430
return args;
431431
}
432432

433-
/**
433+
/**
434434
* jkeyes
435435
* - commented out until it is implemented properly
436436
* <p>Dump state, suitable for debugging.</p>
437437
*
438-
* @return Stringified form of this object
438+
* @return Stringified form of this object.
439439
*/
440440

441441
/*
442442
public String toString() {
443443
StringBuilder buf = new StringBuilder();
444-
444+
445445
buf.append("[ CommandLine: [ options: ");
446446
buf.append(options.toString());
447447
buf.append(" ] [ args: ");
448448
buf.append(args.toString());
449449
buf.append(" ] ]");
450-
450+
451451
return buf.toString();
452452
}
453453
*/
@@ -465,7 +465,7 @@ protected void addArg(final String arg)
465465
/**
466466
* Add an option to the command line. The values of the option are stored.
467467
*
468-
* @param opt the processed option
468+
* @param opt the processed option.
469469
*/
470470
protected void addOption(final Option opt)
471471
{
@@ -476,7 +476,7 @@ protected void addOption(final Option opt)
476476
* Returns an iterator over the Option members of CommandLine.
477477
*
478478
* @return an <code>Iterator</code> over the processed {@link Option}
479-
* members of this {@link CommandLine}
479+
* members of this {@link CommandLine}.
480480
*/
481481
public Iterator<Option> iterator()
482482
{
@@ -502,7 +502,7 @@ public Option[] getOptions()
502502
/**
503503
* A nested builder class to create <code>CommandLine</code> instance
504504
* using descriptive methods.
505-
*
505+
*
506506
* @since 1.4
507507
*/
508508
public static final class Builder
@@ -515,7 +515,7 @@ public static final class Builder
515515
/**
516516
* Add an option to the command line. The values of the option are stored.
517517
*
518-
* @param opt the processed option
518+
* @param opt the processed option.
519519
*
520520
* @return this Builder instance for method chaining.
521521
*/

0 commit comments

Comments
 (0)