You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by sc...@apache.org on 2009/10/27 00:43:10 UTC

svn commit: r830024 - in /commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable: MutableBoolean.java MutableByte.java MutableDouble.java MutableFloat.java MutableInt.java MutableLong.java MutableShort.java

Author: scolebourne
Date: Mon Oct 26 23:43:09 2009
New Revision: 830024

URL: http://svn.apache.org/viewvc?rev=830024&view=rev
Log:
Javadoc clarifications and tidy

Modified:
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableBoolean.java
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableByte.java
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableDouble.java
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableFloat.java
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableInt.java
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableLong.java
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableShort.java

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableBoolean.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableBoolean.java?rev=830024&r1=830023&r2=830024&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableBoolean.java (original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableBoolean.java Mon Oct 26 23:43:09 2009
@@ -49,8 +49,7 @@
     /**
      * Constructs a new MutableBoolean with the specified value.
      * 
-     * @param value
-     *            a value.
+     * @param value  the initial value to store
      */
     public MutableBoolean(boolean value) {
         super();
@@ -60,10 +59,8 @@
     /**
      * Constructs a new MutableBoolean with the specified value.
      * 
-     * @param value
-     *            a value.
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the initial value to store, not null
+     * @throws NullPointerException if the object is null
      */
     public MutableBoolean(Boolean value) {
         super();
@@ -94,11 +91,9 @@
     /**
      * Compares this mutable to another in ascending order.
      * 
-     * @param other
-     *            the mutable to compare to
-     * @return zero if this object represents the same boolean value as the argument; a positive value if this object
-     *         represents true and the argument represents false; and a negative value if this object represents false
-     *         and the argument represents true
+     * @param other  the other mutable to compare to, not null
+     * @return negative if this is less, zero if equal, positive if greater
+     *  where false is less than true
      */
     public int compareTo(MutableBoolean other) {
         boolean anotherVal = other.value;
@@ -111,8 +106,7 @@
      * not <code>null</code> and is an <code>MutableBoolean</code> object that contains the same
      * <code>boolean</code> value as this object.
      * 
-     * @param obj
-     *            the object to compare with.
+     * @param obj  the object to compare with, null returns false
      * @return <code>true</code> if the objects are the same; <code>false</code> otherwise.
      */
     @Override
@@ -127,17 +121,16 @@
     /**
      * Gets the value as a Boolean instance.
      * 
-     * @return the value as a Boolean
+     * @return the value as a Boolean, never null
      */
     public Boolean getValue() {
         return Boolean.valueOf(this.value);
     }
 
     /**
-     * Returns a suitable hashcode for this mutable.
+     * Returns a suitable hash code for this mutable.
      * 
-     * @return the integer <code>1231</code> if this object represents <code>true</code>; returns the integer
-     *         <code>1237</code> if this object represents <code>false</code>.
+     * @return the hash code returned by <code>Boolean.TRUE</code> or <code>Boolean.FALSE</code>
      */
     @Override
     public int hashCode() {
@@ -147,8 +140,7 @@
     /**
      * Sets the value.
      * 
-     * @param value
-     *            the value to set
+     * @param value  the value to set
      */
     public void setValue(boolean value) {
         this.value = value;
@@ -157,15 +149,14 @@
     /**
      * Sets the value from any Boolean instance.
      * 
-     * @param value
-     *            the value to set
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the value to set, not null
+     * @throws NullPointerException if the object is null
      */
     public void setValue(Boolean value) {
         this.value = value.booleanValue();
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Returns the String value of this mutable.
      * 

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableByte.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableByte.java?rev=830024&r1=830023&r2=830024&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableByte.java (original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableByte.java Mon Oct 26 23:43:09 2009
@@ -45,8 +45,7 @@
     /**
      * Constructs a new MutableByte with the specified value.
      * 
-     * @param value
-     *            a value.
+     * @param value  the initial value to store
      */
     public MutableByte(byte value) {
         super();
@@ -56,10 +55,8 @@
     /**
      * Constructs a new MutableByte with the specified value.
      * 
-     * @param value
-     *            a value.
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the initial value to store, not null
+     * @throws NullPointerException if the object is null
      */
     public MutableByte(Number value) {
         super();
@@ -69,10 +66,8 @@
     /**
      * Constructs a new MutableByte parsing the given string.
      * 
-     * @param value
-     *                  the string to parse.
-     * @throws NumberFormatException
-     *                  if the string cannot be parsed into a byte
+     * @param value  the string to parse, not null
+     * @throws NumberFormatException if the string cannot be parsed into a byte
      */
     public MutableByte(String value) throws NumberFormatException {
         super();
@@ -83,7 +78,7 @@
     /**
      * Gets the value as a Byte instance.
      * 
-     * @return the value as a Byte
+     * @return the value as a Byte, never null
      */
     public Byte getValue() {
         return Byte.valueOf(this.value);
@@ -92,8 +87,7 @@
     /**
      * Sets the value.
      * 
-     * @param value
-     *            the value to set
+     * @param value  the value to set
      */
     public void setValue(byte value) {
         this.value = value;
@@ -102,10 +96,8 @@
     /**
      * Sets the value from any Number instance.
      * 
-     * @param value
-     *            the value to set
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the value to set, not null
+     * @throws NullPointerException if the object is null
      */
     public void setValue(Number value) {
         this.value = value.byteValue();
@@ -124,7 +116,7 @@
     }
 
     /**
-     * Returns the value of this MutableByte as a int.
+     * Returns the value of this MutableByte as an int.
      *
      * @return the numeric value represented by this object after conversion to type int.
      */
@@ -194,11 +186,9 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to add, not null
      * @since Commons Lang 2.2
      */
     public void add(byte operand) {
@@ -206,13 +196,10 @@
     }
 
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to add, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void add(Number operand) {
@@ -220,11 +207,9 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to subtract, not null
      * @since Commons Lang 2.2
      */
     public void subtract(byte operand) {
@@ -232,13 +217,10 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to subtract, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void subtract(Number operand) {
@@ -247,12 +229,11 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Compares this object against the specified object. The result is <code>true</code> if and only if the argument
-     * is not <code>null</code> and is a <code>MutableByte</code> object that contains the same <code>byte</code>
-     * value as this object.
+     * Compares this object to the specified object. The result is <code>true</code> if and only if the argument is
+     * not <code>null</code> and is a <code>MutableByte</code> object that contains the same <code>byte</code> value
+     * as this object.
      * 
-     * @param obj
-     *            the object to compare with.
+     * @param obj  the object to compare with, null returns false
      * @return <code>true</code> if the objects are the same; <code>false</code> otherwise.
      */
     @Override
@@ -264,28 +245,28 @@
     }
 
     /**
-     * Returns a suitable hashcode for this mutable.
+     * Returns a suitable hash code for this mutable.
      * 
-     * @return a suitable hashcode
+     * @return a suitable hash code
      */
     @Override
     public int hashCode() {
         return value;
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Compares this mutable to another in ascending order.
      * 
-     * @param other
-     *            the mutable to compare to
+     * @param other  the other mutable to compare to, not null
      * @return negative if this is less, zero if equal, positive if greater
-     * @throws ClassCastException if the argument is not a MutableByte
      */
     public int compareTo(MutableByte other) {
         byte anotherVal = other.value;
         return value < anotherVal ? -1 : (value == anotherVal ? 0 : 1);
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Returns the String value of this mutable.
      * 

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableDouble.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableDouble.java?rev=830024&r1=830023&r2=830024&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableDouble.java (original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableDouble.java Mon Oct 26 23:43:09 2009
@@ -45,8 +45,7 @@
     /**
      * Constructs a new MutableDouble with the specified value.
      * 
-     * @param value
-     *            a value.
+     * @param value  the initial value to store
      */
     public MutableDouble(double value) {
         super();
@@ -56,10 +55,8 @@
     /**
      * Constructs a new MutableDouble with the specified value.
      * 
-     * @param value
-     *            a value.
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the initial value to store, not null
+     * @throws NullPointerException if the object is null
      */
     public MutableDouble(Number value) {
         super();
@@ -69,10 +66,8 @@
     /**
      * Constructs a new MutableDouble parsing the given string.
      * 
-     * @param value
-     *                  the string to parse.
-     * @throws NumberFormatException
-     *                  if the string cannot be parsed into a double
+     * @param value  the string to parse, not null
+     * @throws NumberFormatException if the string cannot be parsed into a double
      */
     public MutableDouble(String value) throws NumberFormatException {
         super();
@@ -83,7 +78,7 @@
     /**
      * Gets the value as a Double instance.
      * 
-     * @return the value as a Double
+     * @return the value as a Double, never null
      */
     public Double getValue() {
         return new Double(this.value);
@@ -92,8 +87,7 @@
     /**
      * Sets the value.
      * 
-     * @param value
-     *            the value to set
+     * @param value  the value to set
      */
     public void setValue(double value) {
         this.value = value;
@@ -102,10 +96,8 @@
     /**
      * Sets the value from any Number instance.
      * 
-     * @param value
-     *            the value to set
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the value to set, not null
+     * @throws NullPointerException if the object is null
      */
     public void setValue(Number value) {
         this.value = value.doubleValue();
@@ -114,7 +106,7 @@
     //-----------------------------------------------------------------------
     // shortValue and bytValue rely on Number implementation
     /**
-     * Returns the value of this MutableDouble as a int.
+     * Returns the value of this MutableDouble as an int.
      *
      * @return the numeric value represented by this object after conversion to type int.
      */
@@ -202,11 +194,9 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to add
      * @since Commons Lang 2.2
      */
     public void add(double operand) {
@@ -214,13 +204,10 @@
     }
 
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to add, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void add(Number operand) {
@@ -228,11 +215,9 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to subtract, not null
      * @since Commons Lang 2.2
      */
     public void subtract(double operand) {
@@ -240,13 +225,10 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to subtract, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void subtract(Number operand) {
@@ -280,8 +262,7 @@
      * <code>+0.0==-0.0</code> has the value <code>true</code>. This allows hashtables to operate properly.
      * </ul>
      * 
-     * @param obj
-     *            the object to compare with.
+     * @param obj  the object to compare with, null returns false
      * @return <code>true</code> if the objects are the same; <code>false</code> otherwise.
      */
     @Override
@@ -291,9 +272,9 @@
     }
 
     /**
-     * Returns a suitable hashcode for this mutable.
+     * Returns a suitable hash code for this mutable.
      * 
-     * @return a suitable hashcode
+     * @return a suitable hash code
      */
     @Override
     public int hashCode() {
@@ -301,11 +282,11 @@
         return (int) (bits ^ (bits >>> 32));
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Compares this mutable to another in ascending order.
      * 
-     * @param other
-     *            the mutable to compare to
+     * @param other  the other mutable to compare to, not null
      * @return negative if this is less, zero if equal, positive if greater
      */
     public int compareTo(MutableDouble other) {
@@ -313,6 +294,7 @@
         return Double.compare(value, anotherVal);
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Returns the String value of this mutable.
      * 

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableFloat.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableFloat.java?rev=830024&r1=830023&r2=830024&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableFloat.java (original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableFloat.java Mon Oct 26 23:43:09 2009
@@ -45,8 +45,7 @@
     /**
      * Constructs a new MutableFloat with the specified value.
      * 
-     * @param value
-     *            a value.
+     * @param value  the initial value to store
      */
     public MutableFloat(float value) {
         super();
@@ -56,10 +55,8 @@
     /**
      * Constructs a new MutableFloat with the specified value.
      * 
-     * @param value
-     *            a value.
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the initial value to store, not null
+     * @throws NullPointerException if the object is null
      */
     public MutableFloat(Number value) {
         super();
@@ -69,10 +66,8 @@
     /**
      * Constructs a new MutableFloat parsing the given string.
      * 
-     * @param value
-     *                  the string to parse.
-     * @throws NumberFormatException
-     *                  if the string cannot be parsed into a float
+     * @param value  the string to parse, not null
+     * @throws NumberFormatException if the string cannot be parsed into a float
      */
     public MutableFloat(String value) throws NumberFormatException {
         super();
@@ -83,7 +78,7 @@
     /**
      * Gets the value as a Float instance.
      * 
-     * @return the value as a Float
+     * @return the value as a Float, never null
      */
     public Float getValue() {
         return new Float(this.value);
@@ -92,8 +87,7 @@
     /**
      * Sets the value.
      * 
-     * @param value
-     *            the value to set
+     * @param value  the value to set
      */
     public void setValue(float value) {
         this.value = value;
@@ -102,10 +96,8 @@
     /**
      * Sets the value from any Number instance.
      * 
-     * @param value
-     *            the value to set
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the value to set, not null
+     * @throws NullPointerException if the object is null
      */
     public void setValue(Number value) {
         this.value = value.floatValue();
@@ -132,11 +124,9 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to add, not null
      * @since Commons Lang 2.2
      */
     public void add(float operand) {
@@ -144,13 +134,10 @@
     }
 
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to add, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void add(Number operand) {
@@ -158,11 +145,9 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to subtract
      * @since Commons Lang 2.2
      */
     public void subtract(float operand) {
@@ -170,13 +155,10 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to subtract, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void subtract(Number operand) {
@@ -186,7 +168,7 @@
     //-----------------------------------------------------------------------
     // shortValue and bytValue rely on Number implementation
     /**
-     * Returns the value of this MutableFloat as a int.
+     * Returns the value of this MutableFloat as an int.
      *
      * @return the numeric value represented by this object after conversion to type int.
      */
@@ -281,8 +263,7 @@
      * </ul>
      * This definition allows hashtables to operate properly.
      * 
-     * @param obj
-     *            the object to be compared
+     * @param obj  the object to compare with, null returns false
      * @return <code>true</code> if the objects are the same; <code>false</code> otherwise.
      * @see java.lang.Float#floatToIntBits(float)
      */
@@ -292,22 +273,21 @@
             && (Float.floatToIntBits(((MutableFloat) obj).value) == Float.floatToIntBits(value));
     }
 
-    //-----------------------------------------------------------------------
     /**
-     * Returns a suitable hashcode for this mutable.
+     * Returns a suitable hash code for this mutable.
      * 
-     * @return a suitable hashcode
+     * @return a suitable hash code
      */
     @Override
     public int hashCode() {
         return Float.floatToIntBits(value);
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Compares this mutable to another in ascending order.
      * 
-     * @param other
-     *            the mutable to compare to
+     * @param other  the other mutable to compare to, not null
      * @return negative if this is less, zero if equal, positive if greater
      */
     public int compareTo(MutableFloat other) {
@@ -315,6 +295,7 @@
         return Float.compare(value, anotherVal);
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Returns the String value of this mutable.
      * 

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableInt.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableInt.java?rev=830024&r1=830023&r2=830024&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableInt.java (original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableInt.java Mon Oct 26 23:43:09 2009
@@ -45,8 +45,7 @@
     /**
      * Constructs a new MutableInt with the specified value.
      * 
-     * @param value
-     *                  a value.
+     * @param value  the initial value to store
      */
     public MutableInt(int value) {
         super();
@@ -56,10 +55,8 @@
     /**
      * Constructs a new MutableInt with the specified value.
      * 
-     * @param value
-     *                  a value.
-     * @throws NullPointerException
-     *                  if the object is null
+     * @param value  the initial value to store, not null
+     * @throws NullPointerException if the object is null
      */
     public MutableInt(Number value) {
         super();
@@ -69,10 +66,8 @@
     /**
      * Constructs a new MutableInt parsing the given string.
      * 
-     * @param value
-     *                  the string to parse.
-     * @throws NumberFormatException
-     *                  if the string cannot be parsed into an int
+     * @param value  the string to parse, not null
+     * @throws NumberFormatException if the string cannot be parsed into an int
      */
     public MutableInt(String value) throws NumberFormatException {
         super();
@@ -83,7 +78,7 @@
     /**
      * Gets the value as a Integer instance.
      * 
-     * @return the value as a Integer
+     * @return the value as a Integer, never null
      */
     public Integer getValue() {
         return new Integer(this.value);
@@ -92,8 +87,7 @@
     /**
      * Sets the value.
      * 
-     * @param value
-     *                  the value to set
+     * @param value  the value to set
      */
     public void setValue(int value) {
         this.value = value;
@@ -102,12 +96,8 @@
     /**
      * Sets the value from any Number instance.
      * 
-     * @param value
-     *                  the value to set
-     * @throws NullPointerException
-     *                  if the object is null
-     * @throws ClassCastException
-     *                  if the type is not a {@link Number}
+     * @param value  the value to set, not null
+     * @throws NullPointerException if the object is null
      */
     public void setValue(Number value) {
         this.value = value.intValue();
@@ -134,11 +124,9 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to add, not null
      * @since Commons Lang 2.2
      */
     public void add(int operand) {
@@ -146,13 +134,10 @@
     }
 
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to add, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void add(Number operand) {
@@ -160,11 +145,9 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to subtract, not null
      * @since Commons Lang 2.2
      */
     public void subtract(int operand) {
@@ -172,13 +155,10 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to subtract, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void subtract(Number operand) {
@@ -188,7 +168,7 @@
     //-----------------------------------------------------------------------
     // shortValue and bytValue rely on Number implementation
     /**
-     * Returns the value of this MutableInt as a int.
+     * Returns the value of this MutableInt as an int.
      *
      * @return the numeric value represented by this object after conversion to type int.
      */
@@ -240,11 +220,10 @@
     //-----------------------------------------------------------------------
     /**
      * Compares this object to the specified object. The result is <code>true</code> if and only if the argument is
-     * not <code>null</code> and is an <code>MutableInt</code> object that contains the same <code>int</code> value
+     * not <code>null</code> and is a <code>MutableInt</code> object that contains the same <code>int</code> value
      * as this object.
      * 
-     * @param obj
-     *                  the object to compare with.
+     * @param obj  the object to compare with, null returns false
      * @return <code>true</code> if the objects are the same; <code>false</code> otherwise.
      */
     @Override
@@ -256,20 +235,20 @@
     }
 
     /**
-     * Returns a suitable hashcode for this mutable.
+     * Returns a suitable hash code for this mutable.
      * 
-     * @return a suitable hashcode
+     * @return a suitable hash code
      */
     @Override
     public int hashCode() {
         return value;
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Compares this mutable to another in ascending order.
      * 
-     * @param other
-     *                  the mutable to compare to
+     * @param other  the other mutable to compare to, not null
      * @return negative if this is less, zero if equal, positive if greater
      */
     public int compareTo(MutableInt other) {
@@ -277,6 +256,7 @@
         return value < anotherVal ? -1 : (value == anotherVal ? 0 : 1);
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Returns the String value of this mutable.
      * 

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableLong.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableLong.java?rev=830024&r1=830023&r2=830024&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableLong.java (original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableLong.java Mon Oct 26 23:43:09 2009
@@ -45,8 +45,7 @@
     /**
      * Constructs a new MutableLong with the specified value.
      * 
-     * @param value
-     *            a value.
+     * @param value  the initial value to store
      */
     public MutableLong(long value) {
         super();
@@ -56,10 +55,8 @@
     /**
      * Constructs a new MutableLong with the specified value.
      * 
-     * @param value
-     *            a value.
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the initial value to store, not null
+     * @throws NullPointerException if the object is null
      */
     public MutableLong(Number value) {
         super();
@@ -69,10 +66,8 @@
     /**
      * Constructs a new MutableLong parsing the given string.
      * 
-     * @param value
-     *                  the string to parse.
-     * @throws NumberFormatException
-     *                  if the string cannot be parsed into a long
+     * @param value  the string to parse, not null
+     * @throws NumberFormatException if the string cannot be parsed into a long
      */
     public MutableLong(String value) throws NumberFormatException {
         super();
@@ -83,7 +78,7 @@
     /**
      * Gets the value as a Long instance.
      * 
-     * @return the value as a Long
+     * @return the value as a Long, never null
      */
     public Long getValue() {
         return new Long(this.value);
@@ -92,8 +87,7 @@
     /**
      * Sets the value.
      * 
-     * @param value
-     *            the value to set
+     * @param value  the value to set
      */
     public void setValue(long value) {
         this.value = value;
@@ -102,10 +96,8 @@
     /**
      * Sets the value from any Number instance.
      * 
-     * @param value
-     *            the value to set
-     * @throws NullPointerException
-     *             if the object is null
+     * @param value  the value to set, not null
+     * @throws NullPointerException if the object is null
      */
     public void setValue(Number value) {
         this.value = value.longValue();
@@ -132,11 +124,9 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to add, not null
      * @since Commons Lang 2.2
      */
     public void add(long operand) {
@@ -144,13 +134,10 @@
     }
 
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to add, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void add(Number operand) {
@@ -158,11 +145,9 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to subtract, not null
      * @since Commons Lang 2.2
      */
     public void subtract(long operand) {
@@ -170,13 +155,10 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to subtract, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void subtract(Number operand) {
@@ -186,7 +168,7 @@
     //-----------------------------------------------------------------------
     // shortValue and bytValue rely on Number implementation
     /**
-     * Returns the value of this MutableLong as a int.
+     * Returns the value of this MutableLong as an int.
      *
      * @return the numeric value represented by this object after conversion to type int.
      */
@@ -237,12 +219,11 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Compares this object against the specified object. The result is <code>true</code> if and only if the argument
+     * Compares this object to the specified object. The result is <code>true</code> if and only if the argument
      * is not <code>null</code> and is a <code>MutableLong</code> object that contains the same <code>long</code>
      * value as this object.
      * 
-     * @param obj
-     *            the object to compare with.
+     * @param obj  the object to compare with, null returns false
      * @return <code>true</code> if the objects are the same; <code>false</code> otherwise.
      */
     @Override
@@ -254,20 +235,20 @@
     }
 
     /**
-     * Returns a suitable hashcode for this mutable.
+     * Returns a suitable hash code for this mutable.
      * 
-     * @return a suitable hashcode
+     * @return a suitable hash code
      */
     @Override
     public int hashCode() {
         return (int) (value ^ (value >>> 32));
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Compares this mutable to another in ascending order.
      * 
-     * @param other
-     *            the mutable to compare to
+     * @param other  the other mutable to compare to, not null
      * @return negative if this is less, zero if equal, positive if greater
      */
     public int compareTo(MutableLong other) {
@@ -275,6 +256,7 @@
         return value < anotherVal ? -1 : (value == anotherVal ? 0 : 1);
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Returns the String value of this mutable.
      * 

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableShort.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableShort.java?rev=830024&r1=830023&r2=830024&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableShort.java (original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/mutable/MutableShort.java Mon Oct 26 23:43:09 2009
@@ -45,8 +45,7 @@
     /**
      * Constructs a new MutableShort with the specified value.
      * 
-     * @param value
-     *                  a value.
+     * @param value  the initial value to store
      */
     public MutableShort(short value) {
         super();
@@ -56,10 +55,8 @@
     /**
      * Constructs a new MutableShort with the specified value.
      * 
-     * @param value
-     *                  a value.
-     * @throws NullPointerException
-     *                  if the object is null
+     * @param value  the initial value to store, not null
+     * @throws NullPointerException if the object is null
      */
     public MutableShort(Number value) {
         super();
@@ -69,10 +66,8 @@
     /**
      * Constructs a new MutableShort parsing the given string.
      * 
-     * @param value
-     *                  the string to parse.
-     * @throws NumberFormatException
-     *                  if the string cannot be parsed into a short
+     * @param value  the string to parse, not null
+     * @throws NumberFormatException if the string cannot be parsed into a short
      */
     public MutableShort(String value) throws NumberFormatException {
         super();
@@ -83,7 +78,7 @@
     /**
      * Gets the value as a Short instance.
      * 
-     * @return the value as a Short
+     * @return the value as a Short, never null
      */
     public Short getValue() {
         return new Short(this.value);
@@ -92,8 +87,7 @@
     /**
      * Sets the value.
      * 
-     * @param value
-     *                  the value to set
+     * @param value  the value to set
      */
     public void setValue(short value) {
         this.value = value;
@@ -102,10 +96,8 @@
     /**
      * Sets the value from any Number instance.
      * 
-     * @param value
-     *                  the value to set
-     * @throws NullPointerException
-     *                  if the object is null
+     * @param value  the value to set, not null
+     * @throws NullPointerException if the object is null
      */
     public void setValue(Number value) {
         this.value = value.shortValue();
@@ -132,11 +124,9 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to add, not null
      * @since Commons Lang 2.2
      */
     public void add(short operand) {
@@ -144,13 +134,10 @@
     }
 
     /**
-     * Adds a value.
+     * Adds a value to the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to add, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void add(Number operand) {
@@ -158,11 +145,9 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     *
+     * @param operand  the value to subtract, not null
      * @since Commons Lang 2.2
      */
     public void subtract(short operand) {
@@ -170,13 +155,10 @@
     }
 
     /**
-     * Subtracts a value.
+     * Subtracts a value from the value of this instance.
      * 
-     * @param operand
-     *            the value to add
-     * @throws NullPointerException
-     *             if the object is null
-     *
+     * @param operand  the value to subtract, not null
+     * @throws NullPointerException if the object is null
      * @since Commons Lang 2.2
      */
     public void subtract(Number operand) {
@@ -196,7 +178,7 @@
     }
 
     /**
-     * Returns the value of this MutableShort as a int.
+     * Returns the value of this MutableShort as an int.
      *
      * @return the numeric value represented by this object after conversion to type int.
      */
@@ -247,12 +229,11 @@
 
     //-----------------------------------------------------------------------
     /**
-     * Compares this object against the specified object. The result is <code>true</code> if and only if the argument
+     * Compares this object to the specified object. The result is <code>true</code> if and only if the argument
      * is not <code>null</code> and is a <code>MutableShort</code> object that contains the same <code>short</code>
      * value as this object.
      * 
-     * @param obj
-     *                  the object to compare with.
+     * @param obj  the object to compare with, null returns false
      * @return <code>true</code> if the objects are the same; <code>false</code> otherwise.
      */
     @Override
@@ -264,20 +245,20 @@
     }
 
     /**
-     * Returns a suitable hashcode for this mutable.
+     * Returns a suitable hash code for this mutable.
      * 
-     * @return a suitable hashcode
+     * @return a suitable hash code
      */
     @Override
     public int hashCode() {
         return value;
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Compares this mutable to another in ascending order.
      * 
-     * @param other
-     *                  the mutable to compare to
+     * @param other  the other mutable to compare to, not null
      * @return negative if this is less, zero if equal, positive if greater
      */
     public int compareTo(MutableShort other) {
@@ -285,6 +266,7 @@
         return value < anotherVal ? -1 : (value == anotherVal ? 0 : 1);
     }
 
+    //-----------------------------------------------------------------------
     /**
      * Returns the String value of this mutable.
      *