Adding missing private method javadoc and removing 'unused' import in favour of fully qualified javadoc link

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@1142401 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Henri Yandell 2011-07-03 08:30:12 +00:00
parent a783018094
commit 0b1db833f2
2 changed files with 9 additions and 4 deletions

View File

@ -18,7 +18,6 @@ package org.apache.commons.lang3;
import java.io.Serializable;
import java.util.Comparator;
import java.util.Formattable;
/**
* <p>An immutable range of objects from a minimum to maximum point inclusive.</p>
@ -442,7 +441,7 @@ public final class Range<T> implements Serializable {
/**
* <p>Formats the receiver using the given format.</p>
*
* <p>This uses {@link Formattable} to perform the formatting. Three variables may
* <p>This uses {@link java.util.Formattable} to perform the formatting. Three variables may
* be used to embed the minimum, maximum and comparator.
* Use {@code %1$s} for the minimum element, {@code %2$s} for the maximum element
* and {@code %3$s} for the comparator.
@ -459,6 +458,13 @@ public final class Range<T> implements Serializable {
@SuppressWarnings({"rawtypes", "unchecked"})
private enum ComparableComparator implements Comparator {
INSTANCE;
/**
* Comparable based compare implementation.
*
* @param obj1 left hand side of comparison
* @param obj2 right hand side of comparison
* @return negative, 0, positive comparison value
*/
public int compare(Object obj1, Object obj2) {
return ((Comparable) obj1).compareTo(obj2);
}

View File

@ -17,7 +17,6 @@
package org.apache.commons.lang3.tuple;
import java.io.Serializable;
import java.util.Formattable;
import java.util.Map;
import org.apache.commons.lang3.ObjectUtils;
@ -162,7 +161,7 @@ public abstract class Pair<L, R> implements Map.Entry<L, R>, Comparable<Pair<L,
/**
* <p>Formats the receiver using the given format.</p>
*
* <p>This uses {@link Formattable} to perform the formatting. Two variables may
* <p>This uses {@link java.util.Formattable} to perform the formatting. Two variables may
* be used to embed the left and right elements. Use {@code %1$s} for the left
* element (key) and {@code %2$s} for the right element (value).
* The default format used by {@code toString()} is {@code (%1$s,%2$s)}.</p>