Commit 6d8b8de3 by Tom Tromey Committed by Tom Tromey

CloneNotSupportedException.java: Re-merged with Classpath.

	* java/lang/CloneNotSupportedException.java: Re-merged with
	Classpath.

From-SVN: r45599
parent 5de7e417
2001-09-14 Tom Tromey <tromey@redhat.com>
* java/lang/CloneNotSupportedException.java: Re-merged with
Classpath.
2001-09-14 Bryce McKinlay <bryce@waitaki.otago.ac.nz> 2001-09-14 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
* java/io/File.java (normalizePath): Use equals() not '==' for string * java/io/File.java (normalizePath): Use equals() not '==' for string
......
...@@ -36,36 +36,42 @@ package java.lang; ...@@ -36,36 +36,42 @@ package java.lang;
*/ */
/** /**
* Exceptions may be thrown by one part of a Java program and caught * Thrown to indicate an object should not or could not be cloned. This
* by another in order to deal with exceptional conditions. * includes the case when {@link Object#clone()} is called on an object
* Thrown to indicate an object should not or could not be cloned. * which does not implement the {@link Cloneable} interface.
* For example <code>CloneNotSupportedException</code> is thrown by * <p>
* the <code>clone</code> method of <code>Object</code> to indicate *
* that object does not implement the <code>Cloneable</code> interface. * Notice that calling <code>clone()</code> on an array will never produce
* this exception, as the VM will always succeed in copying the array, or
* cause an OutOfMemoryError first.
* *
* @since JDK 1.0
*
* @author Brian Jones * @author Brian Jones
* @author Warren Levy <warrenl@cygnus.com> * @author Warren Levy <warrenl@cygnus.com>
* @date September 18, 1998. * @author Eric Blake <ebb9@email.byu.edu>
* @since 1.0
* @see Cloneable
* @see Object#clone()
*/ */
public class CloneNotSupportedException extends Exception public class CloneNotSupportedException extends Exception
{ {
static final long serialVersionUID = 5195511250079656443L; /**
* compatible with JDK 1.0+
*/
private static final long serialVersionUID = 5195511250079656443L;
/** /**
* Create an exception without a message. * Create an exception without a message.
*/ */
public CloneNotSupportedException() public CloneNotSupportedException()
{ {
super(); }
}
/** /**
* Create an exception with a message. * Create an exception with a message.
* @param s the error message
*/ */
public CloneNotSupportedException(String s) public CloneNotSupportedException(String s)
{ {
super(s); super(s);
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment