Author: scolebourne Date: Wed May 25 15:29:31 2011 New Revision: 1127554 URL: http://svn.apache.org/viewvc?rev=1127554&view=rev Log: Fix toString(format)
Modified: commons/proper/lang/trunk/src/main/java/org/apache/commons/lang3/tuple/Pair.java Modified: commons/proper/lang/trunk/src/main/java/org/apache/commons/lang3/tuple/Pair.java URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/main/java/org/apache/commons/lang3/tuple/Pair.java?rev=1127554&r1=1127553&r2=1127554&view=diff ============================================================================== --- commons/proper/lang/trunk/src/main/java/org/apache/commons/lang3/tuple/Pair.java (original) +++ commons/proper/lang/trunk/src/main/java/org/apache/commons/lang3/tuple/Pair.java Wed May 25 15:29:31 2011 @@ -162,7 +162,7 @@ public abstract class Pair<L, R> impleme /** * <p>Formats the receiver using the given format.</p> * - * <p>This uses {@link Formattable} to perform the formatting. Two variable may + * <p>This uses {@link Formattable} to perform the formatting. Two variables may * be used to embed the left and right elements. Use {@code %1$} for the left * element (key) and {@code %2$} for the right element (value). * The default format used by {@code toString()} is {@code (%1$s,%2$s)}.</p> @@ -170,7 +170,7 @@ public abstract class Pair<L, R> impleme * @param format the format string, optionally containing {@code %1$} and {@code %2$}, not null * @return the formatted string, not null */ - public Object toString(String format) { + public String toString(String format) { return String.format(format, getLeft(), getRight()); }