You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@commons.apache.org by br...@apache.org on 2017/06/08 17:47:21 UTC
svn commit: r1013656 [31/45] - in
/websites/production/commons/content/proper/commons-cli: ./ apidocs/
apidocs/org/apache/commons/cli/ apidocs/org/apache/commons/cli/class-use/
apidocs/resources/ apidocs/src-html/org/apache/commons/cli/
jacoco-aggregat...
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Option.java.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Option.java.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Option.java.html Thu Jun 8 17:47:18 2017
@@ -37,7 +37,7 @@ import java.util.List;
* @see org.apache.commons.cli.Options
* @see org.apache.commons.cli.CommandLine
*
- * @version $Id: Option.java 1756753 2016-08-18 10:18:43Z britter $
+ * @version $Id$
*/
public class Option implements Cloneable, Serializable
{
@@ -108,7 +108,7 @@ public class Option implements Cloneable
* @throws IllegalArgumentException if there are any non valid
* Option characters in <code>opt</code>.
*/
- public Option(String opt, String description) throws IllegalArgumentException
+ public Option(final String opt, final String description) throws IllegalArgumentException
{
<span class="fc" id="L113"> this(opt, null, false, description);</span>
<span class="fc" id="L114"> }</span>
@@ -123,7 +123,7 @@ public class Option implements Cloneable
* @throws IllegalArgumentException if there are any non valid
* Option characters in <code>opt</code>.
*/
- public Option(String opt, boolean hasArg, String description) throws IllegalArgumentException
+ public Option(final String opt, final boolean hasArg, final String description) throws IllegalArgumentException
{
<span class="fc" id="L128"> this(opt, null, hasArg, description);</span>
<span class="fc" id="L129"> }</span>
@@ -139,7 +139,7 @@ public class Option implements Cloneable
* @throws IllegalArgumentException if there are any non valid
* Option characters in <code>opt</code>.
*/
- public Option(String opt, String longOpt, boolean hasArg, String description)
+ public Option(final String opt, final String longOpt, final boolean hasArg, final String description)
throws IllegalArgumentException
<span class="fc" id="L144"> {</span>
// ensure that the option is valid
@@ -215,7 +215,7 @@ public class Option implements Cloneable
* @deprecated since 1.3, use {@link #setType(Class)} instead
*/
@Deprecated
- public void setType(Object type)
+ public void setType(final Object type)
{
<span class="nc" id="L220"> setType((Class<?>) type);</span>
<span class="nc" id="L221"> }</span>
@@ -226,7 +226,7 @@ public class Option implements Cloneable
* @param type the type of this Option
* @since 1.3
*/
- public void setType(Class<?> type)
+ public void setType(final Class<?> type)
{
<span class="fc" id="L231"> this.type = type;</span>
<span class="fc" id="L232"> }</span>
@@ -246,7 +246,7 @@ public class Option implements Cloneable
*
* @param longOpt the long name of this Option
*/
- public void setLongOpt(String longOpt)
+ public void setLongOpt(final String longOpt)
{
<span class="fc" id="L251"> this.longOpt = longOpt;</span>
<span class="fc" id="L252"> }</span>
@@ -257,7 +257,7 @@ public class Option implements Cloneable
* @param optionalArg specifies whether the Option can have
* an optional argument.
*/
- public void setOptionalArg(boolean optionalArg)
+ public void setOptionalArg(final boolean optionalArg)
{
<span class="fc" id="L262"> this.optionalArg = optionalArg;</span>
<span class="fc" id="L263"> }</span>
@@ -306,7 +306,7 @@ public class Option implements Cloneable
* @param description The description of this option
* @since 1.1
*/
- public void setDescription(String description)
+ public void setDescription(final String description)
{
<span class="fc" id="L311"> this.description = description;</span>
<span class="fc" id="L312"> }</span>
@@ -326,7 +326,7 @@ public class Option implements Cloneable
*
* @param required specifies whether this Option is mandatory
*/
- public void setRequired(boolean required)
+ public void setRequired(final boolean required)
{
<span class="fc" id="L331"> this.required = required;</span>
<span class="fc" id="L332"> }</span>
@@ -336,7 +336,7 @@ public class Option implements Cloneable
*
* @param argName the display name for the argument value.
*/
- public void setArgName(String argName)
+ public void setArgName(final String argName)
{
<span class="fc" id="L341"> this.argName = argName;</span>
<span class="fc" id="L342"> }</span>
@@ -376,7 +376,7 @@ public class Option implements Cloneable
*
* @param num the number of argument values
*/
- public void setArgs(int num)
+ public void setArgs(final int num)
{
<span class="fc" id="L381"> this.numberOfArgs = num;</span>
<span class="fc" id="L382"> }</span>
@@ -387,7 +387,7 @@ public class Option implements Cloneable
*
* @param sep The value separator.
*/
- public void setValueSeparator(char sep)
+ public void setValueSeparator(final char sep)
{
<span class="fc" id="L392"> this.valuesep = sep;</span>
<span class="fc" id="L393"> }</span>
@@ -437,7 +437,7 @@ public class Option implements Cloneable
*
* @param value is a/the value of this Option
*/
- void addValueForProcessing(String value)
+ void addValueForProcessing(final String value)
{
<span class="pc bpc" id="L442" title="1 of 2 branches missed."> if (numberOfArgs == UNINITIALIZED)</span>
{
@@ -463,7 +463,7 @@ public class Option implements Cloneable
<span class="fc bfc" id="L463" title="All 2 branches covered."> if (hasValueSeparator())</span>
{
// get the separator character
-<span class="fc" id="L466"> char sep = getValueSeparator();</span>
+<span class="fc" id="L466"> final char sep = getValueSeparator();</span>
// store the index for the value separator
<span class="fc" id="L469"> int index = value.indexOf(sep);</span>
@@ -501,7 +501,7 @@ public class Option implements Cloneable
*
* @since 1.0.1
*/
- private void add(String value)
+ private void add(final String value)
{
<span class="fc bfc" id="L506" title="All 2 branches covered."> if (!acceptsArg())</span>
{
@@ -536,7 +536,7 @@ public class Option implements Cloneable
* @throws IndexOutOfBoundsException if index is less than 1
* or greater than the number of the values for this Option.
*/
- public String getValue(int index) throws IndexOutOfBoundsException
+ public String getValue(final int index) throws IndexOutOfBoundsException
{
<span class="fc bfc" id="L541" title="All 2 branches covered."> return hasNoValues() ? null : values.get(index);</span>
}
@@ -551,9 +551,9 @@ public class Option implements Cloneable
* @return the value/first value of this Option or the
* <code>defaultValue</code> if there are no values.
*/
- public String getValue(String defaultValue)
+ public String getValue(final String defaultValue)
{
-<span class="fc" id="L556"> String value = getValue();</span>
+<span class="fc" id="L556"> final String value = getValue();</span>
<span class="fc bfc" id="L558" title="All 2 branches covered."> return (value != null) ? value : defaultValue;</span>
}
@@ -587,7 +587,7 @@ public class Option implements Cloneable
@Override
public String toString()
{
-<span class="fc" id="L590"> StringBuilder buf = new StringBuilder().append("[ option: ");</span>
+<span class="fc" id="L590"> final StringBuilder buf = new StringBuilder().append("[ option: ");</span>
<span class="fc" id="L592"> buf.append(opt);</span>
@@ -630,7 +630,7 @@ public class Option implements Cloneable
}
@Override
- public boolean equals(Object o)
+ public boolean equals(final Object o)
{
<span class="fc bfc" id="L635" title="All 2 branches covered."> if (this == o)</span>
{
@@ -641,28 +641,27 @@ public class Option implements Cloneable
<span class="nc" id="L641"> return false;</span>
}
-<span class="fc" id="L644"> Option option = (Option) o;</span>
+<span class="fc" id="L644"> final Option option = (Option) o;</span>
-
-<span class="fc bfc" id="L647" title="All 6 branches covered."> if (opt != null ? !opt.equals(option.opt) : option.opt != null)</span>
+<span class="fc bfc" id="L646" title="All 6 branches covered."> if (opt != null ? !opt.equals(option.opt) : option.opt != null)</span>
{
-<span class="fc" id="L649"> return false;</span>
+<span class="fc" id="L648"> return false;</span>
}
-<span class="pc bpc" id="L651" title="1 of 6 branches missed."> if (longOpt != null ? !longOpt.equals(option.longOpt) : option.longOpt != null)</span>
+<span class="pc bpc" id="L650" title="1 of 6 branches missed."> if (longOpt != null ? !longOpt.equals(option.longOpt) : option.longOpt != null)</span>
{
-<span class="fc" id="L653"> return false;</span>
+<span class="fc" id="L652"> return false;</span>
}
-<span class="fc" id="L656"> return true;</span>
+<span class="fc" id="L655"> return true;</span>
}
@Override
public int hashCode()
{
int result;
-<span class="fc bfc" id="L663" title="All 2 branches covered."> result = opt != null ? opt.hashCode() : 0;</span>
-<span class="fc bfc" id="L664" title="All 2 branches covered."> result = 31 * result + (longOpt != null ? longOpt.hashCode() : 0);</span>
-<span class="fc" id="L665"> return result;</span>
+<span class="fc bfc" id="L662" title="All 2 branches covered."> result = opt != null ? opt.hashCode() : 0;</span>
+<span class="fc bfc" id="L663" title="All 2 branches covered."> result = 31 * result + (longOpt != null ? longOpt.hashCode() : 0);</span>
+<span class="fc" id="L664"> return result;</span>
}
/**
@@ -682,13 +681,13 @@ public class Option implements Cloneable
{
try
{
-<span class="fc" id="L685"> Option option = (Option) super.clone();</span>
-<span class="fc" id="L686"> option.values = new ArrayList<String>(values);</span>
-<span class="fc" id="L687"> return option;</span>
+<span class="fc" id="L684"> final Option option = (Option) super.clone();</span>
+<span class="fc" id="L685"> option.values = new ArrayList<String>(values);</span>
+<span class="fc" id="L686"> return option;</span>
}
-<span class="nc" id="L689"> catch (CloneNotSupportedException cnse)</span>
+<span class="nc" id="L688"> catch (final CloneNotSupportedException cnse)</span>
{
-<span class="nc" id="L691"> throw new RuntimeException("A CloneNotSupportedException was thrown: " + cnse.getMessage());</span>
+<span class="nc" id="L690"> throw new RuntimeException("A CloneNotSupportedException was thrown: " + cnse.getMessage());</span>
}
}
@@ -700,8 +699,8 @@ public class Option implements Cloneable
*/
void clearValues()
{
-<span class="fc" id="L703"> values.clear();</span>
-<span class="fc" id="L704"> }</span>
+<span class="fc" id="L702"> values.clear();</span>
+<span class="fc" id="L703"> }</span>
/**
* This method is not intended to be used. It was a piece of internal
@@ -713,9 +712,9 @@ public class Option implements Cloneable
* @deprecated
*/
@Deprecated
- public boolean addValue(String value)
+ public boolean addValue(final String value)
{
-<span class="nc" id="L718"> throw new UnsupportedOperationException("The addValue method is not intended for client use. "</span>
+<span class="nc" id="L717"> throw new UnsupportedOperationException("The addValue method is not intended for client use. "</span>
+ "Subclasses should use the addValueForProcessing method instead. ");
}
@@ -727,7 +726,7 @@ public class Option implements Cloneable
*/
boolean acceptsArg()
{
-<span class="pc bpc" id="L730" title="2 of 10 branches missed."> return (hasArg() || hasArgs() || hasOptionalArg()) && (numberOfArgs <= 0 || values.size() < numberOfArgs);</span>
+<span class="pc bpc" id="L729" title="2 of 10 branches missed."> return (hasArg() || hasArgs() || hasOptionalArg()) && (numberOfArgs <= 0 || values.size() < numberOfArgs);</span>
}
/**
@@ -738,15 +737,15 @@ public class Option implements Cloneable
*/
boolean requiresArg()
{
-<span class="fc bfc" id="L741" title="All 2 branches covered."> if (optionalArg)</span>
+<span class="fc bfc" id="L740" title="All 2 branches covered."> if (optionalArg)</span>
{
-<span class="fc" id="L743"> return false;</span>
+<span class="fc" id="L742"> return false;</span>
}
-<span class="fc bfc" id="L745" title="All 2 branches covered."> if (numberOfArgs == UNLIMITED_VALUES)</span>
+<span class="fc bfc" id="L744" title="All 2 branches covered."> if (numberOfArgs == UNLIMITED_VALUES)</span>
{
-<span class="fc" id="L747"> return values.isEmpty();</span>
+<span class="fc" id="L746"> return values.isEmpty();</span>
}
-<span class="fc" id="L749"> return acceptsArg();</span>
+<span class="fc" id="L748"> return acceptsArg();</span>
}
/**
@@ -758,7 +757,7 @@ public class Option implements Cloneable
*/
public static Builder builder()
{
-<span class="fc" id="L761"> return builder(null);</span>
+<span class="fc" id="L760"> return builder(null);</span>
}
/**
@@ -772,7 +771,7 @@ public class Option implements Cloneable
*/
public static Builder builder(final String opt)
{
-<span class="fc" id="L775"> return new Builder(opt);</span>
+<span class="fc" id="L774"> return new Builder(opt);</span>
}
/**
@@ -810,10 +809,10 @@ public class Option implements Cloneable
private boolean optionalArg;
/** the number of argument values this option can have */
-<span class="fc" id="L813"> private int numberOfArgs = UNINITIALIZED;</span>
+<span class="fc" id="L812"> private int numberOfArgs = UNINITIALIZED;</span>
/** the type of this Option */
-<span class="fc" id="L816"> private Class<?> type = String.class;</span>
+<span class="fc" id="L815"> private Class<?> type = String.class;</span>
/** the character that is the value separator */
private char valuesep;
@@ -826,10 +825,10 @@ public class Option implements Cloneable
* @throws IllegalArgumentException if there are any non valid Option characters in {@code opt}
*/
private Builder(final String opt) throws IllegalArgumentException
-<span class="fc" id="L829"> {</span>
-<span class="fc" id="L830"> OptionValidator.validateOption(opt);</span>
-<span class="fc" id="L831"> this.opt = opt;</span>
-<span class="fc" id="L832"> }</span>
+<span class="fc" id="L828"> {</span>
+<span class="fc" id="L829"> OptionValidator.validateOption(opt);</span>
+<span class="fc" id="L830"> this.opt = opt;</span>
+<span class="fc" id="L831"> }</span>
/**
* Sets the display name for the argument value.
@@ -839,8 +838,8 @@ public class Option implements Cloneable
*/
public Builder argName(final String argName)
{
-<span class="fc" id="L842"> this.argName = argName;</span>
-<span class="fc" id="L843"> return this;</span>
+<span class="fc" id="L841"> this.argName = argName;</span>
+<span class="fc" id="L842"> return this;</span>
}
/**
@@ -851,8 +850,8 @@ public class Option implements Cloneable
*/
public Builder desc(final String description)
{
-<span class="fc" id="L854"> this.description = description;</span>
-<span class="fc" id="L855"> return this;</span>
+<span class="fc" id="L853"> this.description = description;</span>
+<span class="fc" id="L854"> return this;</span>
}
/**
@@ -863,8 +862,8 @@ public class Option implements Cloneable
*/
public Builder longOpt(final String longOpt)
{
-<span class="fc" id="L866"> this.longOpt = longOpt;</span>
-<span class="fc" id="L867"> return this;</span>
+<span class="fc" id="L865"> this.longOpt = longOpt;</span>
+<span class="fc" id="L866"> return this;</span>
}
/**
@@ -875,8 +874,8 @@ public class Option implements Cloneable
*/
public Builder numberOfArgs(final int numberOfArgs)
{
-<span class="fc" id="L878"> this.numberOfArgs = numberOfArgs;</span>
-<span class="fc" id="L879"> return this;</span>
+<span class="fc" id="L877"> this.numberOfArgs = numberOfArgs;</span>
+<span class="fc" id="L878"> return this;</span>
}
/**
@@ -888,8 +887,8 @@ public class Option implements Cloneable
*/
public Builder optionalArg(final boolean isOptional)
{
-<span class="fc" id="L891"> this.optionalArg = isOptional;</span>
-<span class="fc" id="L892"> return this;</span>
+<span class="fc" id="L890"> this.optionalArg = isOptional;</span>
+<span class="fc" id="L891"> return this;</span>
}
/**
@@ -899,7 +898,7 @@ public class Option implements Cloneable
*/
public Builder required()
{
-<span class="fc" id="L902"> return required(true);</span>
+<span class="fc" id="L901"> return required(true);</span>
}
/**
@@ -910,8 +909,8 @@ public class Option implements Cloneable
*/
public Builder required(final boolean required)
{
-<span class="fc" id="L913"> this.required = required;</span>
-<span class="fc" id="L914"> return this;</span>
+<span class="fc" id="L912"> this.required = required;</span>
+<span class="fc" id="L913"> return this;</span>
}
/**
@@ -922,8 +921,8 @@ public class Option implements Cloneable
*/
public Builder type(final Class<?> type)
{
-<span class="fc" id="L925"> this.type = type;</span>
-<span class="fc" id="L926"> return this;</span>
+<span class="fc" id="L924"> this.type = type;</span>
+<span class="fc" id="L925"> return this;</span>
}
/**
@@ -933,7 +932,7 @@ public class Option implements Cloneable
*/
public Builder valueSeparator()
{
-<span class="fc" id="L936"> return valueSeparator('=');</span>
+<span class="fc" id="L935"> return valueSeparator('=');</span>
}
/**
@@ -959,8 +958,8 @@ public class Option implements Cloneable
*/
public Builder valueSeparator(final char sep)
{
-<span class="fc" id="L962"> valuesep = sep;</span>
-<span class="fc" id="L963"> return this;</span>
+<span class="fc" id="L961"> valuesep = sep;</span>
+<span class="fc" id="L962"> return this;</span>
}
/**
@@ -970,7 +969,7 @@ public class Option implements Cloneable
*/
public Builder hasArg()
{
-<span class="fc" id="L973"> return hasArg(true);</span>
+<span class="fc" id="L972"> return hasArg(true);</span>
}
/**
@@ -982,8 +981,8 @@ public class Option implements Cloneable
public Builder hasArg(final boolean hasArg)
{
// set to UNINITIALIZED when no arg is specified to be compatible with OptionBuilder
-<span class="fc bfc" id="L985" title="All 2 branches covered."> numberOfArgs = hasArg ? 1 : Option.UNINITIALIZED;</span>
-<span class="fc" id="L986"> return this;</span>
+<span class="fc bfc" id="L984" title="All 2 branches covered."> numberOfArgs = hasArg ? 1 : Option.UNINITIALIZED;</span>
+<span class="fc" id="L985"> return this;</span>
}
/**
@@ -993,8 +992,8 @@ public class Option implements Cloneable
*/
public Builder hasArgs()
{
-<span class="nc" id="L996"> numberOfArgs = Option.UNLIMITED_VALUES;</span>
-<span class="nc" id="L997"> return this;</span>
+<span class="nc" id="L995"> numberOfArgs = Option.UNLIMITED_VALUES;</span>
+<span class="nc" id="L996"> return this;</span>
}
/**
@@ -1005,11 +1004,11 @@ public class Option implements Cloneable
*/
public Option build()
{
-<span class="fc bfc" id="L1008" title="All 4 branches covered."> if (opt == null && longOpt == null)</span>
+<span class="fc bfc" id="L1007" title="All 4 branches covered."> if (opt == null && longOpt == null)</span>
{
-<span class="fc" id="L1010"> throw new IllegalArgumentException("Either opt or longOpt must be specified");</span>
+<span class="fc" id="L1009"> throw new IllegalArgumentException("Either opt or longOpt must be specified");</span>
}
-<span class="fc" id="L1012"> return new Option(this);</span>
+<span class="fc" id="L1011"> return new Option(this);</span>
}
}
}
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionBuilder.java.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionBuilder.java.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionBuilder.java.html Thu Jun 8 17:47:18 2017
@@ -25,7 +25,7 @@ package org.apache.commons.cli;
* <p>
* This class is NOT thread safe. See <a href="https://issues.apache.org/jira/browse/CLI-209">CLI-209</a>
*
- * @version $Id: OptionBuilder.java 1677400 2015-05-03 13:46:08Z britter $
+ * @version $Id$
* @since 1.0
* @deprecated since 1.3, use {@link Option#builder(String)} instead
*/
@@ -94,7 +94,7 @@ public final class OptionBuilder
* @param newLongopt the long option value
* @return the OptionBuilder instance
*/
- public static OptionBuilder withLongOpt(String newLongopt)
+ public static OptionBuilder withLongOpt(final String newLongopt)
{
<span class="fc" id="L99"> OptionBuilder.longopt = newLongopt;</span>
@@ -120,7 +120,7 @@ public final class OptionBuilder
* @param hasArg if true then the Option has an argument value
* @return the OptionBuilder instance
*/
- public static OptionBuilder hasArg(boolean hasArg)
+ public static OptionBuilder hasArg(final boolean hasArg)
{
<span class="fc bfc" id="L125" title="All 2 branches covered."> OptionBuilder.numberOfArgs = hasArg ? 1 : Option.UNINITIALIZED;</span>
@@ -133,7 +133,7 @@ public final class OptionBuilder
* @param name the name for the argument value
* @return the OptionBuilder instance
*/
- public static OptionBuilder withArgName(String name)
+ public static OptionBuilder withArgName(final String name)
{
<span class="fc" id="L138"> OptionBuilder.argName = name;</span>
@@ -171,7 +171,7 @@ public final class OptionBuilder
*
* @return the OptionBuilder instance
*/
- public static OptionBuilder withValueSeparator(char sep)
+ public static OptionBuilder withValueSeparator(final char sep)
{
<span class="fc" id="L176"> OptionBuilder.valuesep = sep;</span>
@@ -208,7 +208,7 @@ public final class OptionBuilder
* @param newRequired if true then the Option is required
* @return the OptionBuilder instance
*/
- public static OptionBuilder isRequired(boolean newRequired)
+ public static OptionBuilder isRequired(final boolean newRequired)
{
<span class="nc" id="L213"> OptionBuilder.required = newRequired;</span>
@@ -233,7 +233,7 @@ public final class OptionBuilder
* @param num the number of args that the option can have
* @return the OptionBuilder instance
*/
- public static OptionBuilder hasArgs(int num)
+ public static OptionBuilder hasArgs(final int num)
{
<span class="fc" id="L238"> OptionBuilder.numberOfArgs = num;</span>
@@ -273,7 +273,7 @@ public final class OptionBuilder
* the next Option created can have.
* @return the OptionBuilder instance
*/
- public static OptionBuilder hasOptionalArgs(int numArgs)
+ public static OptionBuilder hasOptionalArgs(final int numArgs)
{
<span class="fc" id="L278"> OptionBuilder.numberOfArgs = numArgs;</span>
<span class="fc" id="L279"> OptionBuilder.optionalArg = true;</span>
@@ -293,7 +293,7 @@ public final class OptionBuilder
* @deprecated since 1.3, use {@link #withType(Class)} instead
*/
@Deprecated
- public static OptionBuilder withType(Object newType)
+ public static OptionBuilder withType(final Object newType)
{
<span class="nc" id="L298"> return withType((Class<?>) newType);</span>
}
@@ -306,7 +306,7 @@ public final class OptionBuilder
* @return the OptionBuilder instance
* @since 1.3
*/
- public static OptionBuilder withType(Class<?> newType)
+ public static OptionBuilder withType(final Class<?> newType)
{
<span class="fc" id="L311"> OptionBuilder.type = newType;</span>
@@ -319,7 +319,7 @@ public final class OptionBuilder
* @param newDescription a description of the Option's purpose
* @return the OptionBuilder instance
*/
- public static OptionBuilder withDescription(String newDescription)
+ public static OptionBuilder withDescription(final String newDescription)
{
<span class="fc" id="L324"> OptionBuilder.description = newDescription;</span>
@@ -335,7 +335,7 @@ public final class OptionBuilder
* @throws IllegalArgumentException if <code>opt</code> is not
* a valid character. See Option.
*/
- public static Option create(char opt) throws IllegalArgumentException
+ public static Option create(final char opt) throws IllegalArgumentException
{
<span class="fc" id="L340"> return create(String.valueOf(opt));</span>
}
@@ -367,7 +367,7 @@ public final class OptionBuilder
* @throws IllegalArgumentException if <code>opt</code> is not
* a valid character. See Option.
*/
- public static Option create(String opt) throws IllegalArgumentException
+ public static Option create(final String opt) throws IllegalArgumentException
{
<span class="fc" id="L372"> Option option = null;</span>
try
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionGroup.java.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionGroup.java.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionGroup.java.html Thu Jun 8 17:47:18 2017
@@ -26,7 +26,7 @@ import java.util.Map;
/**
* A group of mutually exclusive options.
*
- * @version $Id: OptionGroup.java 1749596 2016-06-21 20:27:06Z britter $
+ * @version $Id$
*/
<span class="fc" id="L31">public class OptionGroup implements Serializable</span>
{
@@ -48,7 +48,7 @@ import java.util.Map;
* @param option the option to add to this group
* @return this option group with the option added
*/
- public OptionGroup addOption(Option option)
+ public OptionGroup addOption(final Option option)
{
// key - option name
// value - the option
@@ -83,7 +83,7 @@ import java.util.Map;
* @throws AlreadySelectedException if an option from this group has
* already been selected.
*/
- public void setSelected(Option option) throws AlreadySelectedException
+ public void setSelected(final Option option) throws AlreadySelectedException
{
<span class="fc bfc" id="L88" title="All 2 branches covered."> if (option == null)</span>
{
@@ -116,7 +116,7 @@ import java.util.Map;
/**
* @param required specifies if this group is required
*/
- public void setRequired(boolean required)
+ public void setRequired(final boolean required)
{
<span class="fc" id="L121"> this.required = required;</span>
<span class="fc" id="L122"> }</span>
@@ -139,15 +139,15 @@ import java.util.Map;
@Override
public String toString()
{
-<span class="fc" id="L142"> StringBuilder buff = new StringBuilder();</span>
+<span class="fc" id="L142"> final StringBuilder buff = new StringBuilder();</span>
-<span class="fc" id="L144"> Iterator<Option> iter = getOptions().iterator();</span>
+<span class="fc" id="L144"> final Iterator<Option> iter = getOptions().iterator();</span>
<span class="fc" id="L146"> buff.append("[");</span>
<span class="fc bfc" id="L148" title="All 2 branches covered."> while (iter.hasNext())</span>
{
-<span class="fc" id="L150"> Option option = iter.next();</span>
+<span class="fc" id="L150"> final Option option = iter.next();</span>
<span class="fc bfc" id="L152" title="All 2 branches covered."> if (option.getOpt() != null)</span>
{
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionValidator.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionValidator.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionValidator.html Thu Jun 8 17:47:18 2017
@@ -1 +1 @@
-<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>OptionValidator</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">Apache Commons CLI</a> > <a href="index.html" class="el_package">org.apache.commons.cli</a> > <span class="el_class">OptionValidator</span></div><h1>OptionValidator</h1><table class="coverage" cellspacing="0" id="coveragetable"><th
ead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">3 of 87</td><td class="ctr2">97%</td><td class="bar">0 of 16</td><td class="ctr2">100%</td><td class="ctr1">1</td><td class="ctr2">12</td><
td class="ctr1">1</td><td class="ctr2">14</td><td class="ctr1">1</td><td class="ctr2">4</td></tr></tfoot><tbody><tr><td id="a2"><a href="OptionValidator.java.html#L26" class="el_method">OptionValidator()</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="5" height="10" title="3" alt="3"/></td><td class="ctr2" id="c3">0%</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h0">1</td><td class="ctr2" id="i1">1</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a3"><a href="OptionValidator.java.html#L48" class="el_method">validateOption(String)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/greenbar.gif" width="120" height="10" title="68" alt="68"/></td><td class="ctr2" id="c0">100%</td><td class="bar" id="d0"><img src="../jacoco-resources/greenbar.gif" width="120" height="10" title="10" alt="10"/></td><td class="ctr2"
id="e0">100%</td><td class="ctr1" id="f1">0</td><td class="ctr2" id="g0">6</td><td class="ctr1" id="h1">0</td><td class="ctr2" id="i0">11</td><td class="ctr1" id="j1">0</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a1"><a href="OptionValidator.java.html#L86" class="el_method">isValidOpt(char)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/greenbar.gif" width="22" height="10" title="13" alt="13"/></td><td class="ctr2" id="c1">100%</td><td class="bar" id="d1"><img src="../jacoco-resources/greenbar.gif" width="72" height="10" title="6" alt="6"/></td><td class="ctr2" id="e1">100%</td><td class="ctr1" id="f2">0</td><td class="ctr2" id="g1">4</td><td class="ctr1" id="h2">0</td><td class="ctr2" id="i2">1</td><td class="ctr1" id="j2">0</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a0"><a href="OptionValidator.java.html#L97" class="el_method">isValidChar(char)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/greenbar.gif" width="5" height="10" title="3
" alt="3"/></td><td class="ctr2" id="c2">100%</td><td class="bar" id="d3"/><td class="ctr2" id="e3">n/a</td><td class="ctr1" id="f3">0</td><td class="ctr2" id="g3">1</td><td class="ctr1" id="h3">0</td><td class="ctr2" id="i3">1</td><td class="ctr1" id="j3">0</td><td class="ctr2" id="k3">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.eclemma.org/jacoco">JaCoCo</a> 0.7.7.201606060606</span></div></body></html>
\ No newline at end of file
+<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>OptionValidator</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">Apache Commons CLI</a> > <a href="index.html" class="el_package">org.apache.commons.cli</a> > <span class="el_class">OptionValidator</span></div><h1>OptionValidator</h1><table class="coverage" cellspacing="0" id="coveragetable"><th
ead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">3 of 89</td><td class="ctr2">97%</td><td class="bar">0 of 16</td><td class="ctr2">100%</td><td class="ctr1">1</td><td class="ctr2">12</td><
td class="ctr1">1</td><td class="ctr2">14</td><td class="ctr1">1</td><td class="ctr2">4</td></tr></tfoot><tbody><tr><td id="a2"><a href="OptionValidator.java.html#L26" class="el_method">OptionValidator()</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="5" height="10" title="3" alt="3"/></td><td class="ctr2" id="c3">0%</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h0">1</td><td class="ctr2" id="i1">1</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a3"><a href="OptionValidator.java.html#L48" class="el_method">validateOption(String)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/greenbar.gif" width="120" height="10" title="70" alt="70"/></td><td class="ctr2" id="c0">100%</td><td class="bar" id="d0"><img src="../jacoco-resources/greenbar.gif" width="120" height="10" title="10" alt="10"/></td><td class="ctr2"
id="e0">100%</td><td class="ctr1" id="f1">0</td><td class="ctr2" id="g0">6</td><td class="ctr1" id="h1">0</td><td class="ctr2" id="i0">11</td><td class="ctr1" id="j1">0</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a1"><a href="OptionValidator.java.html#L86" class="el_method">isValidOpt(char)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/greenbar.gif" width="22" height="10" title="13" alt="13"/></td><td class="ctr2" id="c1">100%</td><td class="bar" id="d1"><img src="../jacoco-resources/greenbar.gif" width="72" height="10" title="6" alt="6"/></td><td class="ctr2" id="e1">100%</td><td class="ctr1" id="f2">0</td><td class="ctr2" id="g1">4</td><td class="ctr1" id="h2">0</td><td class="ctr2" id="i2">1</td><td class="ctr1" id="j2">0</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a0"><a href="OptionValidator.java.html#L97" class="el_method">isValidChar(char)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/greenbar.gif" width="5" height="10" title="3
" alt="3"/></td><td class="ctr2" id="c2">100%</td><td class="bar" id="d3"/><td class="ctr2" id="e3">n/a</td><td class="ctr1" id="f3">0</td><td class="ctr2" id="g3">1</td><td class="ctr1" id="h3">0</td><td class="ctr2" id="i3">1</td><td class="ctr1" id="j3">0</td><td class="ctr2" id="k3">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.eclemma.org/jacoco">JaCoCo</a> 0.7.7.201606060606</span></div></body></html>
\ No newline at end of file
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionValidator.java.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionValidator.java.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/OptionValidator.java.html Thu Jun 8 17:47:18 2017
@@ -20,7 +20,7 @@ package org.apache.commons.cli;
/**
* Validates an Option string.
*
- * @version $Id: OptionValidator.java 1544819 2013-11-23 15:34:31Z tn $
+ * @version $Id$
* @since 1.1
*/
<span class="nc" id="L26">final class OptionValidator</span>
@@ -42,7 +42,7 @@ package org.apache.commons.cli;
* @param opt The option string to validate, may be null
* @throws IllegalArgumentException if the Option is not valid.
*/
- static void validateOption(String opt) throws IllegalArgumentException
+ static void validateOption(final String opt) throws IllegalArgumentException
{
// if opt is NULL do not check further
<span class="fc bfc" id="L48" title="All 2 branches covered."> if (opt == null)</span>
@@ -53,7 +53,7 @@ package org.apache.commons.cli;
// handle the single character opt
<span class="fc bfc" id="L54" title="All 2 branches covered."> if (opt.length() == 1)</span>
{
-<span class="fc" id="L56"> char ch = opt.charAt(0);</span>
+<span class="fc" id="L56"> final char ch = opt.charAt(0);</span>
<span class="fc bfc" id="L58" title="All 2 branches covered."> if (!isValidOpt(ch))</span>
{
@@ -64,7 +64,7 @@ package org.apache.commons.cli;
// handle the multi character opt
else
{
-<span class="fc bfc" id="L67" title="All 2 branches covered."> for (char ch : opt.toCharArray())</span>
+<span class="fc bfc" id="L67" title="All 2 branches covered."> for (final char ch : opt.toCharArray())</span>
{
<span class="fc bfc" id="L69" title="All 2 branches covered."> if (!isValidChar(ch))</span>
{
@@ -81,7 +81,7 @@ package org.apache.commons.cli;
* @param c the option to validate
* @return true if <code>c</code> is a letter, '?' or '@', otherwise false.
*/
- private static boolean isValidOpt(char c)
+ private static boolean isValidOpt(final char c)
{
<span class="fc bfc" id="L86" title="All 6 branches covered."> return isValidChar(c) || c == '?' || c == '@';</span>
}
@@ -92,7 +92,7 @@ package org.apache.commons.cli;
* @param c the character to validate
* @return true if <code>c</code> is a letter.
*/
- private static boolean isValidChar(char c)
+ private static boolean isValidChar(final char c)
{
<span class="fc" id="L97"> return Character.isJavaIdentifierPart(c);</span>
}
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Options.java.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Options.java.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Options.java.html Thu Jun 8 17:47:18 2017
@@ -38,7 +38,7 @@ import java.util.Map;
*
* @see org.apache.commons.cli.CommandLine
*
- * @version $Id: Options.java 1754332 2016-07-27 18:47:57Z britter $
+ * @version $Id$
*/
<span class="fc" id="L43">public class Options implements Serializable</span>
{
@@ -65,14 +65,14 @@ import java.util.Map;
* @param group the OptionGroup that is to be added
* @return the resulting Options instance
*/
- public Options addOptionGroup(OptionGroup group)
+ public Options addOptionGroup(final OptionGroup group)
{
<span class="fc bfc" id="L70" title="All 2 branches covered."> if (group.isRequired())</span>
{
<span class="fc" id="L72"> requiredOpts.add(group);</span>
}
-<span class="fc bfc" id="L75" title="All 2 branches covered."> for (Option option : group.getOptions())</span>
+<span class="fc bfc" id="L75" title="All 2 branches covered."> for (final Option option : group.getOptions())</span>
{
// an Option cannot be required if it is in an
// OptionGroup, either the group is required or
@@ -108,7 +108,7 @@ import java.util.Map;
* @return the resulting Options instance
* @since 1.3
*/
- public Options addOption(String opt, String description)
+ public Options addOption(final String opt, final String description)
{
<span class="nc" id="L113"> addOption(opt, null, false, description);</span>
<span class="nc" id="L114"> return this;</span>
@@ -126,7 +126,7 @@ import java.util.Map;
* @param description Self-documenting description
* @return the resulting Options instance
*/
- public Options addOption(String opt, boolean hasArg, String description)
+ public Options addOption(final String opt, final boolean hasArg, final String description)
{
<span class="fc" id="L131"> addOption(opt, null, hasArg, description);</span>
<span class="fc" id="L132"> return this;</span>
@@ -145,7 +145,7 @@ import java.util.Map;
* @param description Self-documenting description
* @return the resulting Options instance
*/
- public Options addOption(String opt, String longOpt, boolean hasArg, String description)
+ public Options addOption(final String opt, final String longOpt, final boolean hasArg, final String description)
{
<span class="fc" id="L150"> addOption(new Option(opt, longOpt, hasArg, description));</span>
<span class="fc" id="L151"> return this;</span>
@@ -173,9 +173,9 @@ import java.util.Map;
* @return the resulting Options instance
* @since 1.4
*/
- public Options addRequiredOption(String opt, String longOpt, boolean hasArg, String description)
+ public Options addRequiredOption(final String opt, final String longOpt, final boolean hasArg, final String description)
{
-<span class="nc" id="L178"> Option option = new Option(opt, longOpt, hasArg, description);</span>
+<span class="nc" id="L178"> final Option option = new Option(opt, longOpt, hasArg, description);</span>
<span class="nc" id="L179"> option.setRequired(true);</span>
<span class="nc" id="L180"> addOption(option);</span>
<span class="nc" id="L181"> return this;</span>
@@ -187,9 +187,9 @@ import java.util.Map;
* @param opt the option that is to be added
* @return the resulting Options instance
*/
- public Options addOption(Option opt)
+ public Options addOption(final Option opt)
{
-<span class="fc" id="L192"> String key = opt.getKey();</span>
+<span class="fc" id="L192"> final String key = opt.getKey();</span>
// add it to the long option list
<span class="fc bfc" id="L195" title="All 2 branches covered."> if (opt.hasLongOpt())</span>
@@ -275,7 +275,7 @@ import java.util.Map;
{
<span class="fc" id="L276"> opt = Util.stripLeadingHyphens(opt);</span>
-<span class="fc" id="L278"> List<String> matchingOpts = new ArrayList<String>();</span>
+<span class="fc" id="L278"> final List<String> matchingOpts = new ArrayList<String>();</span>
// for a perfect match return the single option only
<span class="fc bfc" id="L281" title="All 2 branches covered."> if (longOpts.keySet().contains(opt))</span>
@@ -283,7 +283,7 @@ import java.util.Map;
<span class="fc" id="L283"> return Collections.singletonList(opt);</span>
}
-<span class="fc bfc" id="L286" title="All 2 branches covered."> for (String longOpt : longOpts.keySet())</span>
+<span class="fc bfc" id="L286" title="All 2 branches covered."> for (final String longOpt : longOpts.keySet())</span>
{
<span class="fc bfc" id="L288" title="All 2 branches covered."> if (longOpt.startsWith(opt))</span>
{
@@ -341,7 +341,7 @@ import java.util.Map;
* @param opt the option whose OptionGroup is being queried.
* @return the OptionGroup if <code>opt</code> is part of an OptionGroup, otherwise return null
*/
- public OptionGroup getOptionGroup(Option opt)
+ public OptionGroup getOptionGroup(final Option opt)
{
<span class="fc" id="L346"> return optionGroups.get(opt.getKey());</span>
}
@@ -354,7 +354,7 @@ import java.util.Map;
@Override
public String toString()
{
-<span class="fc" id="L357"> StringBuilder buf = new StringBuilder();</span>
+<span class="fc" id="L357"> final StringBuilder buf = new StringBuilder();</span>
<span class="fc" id="L359"> buf.append("[ Options: [ short ");</span>
<span class="fc" id="L360"> buf.append(shortOpts.toString());</span>
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/ParseException.java.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/ParseException.java.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/ParseException.java.html Thu Jun 8 17:47:18 2017
@@ -20,7 +20,7 @@ package org.apache.commons.cli;
/**
* Base for Exceptions thrown during parsing of a command-line.
*
- * @version $Id: ParseException.java 1443102 2013-02-06 18:12:16Z tn $
+ * @version $Id$
*/
public class ParseException extends Exception
{
@@ -35,7 +35,7 @@ public class ParseException extends Exce
*
* @param message the detail message
*/
- public ParseException(String message)
+ public ParseException(final String message)
{
<span class="fc" id="L40"> super(message);</span>
<span class="fc" id="L41"> }</span>
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Parser.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Parser.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Parser.html Thu Jun 8 17:47:18 2017
@@ -1 +1 @@
-<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Parser</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">Apache Commons CLI</a> > <a href="index.html" class="el_package">org.apache.commons.cli</a> > <span class="el_class">Parser</span></div><h1>Parser</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable
" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">9 of 398</td><td class="ctr2">98%</td><td class="bar">5 of 76</td><td class="ctr2">93%</td><td class="ctr1">4</td><td class="ctr2">51</td><td class="ctr1">2</td><td c
lass="ctr2">106</td><td class="ctr1">0</td><td class="ctr2">13</td></tr></tfoot><tbody><tr><td id="a10"><a href="Parser.java.html#L256" class="el_method">processProperties(Properties)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="5" height="10" title="6" alt="6"/><img src="../jacoco-resources/greenbar.gif" width="70" height="10" title="83" alt="83"/></td><td class="ctr2" id="c12">93%</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="12" height="10" title="3" alt="3"/><img src="../jacoco-resources/greenbar.gif" width="98" height="10" title="23" alt="23"/></td><td class="ctr2" id="e5">88%</td><td class="ctr1" id="f0">2</td><td class="ctr2" id="g1">14</td><td class="ctr1" id="h0">1</td><td class="ctr2" id="i1">24</td><td class="ctr1" id="j0">0</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a6"><a href="Parser.java.html#L149" class="el_method">parse(Options, String[], Properties, boolean)</a></td><td class="bar" id="b1">
<img src="../jacoco-resources/redbar.gif" width="2" height="10" title="3" alt="3"/><img src="../jacoco-resources/greenbar.gif" width="117" height="10" title="138" alt="138"/></td><td class="ctr2" id="c11">98%</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="2" alt="2"/><img src="../jacoco-resources/greenbar.gif" width="111" height="10" title="26" alt="26"/></td><td class="ctr2" id="e4">93%</td><td class="ctr1" id="f1">2</td><td class="ctr2" id="g0">15</td><td class="ctr1" id="h1">1</td><td class="ctr2" id="i0">39</td><td class="ctr1" id="j1">0</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a8"><a href="Parser.java.html#L338" class="el_method">processArgs(Option, ListIterator)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/greenbar.gif" width="36" height="10" title="43" alt="43"/></td><td class="ctr2" id="c0">100%</td><td class="bar" id="d2"><img src="../jacoco-resources/greenbar.gif" width="42" height="10" title="
10" alt="10"/></td><td class="ctr2" id="e0">100%</td><td class="ctr1" id="f2">0</td><td class="ctr2" id="g2">6</td><td class="ctr1" id="h2">0</td><td class="ctr2" id="i2">14</td><td class="ctr1" id="j2">0</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a9"><a href="Parser.java.html#L378" class="el_method">processOption(String, ListIterator)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/greenbar.gif" width="35" height="10" title="42" alt="42"/></td><td class="ctr2" id="c1">100%</td><td class="bar" id="d4"><img src="../jacoco-resources/greenbar.gif" width="17" height="10" title="4" alt="4"/></td><td class="ctr2" id="e1">100%</td><td class="ctr1" id="f3">0</td><td class="ctr2" id="g4">3</td><td class="ctr1" id="h3">0</td><td class="ctr2" id="i3">9</td><td class="ctr1" id="j3">0</td><td class="ctr2" id="k3">1</td></tr><tr><td id="a12"><a href="Parser.java.html#L411" class="el_method">updateRequiredOptions(Option)</a></td><td class="bar" id="b4"><img src="../jacoco-re
sources/greenbar.gif" width="26" height="10" title="31" alt="31"/></td><td class="ctr2" id="c2">100%</td><td class="bar" id="d3"><img src="../jacoco-resources/greenbar.gif" width="25" height="10" title="6" alt="6"/></td><td class="ctr2" id="e2">100%</td><td class="ctr1" id="f4">0</td><td class="ctr2" id="g3">4</td><td class="ctr1" id="h4">0</td><td class="ctr2" id="i4">8</td><td class="ctr1" id="j4">0</td><td class="ctr2" id="k4">1</td></tr><tr><td id="a11"><a href="Parser.java.html#L47" class="el_method">setOptions(Options)</a></td><td class="bar" id="b5"><img src="../jacoco-resources/greenbar.gif" width="9" height="10" title="11" alt="11"/></td><td class="ctr2" id="c3">100%</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f5">0</td><td class="ctr2" id="g6">1</td><td class="ctr1" id="h5">0</td><td class="ctr2" id="i5">3</td><td class="ctr1" id="j5">0</td><td class="ctr2" id="k5">1</td></tr><tr><td id="a0"><a href="Parser.java.html#L318" class="el_m
ethod">checkRequiredOptions()</a></td><td class="bar" id="b6"><img src="../jacoco-resources/greenbar.gif" width="9" height="10" title="11" alt="11"/></td><td class="ctr2" id="c4">100%</td><td class="bar" id="d5"><img src="../jacoco-resources/greenbar.gif" width="8" height="10" title="2" alt="2"/></td><td class="ctr2" id="e3">100%</td><td class="ctr1" id="f6">0</td><td class="ctr2" id="g5">2</td><td class="ctr1" id="h6">0</td><td class="ctr2" id="i6">3</td><td class="ctr1" id="j6">0</td><td class="ctr2" id="k6">1</td></tr><tr><td id="a3"><a href="Parser.java.html#L88" class="el_method">parse(Options, String[])</a></td><td class="bar" id="b7"><img src="../jacoco-resources/greenbar.gif" width="5" height="10" title="7" alt="7"/></td><td class="ctr2" id="c5">100%</td><td class="bar" id="d7"/><td class="ctr2" id="e7">n/a</td><td class="ctr1" id="f7">0</td><td class="ctr2" id="g7">1</td><td class="ctr1" id="h7">0</td><td class="ctr2" id="i7">1</td><td class="ctr1" id="j7">0</td><td class="
ctr2" id="k7">1</td></tr><tr><td id="a5"><a href="Parser.java.html#L105" class="el_method">parse(Options, String[], Properties)</a></td><td class="bar" id="b8"><img src="../jacoco-resources/greenbar.gif" width="5" height="10" title="7" alt="7"/></td><td class="ctr2" id="c6">100%</td><td class="bar" id="d8"/><td class="ctr2" id="e8">n/a</td><td class="ctr1" id="f8">0</td><td class="ctr2" id="g8">1</td><td class="ctr1" id="h8">0</td><td class="ctr2" id="i8">1</td><td class="ctr1" id="j8">0</td><td class="ctr2" id="k8">1</td></tr><tr><td id="a4"><a href="Parser.java.html#L123" class="el_method">parse(Options, String[], boolean)</a></td><td class="bar" id="b9"><img src="../jacoco-resources/greenbar.gif" width="5" height="10" title="7" alt="7"/></td><td class="ctr2" id="c7">100%</td><td class="bar" id="d9"/><td class="ctr2" id="e9">n/a</td><td class="ctr1" id="f9">0</td><td class="ctr2" id="g9">1</td><td class="ctr1" id="h9">0</td><td class="ctr2" id="i9">1</td><td class="ctr1" id="j9">0
</td><td class="ctr2" id="k9">1</td></tr><tr><td id="a7"><a href="Parser.java.html#L34" class="el_method">Parser()</a></td><td class="bar" id="b10"><img src="../jacoco-resources/greenbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c8">100%</td><td class="bar" id="d10"/><td class="ctr2" id="e10">n/a</td><td class="ctr1" id="f10">0</td><td class="ctr2" id="g10">1</td><td class="ctr1" id="h10">0</td><td class="ctr2" id="i10">1</td><td class="ctr1" id="j10">0</td><td class="ctr2" id="k10">1</td></tr><tr><td id="a1"><a href="Parser.java.html#L53" class="el_method">getOptions()</a></td><td class="bar" id="b11"><img src="../jacoco-resources/greenbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c9">100%</td><td class="bar" id="d11"/><td class="ctr2" id="e11">n/a</td><td class="ctr1" id="f11">0</td><td class="ctr2" id="g11">1</td><td class="ctr1" id="h11">0</td><td class="ctr2" id="i11">1</td><td class="ctr1" id="j11">0</td><td class="ct
r2" id="k11">1</td></tr><tr><td id="a2"><a href="Parser.java.html#L58" class="el_method">getRequiredOptions()</a></td><td class="bar" id="b12"><img src="../jacoco-resources/greenbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c10">100%</td><td class="bar" id="d12"/><td class="ctr2" id="e12">n/a</td><td class="ctr1" id="f12">0</td><td class="ctr2" id="g12">1</td><td class="ctr1" id="h12">0</td><td class="ctr2" id="i12">1</td><td class="ctr1" id="j12">0</td><td class="ctr2" id="k12">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.eclemma.org/jacoco">JaCoCo</a> 0.7.7.201606060606</span></div></body></html>
\ No newline at end of file
+<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="en"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Parser</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">Apache Commons CLI</a> > <a href="index.html" class="el_package">org.apache.commons.cli</a> > <span class="el_class">Parser</span></div><h1>Parser</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable
" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">9 of 398</td><td class="ctr2">98%</td><td class="bar">5 of 76</td><td class="ctr2">93%</td><td class="ctr1">4</td><td class="ctr2">51</td><td class="ctr1">2</td><td c
lass="ctr2">104</td><td class="ctr1">0</td><td class="ctr2">13</td></tr></tfoot><tbody><tr><td id="a10"><a href="Parser.java.html#L256" class="el_method">processProperties(Properties)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="5" height="10" title="6" alt="6"/><img src="../jacoco-resources/greenbar.gif" width="70" height="10" title="83" alt="83"/></td><td class="ctr2" id="c12">93%</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="12" height="10" title="3" alt="3"/><img src="../jacoco-resources/greenbar.gif" width="98" height="10" title="23" alt="23"/></td><td class="ctr2" id="e5">88%</td><td class="ctr1" id="f0">2</td><td class="ctr2" id="g1">14</td><td class="ctr1" id="h0">1</td><td class="ctr2" id="i1">22</td><td class="ctr1" id="j0">0</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a6"><a href="Parser.java.html#L149" class="el_method">parse(Options, String[], Properties, boolean)</a></td><td class="bar" id="b1">
<img src="../jacoco-resources/redbar.gif" width="2" height="10" title="3" alt="3"/><img src="../jacoco-resources/greenbar.gif" width="117" height="10" title="138" alt="138"/></td><td class="ctr2" id="c11">98%</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="2" alt="2"/><img src="../jacoco-resources/greenbar.gif" width="111" height="10" title="26" alt="26"/></td><td class="ctr2" id="e4">93%</td><td class="ctr1" id="f1">2</td><td class="ctr2" id="g0">15</td><td class="ctr1" id="h1">1</td><td class="ctr2" id="i0">39</td><td class="ctr1" id="j1">0</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a8"><a href="Parser.java.html#L338" class="el_method">processArgs(Option, ListIterator)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/greenbar.gif" width="36" height="10" title="43" alt="43"/></td><td class="ctr2" id="c0">100%</td><td class="bar" id="d2"><img src="../jacoco-resources/greenbar.gif" width="42" height="10" title="
10" alt="10"/></td><td class="ctr2" id="e0">100%</td><td class="ctr1" id="f2">0</td><td class="ctr2" id="g2">6</td><td class="ctr1" id="h2">0</td><td class="ctr2" id="i2">14</td><td class="ctr1" id="j2">0</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a9"><a href="Parser.java.html#L378" class="el_method">processOption(String, ListIterator)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/greenbar.gif" width="35" height="10" title="42" alt="42"/></td><td class="ctr2" id="c1">100%</td><td class="bar" id="d4"><img src="../jacoco-resources/greenbar.gif" width="17" height="10" title="4" alt="4"/></td><td class="ctr2" id="e1">100%</td><td class="ctr1" id="f3">0</td><td class="ctr2" id="g4">3</td><td class="ctr1" id="h3">0</td><td class="ctr2" id="i3">9</td><td class="ctr1" id="j3">0</td><td class="ctr2" id="k3">1</td></tr><tr><td id="a12"><a href="Parser.java.html#L411" class="el_method">updateRequiredOptions(Option)</a></td><td class="bar" id="b4"><img src="../jacoco-re
sources/greenbar.gif" width="26" height="10" title="31" alt="31"/></td><td class="ctr2" id="c2">100%</td><td class="bar" id="d3"><img src="../jacoco-resources/greenbar.gif" width="25" height="10" title="6" alt="6"/></td><td class="ctr2" id="e2">100%</td><td class="ctr1" id="f4">0</td><td class="ctr2" id="g3">4</td><td class="ctr1" id="h4">0</td><td class="ctr2" id="i4">8</td><td class="ctr1" id="j4">0</td><td class="ctr2" id="k4">1</td></tr><tr><td id="a11"><a href="Parser.java.html#L47" class="el_method">setOptions(Options)</a></td><td class="bar" id="b5"><img src="../jacoco-resources/greenbar.gif" width="9" height="10" title="11" alt="11"/></td><td class="ctr2" id="c3">100%</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f5">0</td><td class="ctr2" id="g6">1</td><td class="ctr1" id="h5">0</td><td class="ctr2" id="i5">3</td><td class="ctr1" id="j5">0</td><td class="ctr2" id="k5">1</td></tr><tr><td id="a0"><a href="Parser.java.html#L318" class="el_m
ethod">checkRequiredOptions()</a></td><td class="bar" id="b6"><img src="../jacoco-resources/greenbar.gif" width="9" height="10" title="11" alt="11"/></td><td class="ctr2" id="c4">100%</td><td class="bar" id="d5"><img src="../jacoco-resources/greenbar.gif" width="8" height="10" title="2" alt="2"/></td><td class="ctr2" id="e3">100%</td><td class="ctr1" id="f6">0</td><td class="ctr2" id="g5">2</td><td class="ctr1" id="h6">0</td><td class="ctr2" id="i6">3</td><td class="ctr1" id="j6">0</td><td class="ctr2" id="k6">1</td></tr><tr><td id="a3"><a href="Parser.java.html#L88" class="el_method">parse(Options, String[])</a></td><td class="bar" id="b7"><img src="../jacoco-resources/greenbar.gif" width="5" height="10" title="7" alt="7"/></td><td class="ctr2" id="c5">100%</td><td class="bar" id="d7"/><td class="ctr2" id="e7">n/a</td><td class="ctr1" id="f7">0</td><td class="ctr2" id="g7">1</td><td class="ctr1" id="h7">0</td><td class="ctr2" id="i7">1</td><td class="ctr1" id="j7">0</td><td class="
ctr2" id="k7">1</td></tr><tr><td id="a5"><a href="Parser.java.html#L105" class="el_method">parse(Options, String[], Properties)</a></td><td class="bar" id="b8"><img src="../jacoco-resources/greenbar.gif" width="5" height="10" title="7" alt="7"/></td><td class="ctr2" id="c6">100%</td><td class="bar" id="d8"/><td class="ctr2" id="e8">n/a</td><td class="ctr1" id="f8">0</td><td class="ctr2" id="g8">1</td><td class="ctr1" id="h8">0</td><td class="ctr2" id="i8">1</td><td class="ctr1" id="j8">0</td><td class="ctr2" id="k8">1</td></tr><tr><td id="a4"><a href="Parser.java.html#L123" class="el_method">parse(Options, String[], boolean)</a></td><td class="bar" id="b9"><img src="../jacoco-resources/greenbar.gif" width="5" height="10" title="7" alt="7"/></td><td class="ctr2" id="c7">100%</td><td class="bar" id="d9"/><td class="ctr2" id="e9">n/a</td><td class="ctr1" id="f9">0</td><td class="ctr2" id="g9">1</td><td class="ctr1" id="h9">0</td><td class="ctr2" id="i9">1</td><td class="ctr1" id="j9">0
</td><td class="ctr2" id="k9">1</td></tr><tr><td id="a7"><a href="Parser.java.html#L34" class="el_method">Parser()</a></td><td class="bar" id="b10"><img src="../jacoco-resources/greenbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c8">100%</td><td class="bar" id="d10"/><td class="ctr2" id="e10">n/a</td><td class="ctr1" id="f10">0</td><td class="ctr2" id="g10">1</td><td class="ctr1" id="h10">0</td><td class="ctr2" id="i10">1</td><td class="ctr1" id="j10">0</td><td class="ctr2" id="k10">1</td></tr><tr><td id="a1"><a href="Parser.java.html#L53" class="el_method">getOptions()</a></td><td class="bar" id="b11"><img src="../jacoco-resources/greenbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c9">100%</td><td class="bar" id="d11"/><td class="ctr2" id="e11">n/a</td><td class="ctr1" id="f11">0</td><td class="ctr2" id="g11">1</td><td class="ctr1" id="h11">0</td><td class="ctr2" id="i11">1</td><td class="ctr1" id="j11">0</td><td class="ct
r2" id="k11">1</td></tr><tr><td id="a2"><a href="Parser.java.html#L58" class="el_method">getRequiredOptions()</a></td><td class="bar" id="b12"><img src="../jacoco-resources/greenbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c10">100%</td><td class="bar" id="d12"/><td class="ctr2" id="e12">n/a</td><td class="ctr1" id="f12">0</td><td class="ctr2" id="g12">1</td><td class="ctr1" id="h12">0</td><td class="ctr2" id="i12">1</td><td class="ctr1" id="j12">0</td><td class="ctr2" id="k12">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.eclemma.org/jacoco">JaCoCo</a> 0.7.7.201606060606</span></div></body></html>
\ No newline at end of file
Modified: websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Parser.java.html
==============================================================================
--- websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Parser.java.html (original)
+++ websites/production/commons/content/proper/commons-cli/jacoco/org.apache.commons.cli/Parser.java.html Thu Jun 8 17:47:18 2017
@@ -27,7 +27,7 @@ import java.util.Properties;
/**
* <code>Parser</code> creates {@link CommandLine}s.
*
- * @version $Id: Parser.java 1744812 2016-05-20 23:36:20Z ggregory $
+ * @version $Id$
* @deprecated since 1.3, the two-pass parsing with the flatten method is not enough flexible to handle complex cases
*/
@Deprecated
@@ -42,7 +42,7 @@ import java.util.Properties;
/** list of required options strings */
private List requiredOptions;
- protected void setOptions(Options options)
+ protected void setOptions(final Options options)
{
<span class="fc" id="L47"> this.options = options;</span>
<span class="fc" id="L48"> this.requiredOptions = new ArrayList(options.getRequiredOptions());</span>
@@ -83,7 +83,7 @@ import java.util.Properties;
* @throws ParseException if there are any problems encountered
* while parsing the command line tokens.
*/
- public CommandLine parse(Options options, String[] arguments) throws ParseException
+ public CommandLine parse(final Options options, final String[] arguments) throws ParseException
{
<span class="fc" id="L88"> return parse(options, arguments, null, false);</span>
}
@@ -100,7 +100,7 @@ import java.util.Properties;
*
* @since 1.1
*/
- public CommandLine parse(Options options, String[] arguments, Properties properties) throws ParseException
+ public CommandLine parse(final Options options, final String[] arguments, final Properties properties) throws ParseException
{
<span class="fc" id="L105"> return parse(options, arguments, properties, false);</span>
}
@@ -118,7 +118,7 @@ import java.util.Properties;
* @return the <code>CommandLine</code>
* @throws ParseException if an error occurs when parsing the arguments.
*/
- public CommandLine parse(Options options, String[] arguments, boolean stopAtNonOption) throws ParseException
+ public CommandLine parse(final Options options, final String[] arguments, final boolean stopAtNonOption) throws ParseException
{
<span class="fc" id="L123"> return parse(options, arguments, null, stopAtNonOption);</span>
}
@@ -142,17 +142,17 @@ import java.util.Properties;
*
* @since 1.1
*/
- public CommandLine parse(Options options, String[] arguments, Properties properties, boolean stopAtNonOption)
+ public CommandLine parse(final Options options, String[] arguments, final Properties properties, final boolean stopAtNonOption)
throws ParseException
{
// clear out the data in options in case it's been used before (CLI-71)
-<span class="fc bfc" id="L149" title="All 2 branches covered."> for (Option opt : options.helpOptions())</span>
+<span class="fc bfc" id="L149" title="All 2 branches covered."> for (final Option opt : options.helpOptions())</span>
{
<span class="fc" id="L151"> opt.clearValues();</span>
<span class="fc" id="L152"> }</span>
// clear the data from the groups
-<span class="fc bfc" id="L155" title="All 2 branches covered."> for (OptionGroup group : options.getOptionGroups())</span>
+<span class="fc bfc" id="L155" title="All 2 branches covered."> for (final OptionGroup group : options.getOptionGroups())</span>
{
<span class="fc" id="L157"> group.setSelected(null);</span>
<span class="fc" id="L158"> } </span>
@@ -169,14 +169,14 @@ import java.util.Properties;
<span class="fc" id="L169"> arguments = new String[0];</span>
}
-<span class="fc" id="L172"> List<String> tokenList = Arrays.asList(flatten(getOptions(), arguments, stopAtNonOption));</span>
+<span class="fc" id="L172"> final List<String> tokenList = Arrays.asList(flatten(getOptions(), arguments, stopAtNonOption));</span>
-<span class="fc" id="L174"> ListIterator<String> iterator = tokenList.listIterator();</span>
+<span class="fc" id="L174"> final ListIterator<String> iterator = tokenList.listIterator();</span>
// process each flattened token
<span class="fc bfc" id="L177" title="All 2 branches covered."> while (iterator.hasNext())</span>
{
-<span class="fc" id="L179"> String t = iterator.next();</span>
+<span class="fc" id="L179"> final String t = iterator.next();</span>
// the value is the double-dash
<span class="fc bfc" id="L182" title="All 2 branches covered."> if ("--".equals(t))</span>
@@ -227,7 +227,7 @@ import java.util.Properties;
{
<span class="fc bfc" id="L228" title="All 2 branches covered."> while (iterator.hasNext())</span>
{
-<span class="fc" id="L230"> String str = iterator.next();</span>
+<span class="fc" id="L230"> final String str = iterator.next();</span>
// ensure only one double-dash is added
<span class="pc bpc" id="L233" title="1 of 2 branches missed."> if (!"--".equals(str))</span>
@@ -251,31 +251,31 @@ import java.util.Properties;
* @throws ParseException if there are any problems encountered
* while processing the properties.
*/
- protected void processProperties(Properties properties) throws ParseException
+ protected void processProperties(final Properties properties) throws ParseException
{
<span class="fc bfc" id="L256" title="All 2 branches covered."> if (properties == null)</span>
{
<span class="fc" id="L258"> return;</span>
}
-<span class="fc bfc" id="L261" title="All 2 branches covered."> for (Enumeration<?> e = properties.propertyNames(); e.hasMoreElements();)</span>
+<span class="fc bfc" id="L261" title="All 2 branches covered."> for (final Enumeration<?> e = properties.propertyNames(); e.hasMoreElements();)</span>
{
-<span class="fc" id="L263"> String option = e.nextElement().toString();</span>
+<span class="fc" id="L263"> final String option = e.nextElement().toString();</span>
-<span class="fc" id="L265"> Option opt = options.getOption(option);</span>
+<span class="fc" id="L265"> final Option opt = options.getOption(option);</span>
<span class="fc bfc" id="L266" title="All 2 branches covered."> if (opt == null)</span>
{
<span class="fc" id="L268"> throw new UnrecognizedOptionException("Default option wasn't defined", option);</span>
}
// if the option is part of a group, check if another option of the group has been selected
-<span class="fc" id="L272"> OptionGroup group = options.getOptionGroup(opt);</span>
-<span class="fc bfc" id="L273" title="All 4 branches covered."> boolean selected = group != null && group.getSelected() != null;</span>
+<span class="fc" id="L272"> final OptionGroup group = options.getOptionGroup(opt);</span>
+<span class="fc bfc" id="L273" title="All 4 branches covered."> final boolean selected = group != null && group.getSelected() != null;</span>
<span class="fc bfc" id="L275" title="All 4 branches covered."> if (!cmd.hasOption(option) && !selected)</span>
{
// get the value from the properties instance
-<span class="fc" id="L278"> String value = properties.getProperty(option);</span>
+<span class="fc" id="L278"> final String value = properties.getProperty(option);</span>
<span class="fc bfc" id="L280" title="All 2 branches covered."> if (opt.hasArg())</span>
{
@@ -285,15 +285,15 @@ import java.util.Properties;
{
<span class="fc" id="L286"> opt.addValueForProcessing(value);</span>
}
-<span class="nc" id="L288"> catch (RuntimeException exp) //NOPMD</span>
+<span class="nc" id="L288"> catch (final RuntimeException exp) //NOPMD</span>
{
// if we cannot add the value don't worry about it
<span class="pc" id="L291"> }</span>
}
}
-<span class="fc bfc" id="L294" title="All 2 branches covered."> else if (!("yes".equalsIgnoreCase(value)</span>
-<span class="fc bfc" id="L295" title="All 2 branches covered."> || "true".equalsIgnoreCase(value)</span>
-<span class="fc bfc" id="L296" title="All 2 branches covered."> || "1".equalsIgnoreCase(value)))</span>
+<span class="fc bfc" id="L294" title="All 6 branches covered."> else if (!("yes".equalsIgnoreCase(value)</span>
+ || "true".equalsIgnoreCase(value)
+ || "1".equalsIgnoreCase(value)))
{
// if the value is not yes, true or 1 then don't add the
// option to the CommandLine
@@ -332,12 +332,12 @@ import java.util.Properties;
* @throws ParseException if an argument value is required
* and it is has not been found.
*/
- public void processArgs(Option opt, ListIterator<String> iter) throws ParseException
+ public void processArgs(final Option opt, final ListIterator<String> iter) throws ParseException
{
// loop until an option is found
<span class="fc bfc" id="L338" title="All 2 branches covered."> while (iter.hasNext())</span>
{
-<span class="fc" id="L340"> String str = iter.next();</span>
+<span class="fc" id="L340"> final String str = iter.next();</span>
// found an Option, not an argument
<span class="fc bfc" id="L343" title="All 4 branches covered."> if (getOptions().hasOption(str) && str.startsWith("-"))</span>
@@ -351,7 +351,7 @@ import java.util.Properties;
{
<span class="fc" id="L352"> opt.addValueForProcessing(Util.stripLeadingAndTrailingQuotes(str));</span>
}
-<span class="fc" id="L354"> catch (RuntimeException exp)</span>
+<span class="fc" id="L354"> catch (final RuntimeException exp)</span>
{
<span class="fc" id="L356"> iter.previous();</span>
<span class="fc" id="L357"> break;</span>
@@ -373,9 +373,9 @@ import java.util.Properties;
*
* @throws ParseException if <code>arg</code> does not represent an Option
*/
- protected void processOption(String arg, ListIterator<String> iter) throws ParseException
+ protected void processOption(final String arg, final ListIterator<String> iter) throws ParseException
{
-<span class="fc" id="L378"> boolean hasOption = getOptions().hasOption(arg);</span>
+<span class="fc" id="L378"> final boolean hasOption = getOptions().hasOption(arg);</span>
// if there is no option throw an UnrecognizedOptionException
<span class="fc bfc" id="L381" title="All 2 branches covered."> if (!hasOption)</span>
@@ -384,7 +384,7 @@ import java.util.Properties;
}
// get the option represented by arg
-<span class="fc" id="L387"> Option opt = (Option) getOptions().getOption(arg).clone();</span>
+<span class="fc" id="L387"> final Option opt = (Option) getOptions().getOption(arg).clone();</span>
// update the required options and groups
<span class="fc" id="L390"> updateRequiredOptions(opt);</span>
@@ -404,7 +404,7 @@ import java.util.Properties;
*
* @param opt
*/
- private void updateRequiredOptions(Option opt) throws ParseException
+ private void updateRequiredOptions(final Option opt) throws ParseException
{
// if the option is a required option remove the option from
// the requiredOptions list
@@ -417,7 +417,7 @@ import java.util.Properties;
// option of the group
<span class="fc bfc" id="L418" title="All 2 branches covered."> if (getOptions().getOptionGroup(opt) != null)</span>
{
-<span class="fc" id="L420"> OptionGroup group = getOptions().getOptionGroup(opt);</span>
+<span class="fc" id="L420"> final OptionGroup group = getOptions().getOptionGroup(opt);</span>
<span class="fc bfc" id="L422" title="All 2 branches covered."> if (group.isRequired())</span>
{