diff --git a/src/java/org/apache/commons/lang/ClassUtils.java b/src/java/org/apache/commons/lang/ClassUtils.java index eb71a0ade..02fe84738 100644 --- a/src/java/org/apache/commons/lang/ClassUtils.java +++ b/src/java/org/apache/commons/lang/ClassUtils.java @@ -32,7 +32,7 @@ * @author Gary Gregory * @author Norm Deane * @since 2.0 - * @version $Id: ClassUtils.java,v 1.32 2004/10/15 20:57:18 scolebourne Exp $ + * @version $Id: ClassUtils.java,v 1.33 2004/10/21 01:18:33 ggregory Exp $ */ public class ClassUtils { @@ -505,6 +505,9 @@ public static boolean isInnerClass(Class cls) { private static class ClassNameComparator implements Comparator { /** * Compares two Classs by name. + * @param o1 The receiver of the comparison call to {@link String#compareTo(String)}. + * @param o2 The argument of the comparison call to {@link String#compareTo(String)}. + * @return The return value from {@link String#compareTo(String)} * * @throws ClassCastException * If o1 or o2 are not Class @@ -536,6 +539,9 @@ private static class PackageNameComparator implements Comparator { /** * Compares two Packages by name. * + * @param o1 The receiver of the comparison call to {@link String#compareTo(String)}. + * @param o2 The argument of the comparison call to {@link String#compareTo(String)}. + * @return The return value from {@link String#compareTo(String)} * @throws ClassCastException * If o1 or o2 are not Package * instances. diff --git a/src/java/org/apache/commons/lang/NotImplementedException.java b/src/java/org/apache/commons/lang/NotImplementedException.java index bef4930e8..f148d038d 100644 --- a/src/java/org/apache/commons/lang/NotImplementedException.java +++ b/src/java/org/apache/commons/lang/NotImplementedException.java @@ -46,7 +46,7 @@ * @author Matthew Hawthorne * @author Stephen Colebourne * @since 2.0 - * @version $Id: NotImplementedException.java,v 1.9 2004/10/15 20:55:01 scolebourne Exp $ + * @version $Id: NotImplementedException.java,v 1.10 2004/10/21 01:18:33 ggregory Exp $ */ public class NotImplementedException extends UnsupportedOperationException implements Nestable { @@ -122,6 +122,7 @@ public NotImplementedException(Class clazz) { //----------------------------------------------------------------------- /** * Gets the root cause of this exception. + * @return the root cause of this exception. * * @since 2.1 */ diff --git a/src/java/org/apache/commons/lang/exception/ExceptionUtils.java b/src/java/org/apache/commons/lang/exception/ExceptionUtils.java index 5cb56adcd..b288812d1 100644 --- a/src/java/org/apache/commons/lang/exception/ExceptionUtils.java +++ b/src/java/org/apache/commons/lang/exception/ExceptionUtils.java @@ -42,7 +42,7 @@ * @author Gary Gregory * @author Pete Gieser * @since 1.0 - * @version $Id: ExceptionUtils.java,v 1.42 2004/10/09 10:04:04 scolebourne Exp $ + * @version $Id: ExceptionUtils.java,v 1.43 2004/10/21 01:18:33 ggregory Exp $ */ public class ExceptionUtils { @@ -695,10 +695,15 @@ public static String[] getStackFrames(Throwable throwable) { } /** + *

Returns an array where each element is a line from the argument.

+ *

The end of line is determined by the value of {@link SystemUtils#LINE_SEPARATOR}.

+ * *

Functionality shared between the * getStackFrames(Throwable) methods of this and the * {@link org.apache.commons.lang.exception.NestableDelegate} * classes.

+ * @param stackTrace A stack trace String. + * @return an array where each element is a line from the argument. */ static String[] getStackFrames(String stackTrace) { String linebreak = SystemUtils.LINE_SEPARATOR; diff --git a/src/java/org/apache/commons/lang/math/JVMRandom.java b/src/java/org/apache/commons/lang/math/JVMRandom.java index 6926a235d..6c6cf6707 100644 --- a/src/java/org/apache/commons/lang/math/JVMRandom.java +++ b/src/java/org/apache/commons/lang/math/JVMRandom.java @@ -24,7 +24,7 @@ * * @author Henri Yandell * @since 2.0 - * @version $Id: JVMRandom.java,v 1.10 2004/02/18 22:56:13 ggregory Exp $ + * @version $Id: JVMRandom.java,v 1.11 2004/10/21 01:18:33 ggregory Exp $ */ public final class JVMRandom extends Random { @@ -42,6 +42,9 @@ public JVMRandom() { /** * Unsupported in 2.0. + * + * @param seed ignored + * @throws UnsupportedOperationException */ public synchronized void setSeed(long seed) { if (this.constructed) { @@ -51,6 +54,9 @@ public synchronized void setSeed(long seed) { /** * Unsupported in 2.0. + * + * @return Nothing, this method always throws an UnsupportedOperationException. + * @throws UnsupportedOperationException */ public synchronized double nextGaussian() { throw new UnsupportedOperationException(); @@ -58,6 +64,9 @@ public synchronized double nextGaussian() { /** * Unsupported in 2.0. + * + * @param byteArray ignored + * @throws UnsupportedOperationException */ public void nextBytes(byte[] byteArray) { throw new UnsupportedOperationException(); diff --git a/src/java/org/apache/commons/lang/math/LongRange.java b/src/java/org/apache/commons/lang/math/LongRange.java index d10fcfa2f..6dd0b90e9 100644 --- a/src/java/org/apache/commons/lang/math/LongRange.java +++ b/src/java/org/apache/commons/lang/math/LongRange.java @@ -22,7 +22,7 @@ * * @author Stephen Colebourne * @since 2.0 - * @version $Id: LongRange.java,v 1.7 2004/02/18 22:56:13 ggregory Exp $ + * @version $Id: LongRange.java,v 1.8 2004/10/21 01:18:33 ggregory Exp $ */ public final class LongRange extends Range implements Serializable { @@ -240,6 +240,8 @@ public int getMaximumInteger() { *

Gets the maximum number in this range as a double.

* *

This conversion can lose information for large values.

+ * + * @return The maximum number in this range as a double. */ public double getMaximumDouble() { return max; @@ -249,6 +251,8 @@ public double getMaximumDouble() { *

Gets the maximum number in this range as a float.

* *

This conversion can lose information for large values.

+ * + * @return The maximum number in this range as a float. */ public float getMaximumFloat() { return max; diff --git a/src/java/org/apache/commons/lang/text/MappedMessageFormat.java b/src/java/org/apache/commons/lang/text/MappedMessageFormat.java index 5ca5a32d0..8a62bcbdd 100644 --- a/src/java/org/apache/commons/lang/text/MappedMessageFormat.java +++ b/src/java/org/apache/commons/lang/text/MappedMessageFormat.java @@ -48,12 +48,18 @@ public class MappedMessageFormat { private ArrayList markers = new ArrayList(2); private ArrayList sources = new ArrayList(2); + /** + * Constructs a new instance. + */ public MappedMessageFormat() { } /** * Defines a source of data that can later be substituted into * strings passed to the "format" methods. + * + * @param marker the marker prefix for the syntax "marker{key}", commonly the String "$". + * @param source A Map where the keys are Strings and the values are non-null Objects. */ public void addSource(String marker, Map source) { nEntries++; @@ -65,12 +71,15 @@ public void addSource(String marker, Map source) { * Expands any variable declarations using any of the known * variable marker strings. * + * @param param The String to expand. + * @return The expanded String + * * @throws IllegalArgumentException if the input param references * a variable which is not known to the specified source. */ public String format(String param) { for(int i=0; i - * Commonly, the variable marker is "$", in which case variables - * are indicated by ${key} in the string. + * Commonly, the variable marker is "$", in which case variables + * are indicated by ${key} in the string. *

* Returns the string after performing all substitutions. *

* If no substitutions were made, the input string object is * returned (not a copy). - * + * + * @param str The String to expand. + * @param marker The variable marker, commonly, "$", in which case variables + * are indicated by ${key} in the string. + * @param source A Map where the keys are Strings and the values are non-null Objects. + * @return The expanded String or, if no substitutions were made, the input String object (not a copy). * @throws IllegalArgumentException if the input param references * a variable which is not known to the specified source. */ diff --git a/src/java/org/apache/commons/lang/time/DateUtils.java b/src/java/org/apache/commons/lang/time/DateUtils.java index 2d03960a5..635691f5a 100644 --- a/src/java/org/apache/commons/lang/time/DateUtils.java +++ b/src/java/org/apache/commons/lang/time/DateUtils.java @@ -34,7 +34,7 @@ * @author Gary Gregory * @author Phil Steitz * @since 2.0 - * @version $Id: DateUtils.java,v 1.35 2004/10/16 21:06:18 scolebourne Exp $ + * @version $Id: DateUtils.java,v 1.36 2004/10/21 01:18:33 ggregory Exp $ */ public class DateUtils { @@ -739,6 +739,12 @@ public Object next() { return spot.clone(); } + /** + * Always throws UnsupportedOperationException. + * + * @throws UnsupportedOperationException + * @see java.util.Iterator#remove() + */ public void remove() { throw new UnsupportedOperationException(); }