You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by sc...@apache.org on 2003/05/16 18:14:22 UTC

cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang IllegalClassException.java IncompleteArgumentException.java NotImplementedException.java UnhandledException.java NullArgumentException.java

scolebourne    2003/05/16 09:14:18

  Modified:    lang/src/java/org/apache/commons/lang
                        IllegalClassException.java
                        IncompleteArgumentException.java
                        NotImplementedException.java
                        UnhandledException.java NullArgumentException.java
  Log:
  Add since tags
  Update javadoc
  
  Revision  Changes    Path
  1.2       +11 -7     jakarta-commons/lang/src/java/org/apache/commons/lang/IllegalClassException.java
  
  Index: IllegalClassException.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/IllegalClassException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- IllegalClassException.java	15 May 2003 04:05:11 -0000	1.1
  +++ IllegalClassException.java	16 May 2003 16:14:16 -0000	1.2
  @@ -57,14 +57,16 @@
    * Thrown when an object is an instance of an unexpected class.
    * 
    * @author Matthew Hawthorne
  + * @since 2.0
    * @version $Id$
    */
   public class IllegalClassException extends IllegalArgumentException {
   
       /**
        * Instantiates with the specified classes.
  -     * @param expected the expected type
  -     * @param actual the actual type
  +     * 
  +     * @param expected  the expected type
  +     * @param actual  the actual type
        */
       public IllegalClassException(Class expected, Class actual) {
           super(
  @@ -76,7 +78,8 @@
   
       /**
        * Instantiates with the specified classes.
  -     * @param message the exception message
  +     * 
  +     * @param message  the exception message
        */
       public IllegalClassException(String message) {
           super(message);
  @@ -84,11 +87,12 @@
   
       /**
        * Gets a classname without throwing an Exception.
  -     * @param c a <code>Class</code>
  +     * 
  +     * @param cls  a <code>Class</code>
        * @return the name of <code>c</code>, or a <code>null</code> <code>String</code>
        */
  -    private static final String safeGetClassName(Class c) {
  -        return c == null ? null : c.getName();
  +    private static final String safeGetClassName(Class cls) {
  +        return cls == null ? null : cls.getName();
       }
   
   }
  
  
  
  1.2       +9 -4      jakarta-commons/lang/src/java/org/apache/commons/lang/IncompleteArgumentException.java
  
  Index: IncompleteArgumentException.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/IncompleteArgumentException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- IncompleteArgumentException.java	15 May 2003 04:05:11 -0000	1.1
  +++ IncompleteArgumentException.java	16 May 2003 16:14:17 -0000	1.2
  @@ -59,13 +59,15 @@
    * Thrown to indicate an incomplete argument to a method.
    * 
    * @author Matthew Hawthorne
  + * @since 2.0
    * @version $Id$
    */
   public class IncompleteArgumentException extends IllegalArgumentException {
   
       /**
        * Instantiates with the specified description.
  -     * @param argName a description of the incomplete argument
  +     * 
  +     * @param argName  a description of the incomplete argument
        */
       public IncompleteArgumentException(String argName) {
           super(argName + " is incomplete.");
  @@ -73,7 +75,9 @@
   
       /**
        * Instantiates with the specified description.
  -     * @param item a description of the incomplete argument
  +     * 
  +     * @param argName  a description of the incomplete argument
  +     * @param items  an array describing the arguments missing
        */
       public IncompleteArgumentException(String argName, String[] items) {
           super(
  @@ -84,7 +88,8 @@
   
       /**
        * Converts an array to a string without throwing an exception.
  -     * @param array an array
  +     * 
  +     * @param array  an array
        * @return the array as a string
        */
       private static final String safeArrayToString(Object[] array) {
  
  
  
  1.2       +8 -5      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.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- NotImplementedException.java	15 May 2003 04:05:11 -0000	1.1
  +++ NotImplementedException.java	16 May 2003 16:14:17 -0000	1.2
  @@ -57,13 +57,15 @@
    * Thrown to indicate that a method has not been implemented.
    * 
    * @author Matthew Hawthorne
  + * @since 2.0
    * @version $Id$
    */
   public class NotImplementedException extends UnsupportedOperationException {
   
       /**
  -     * Instantites with the specified class.
  -     * @param clazz the <code>Class</code> that has not implemented the method
  +     * Constructes the exception with the specified class.
  +     * 
  +     * @param clazz  the <code>Class</code> that has not implemented the method
        */
       public NotImplementedException(Class clazz) {
           super(
  @@ -72,8 +74,9 @@
       }
   
       /**
  -     * Instantites with the specified msg.
  -     * @param msg the exception message.
  +     * Constructs the exception with the specified message.
  +     * 
  +     * @param msg  the exception message.
        */
       public NotImplementedException(String msg) {
           super(msg);
  
  
  
  1.2       +13 -1     jakarta-commons/lang/src/java/org/apache/commons/lang/UnhandledException.java
  
  Index: UnhandledException.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/UnhandledException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- UnhandledException.java	15 May 2003 04:05:11 -0000	1.1
  +++ UnhandledException.java	16 May 2003 16:14:17 -0000	1.2
  @@ -60,14 +60,26 @@
    * or throw a checked exception.
    * 
    * @author Matthew Hawthorne
  + * @since 2.0
    * @version $Id$
    */
   public class UnhandledException extends NestableRuntimeException {
   
  +    /**
  +     * Constructs the exception using a cause.
  +     * 
  +     * @param cause  the underlying cause
  +     */
   	public UnhandledException(Throwable cause) {
   		super(cause);
   	}
   
  +    /**
  +     * Constructs the exception using a message and cause.
  +     * 
  +     * @param message  the message to use
  +     * @param cause  the underlying cause
  +     */
   	public UnhandledException(String message, Throwable cause) {
   		super(message, cause);
   	}
  
  
  
  1.2       +4 -2      jakarta-commons/lang/src/java/org/apache/commons/lang/NullArgumentException.java
  
  Index: NullArgumentException.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/NullArgumentException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- NullArgumentException.java	15 May 2003 04:05:11 -0000	1.1
  +++ NullArgumentException.java	16 May 2003 16:14:17 -0000	1.2
  @@ -57,13 +57,15 @@
    * Thrown to indicate that an argument was null and should not have been.
    * 
    * @author Matthew Hawthorne
  + * @since 2.0
    * @version $Id$
    */
   public class NullArgumentException extends IllegalArgumentException {
   
   	/**
   	 * Instantiates with the given argument name.
  -	 * @param argName - the name of the argument that was null.
  +     * 
  +	 * @param argName  the name of the argument that was null.
   	 */
   	public NullArgumentException(String argName) {
   		super(argName + " cannot be null.");
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org