ggregory 2004/10/20 18:18:34
Modified: lang/src/java/org/apache/commons/lang/math LongRange.java
JVMRandom.java
lang/src/java/org/apache/commons/lang
NotImplementedException.java ClassUtils.java
lang/src/java/org/apache/commons/lang/time DateUtils.java
lang/src/java/org/apache/commons/lang/exception
ExceptionUtils.java
lang/src/java/org/apache/commons/lang/text
MappedMessageFormat.java
Log:
Javadoc only.
Revision Changes Path
1.8 +5 -1
jakarta-commons/lang/src/java/org/apache/commons/lang/math/LongRange.java
Index: LongRange.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/math/LongRange.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- LongRange.java 18 Feb 2004 22:56:13 -0000 1.7
+++ LongRange.java 21 Oct 2004 01:18:33 -0000 1.8
@@ -240,6 +240,8 @@
* <p>Gets the maximum number in this range as a <code>double</code>.</p>
*
* <p>This conversion can lose information for large values.</p>
+ *
+ * @return The maximum number in this range as a <code>double</code>.
*/
public double getMaximumDouble() {
return max;
@@ -249,6 +251,8 @@
* <p>Gets the maximum number in this range as a <code>float</code>.</p>
*
* <p>This conversion can lose information for large values.</p>
+ *
+ * @return The maximum number in this range as a <code>float</code>.
*/
public float getMaximumFloat() {
return max;
1.11 +10 -1
jakarta-commons/lang/src/java/org/apache/commons/lang/math/JVMRandom.java
Index: JVMRandom.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/math/JVMRandom.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- JVMRandom.java 18 Feb 2004 22:56:13 -0000 1.10
+++ JVMRandom.java 21 Oct 2004 01:18:33 -0000 1.11
@@ -42,6 +42,9 @@
/**
* Unsupported in 2.0.
+ *
+ * @param seed ignored
+ * @throws UnsupportedOperationException
*/
public synchronized void setSeed(long seed) {
if (this.constructed) {
@@ -51,6 +54,9 @@
/**
* 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 @@
/**
* Unsupported in 2.0.
+ *
+ * @param byteArray ignored
+ * @throws UnsupportedOperationException
*/
public void nextBytes(byte[] byteArray) {
throw new UnsupportedOperationException();
1.10 +2 -1
jakarta-commons/lang/src/java/org/apache/commons/lang/NotImplementedException.java
Index: NotImplementedException.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/NotImplementedException.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- NotImplementedException.java 15 Oct 2004 20:55:01 -0000 1.9
+++ NotImplementedException.java 21 Oct 2004 01:18:33 -0000 1.10
@@ -122,6 +122,7 @@
//-----------------------------------------------------------------------
/**
* Gets the root cause of this exception.
+ * @return the root cause of this exception.
*
* @since 2.1
*/
1.33 +7 -1
jakarta-commons/lang/src/java/org/apache/commons/lang/ClassUtils.java
Index: ClassUtils.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/ClassUtils.java,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -r1.32 -r1.33
--- ClassUtils.java 15 Oct 2004 20:57:18 -0000 1.32
+++ ClassUtils.java 21 Oct 2004 01:18:33 -0000 1.33
@@ -505,6 +505,9 @@
private static class ClassNameComparator implements Comparator {
/**
* Compares two <code>Class</code>s by name.
+ * @param o1 The receiver of the comparison call to [EMAIL PROTECTED]
String#compareTo(String)}.
+ * @param o2 The argument of the comparison call to [EMAIL PROTECTED]
String#compareTo(String)}.
+ * @return The return value from [EMAIL PROTECTED] String#compareTo(String)}
*
* @throws ClassCastException
* If <code>o1</code> or <code>o2</code> are not
<code>Class</code>
@@ -536,6 +539,9 @@
/**
* Compares two <code>Package</code>s by name.
*
+ * @param o1 The receiver of the comparison call to [EMAIL PROTECTED]
String#compareTo(String)}.
+ * @param o2 The argument of the comparison call to [EMAIL PROTECTED]
String#compareTo(String)}.
+ * @return The return value from [EMAIL PROTECTED] String#compareTo(String)}
* @throws ClassCastException
* If <code>o1</code> or <code>o2</code> are not
<code>Package</code>
* instances.
1.36 +7 -1
jakarta-commons/lang/src/java/org/apache/commons/lang/time/DateUtils.java
Index: DateUtils.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/time/DateUtils.java,v
retrieving revision 1.35
retrieving revision 1.36
diff -u -r1.35 -r1.36
--- DateUtils.java 16 Oct 2004 21:06:18 -0000 1.35
+++ DateUtils.java 21 Oct 2004 01:18:33 -0000 1.36
@@ -739,6 +739,12 @@
return spot.clone();
}
+ /**
+ * Always throws UnsupportedOperationException.
+ *
+ * @throws UnsupportedOperationException
+ * @see java.util.Iterator#remove()
+ */
public void remove() {
throw new UnsupportedOperationException();
}
1.43 +6 -1
jakarta-commons/lang/src/java/org/apache/commons/lang/exception/ExceptionUtils.java
Index: ExceptionUtils.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/exception/ExceptionUtils.java,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -r1.42 -r1.43
--- ExceptionUtils.java 9 Oct 2004 10:04:04 -0000 1.42
+++ ExceptionUtils.java 21 Oct 2004 01:18:33 -0000 1.43
@@ -695,10 +695,15 @@
}
/**
+ * <p>Returns an array where each element is a line from the argument.</p>
+ * <p>The end of line is determined by the value of [EMAIL PROTECTED]
SystemUtils#LINE_SEPARATOR}.</p>
+ *
* <p>Functionality shared between the
* <code>getStackFrames(Throwable)</code> methods of this and the
* [EMAIL PROTECTED] org.apache.commons.lang.exception.NestableDelegate}
* classes.</p>
+ * @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;
1.4 +18 -4
jakarta-commons/lang/src/java/org/apache/commons/lang/text/MappedMessageFormat.java
Index: MappedMessageFormat.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/text/MappedMessageFormat.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- MappedMessageFormat.java 30 Sep 2004 16:57:18 -0000 1.3
+++ MappedMessageFormat.java 21 Oct 2004 01:18:34 -0000 1.4
@@ -48,12 +48,18 @@
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 <code>"$"</code>.
+ * @param source A Map where the keys are Strings and the values are
non-<code>null</code> Objects.
*/
public void addSource(String marker, Map source) {
nEntries++;
@@ -65,12 +71,15 @@
* 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<nEntries; i++) {
- param = format( param, (String) markers.get(i), (Map) sources.get(i));
+ param = format(param, (String) markers.get(i), (Map) sources.get(i));
}
return param;
}
@@ -79,14 +88,19 @@
* Replace any occurrences within the string of the form
* "marker{key}" with the value from source[key].
* <p>
- * Commonly, the variable marker is "$", in which case variables
- * are indicated by ${key} in the string.
+ * Commonly, the variable marker is <code>"$"</code>, in which case variables
+ * are indicated by <code>${key}</code> in the string.
* <p>
* Returns the string after performing all substitutions.
* <p>
* 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, <code>"$"</code>, in which case
variables
+ * are indicated by <code>${key}</code> in the string.
+ * @param source A Map where the keys are Strings and the values are
non-<code>null</code> 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.
*/
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]