/** * Return <code>true</code> if the first version number is greater than * or equal to the second; otherwise return <code>false</code>. * * @param first First version number (dotted decimal) * @param second Second version number (dotted decimal) */ private boolean isCompatible(final DeweyDecimal first, final DeweyDecimal second) { return first.isGreaterThanOrEqual(second); }
/** * Return <code>true</code> if this <code>DeweyDecimal</code> is * less than the other <code>DeweyDecimal</code>. * * @param other the other DeweyDecimal * @return true if less than other DeweyDecimal, false otherwise */ public boolean isLessThan(final DeweyDecimal other) { return !isGreaterThanOrEqual(other); }
/** * Return <code>true</code> if the first version number is greater than * or equal to the second; otherwise return <code>false</code>. * * @param first First version number (dotted decimal) * @param second Second version number (dotted decimal) */ private boolean isCompatible(final DeweyDecimal first, final DeweyDecimal second) { return first.isGreaterThanOrEqual(second); }
/** * Evaluate the condition. * @return true if the condition is true. * @throws BuildException if an error occurs. */ public boolean eval() throws BuildException { validate(); DeweyDecimal actual = JavaEnvUtils.getParsedJavaVersion(); if (null != atLeast) { return actual.isGreaterThanOrEqual(new DeweyDecimal(atLeast)); } if (null != exactly) { return actual.isEqual(new DeweyDecimal(exactly)); } //default return false; }
/** * Evaluate the condition. * @return true if the condition is true. * @throws BuildException if an error occurs. */ @Override public boolean eval() throws BuildException { validate(); DeweyDecimal actual = getVersion(); if (null != atLeast) { return actual.isGreaterThanOrEqual(new DeweyDecimal(atLeast)); } if (null != exactly) { return actual.isEqual(new DeweyDecimal(exactly)); } //default return false; }