@@ -469,47 +469,47 @@ private void handleProperties(final Properties properties) throws ParseException
469469 *
470470 * -L -LV -L V -L=V -l
471471 *
472- * @param token the command line token to handle
472+ * @param hyphenToken the command line token to handle
473473 */
474- private void handleShortAndLongOption (final String token ) throws ParseException {
475- final String t = Util .stripLeadingHyphens (token );
476- final int pos = indexOfEqual (t );
477- if (t .length () == 1 ) {
474+ private void handleShortAndLongOption (final String hyphenToken ) throws ParseException {
475+ final String token = Util .stripLeadingHyphens (hyphenToken );
476+ final int pos = indexOfEqual (token );
477+ if (token .length () == 1 ) {
478478 // -S
479- if (options .hasShortOption (t )) {
480- handleOption (options .getOption (t ));
479+ if (options .hasShortOption (token )) {
480+ handleOption (options .getOption (token ));
481481 } else {
482- handleUnknownToken (token );
482+ handleUnknownToken (hyphenToken );
483483 }
484484 } else if (pos == -1 ) {
485485 // no equal sign found (-xxx)
486- if (options .hasShortOption (t )) {
487- handleOption (options .getOption (t ));
488- } else if (!getMatchingLongOptions (t ).isEmpty ()) {
486+ if (options .hasShortOption (token )) {
487+ handleOption (options .getOption (token ));
488+ } else if (!getMatchingLongOptions (token ).isEmpty ()) {
489489 // -L or -l
490- handleLongOptionWithoutEqual (token );
490+ handleLongOptionWithoutEqual (hyphenToken );
491491 } else {
492492 // look for a long prefix (-Xmx512m)
493- final String opt = getLongPrefix (t );
493+ final String opt = getLongPrefix (token );
494494
495495 if (opt != null && options .getOption (opt ).acceptsArg ()) {
496496 handleOption (options .getOption (opt ));
497- currentOption .processValue (stripLeadingAndTrailingQuotesDefaultOff (t .substring (opt .length ())));
497+ currentOption .processValue (stripLeadingAndTrailingQuotesDefaultOff (token .substring (opt .length ())));
498498 currentOption = null ;
499- } else if (isJavaProperty (t )) {
499+ } else if (isJavaProperty (token )) {
500500 // -SV1 (-Dflag)
501- handleOption (options .getOption (t .substring (0 , 1 )));
502- currentOption .processValue (stripLeadingAndTrailingQuotesDefaultOff (t .substring (1 )));
501+ handleOption (options .getOption (token .substring (0 , 1 )));
502+ currentOption .processValue (stripLeadingAndTrailingQuotesDefaultOff (token .substring (1 )));
503503 currentOption = null ;
504504 } else {
505505 // -S1S2S3 or -S1S2V
506- handleConcatenatedOptions (token );
506+ handleConcatenatedOptions (hyphenToken );
507507 }
508508 }
509509 } else {
510510 // equal sign found (-xxx=yyy)
511- final String opt = t .substring (0 , pos );
512- final String value = t .substring (pos + 1 );
511+ final String opt = token .substring (0 , pos );
512+ final String value = token .substring (pos + 1 );
513513
514514 if (opt .length () == 1 ) {
515515 // -S=V
@@ -519,7 +519,7 @@ private void handleShortAndLongOption(final String token) throws ParseException
519519 currentOption .processValue (value );
520520 currentOption = null ;
521521 } else {
522- handleUnknownToken (token );
522+ handleUnknownToken (hyphenToken );
523523 }
524524 } else if (isJavaProperty (opt )) {
525525 // -SV1=V2 (-Dkey=value)
@@ -529,7 +529,7 @@ private void handleShortAndLongOption(final String token) throws ParseException
529529 currentOption = null ;
530530 } else {
531531 // -L=V or -l=V
532- handleLongOptionWithEqual (token );
532+ handleLongOptionWithEqual (hyphenToken );
533533 }
534534 }
535535 }
0 commit comments