KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > netbeans > modules > classfile > InvalidClassFormatException


1 /*
2  * InvalidClassFormatException.java
3  *
4  * The contents of this file are subject to the terms of the Common Development
5  * and Distribution License (the License). You may not use this file except in
6  * compliance with the License.
7  *
8  * You can obtain a copy of the License at http://www.netbeans.org/cddl.html
9  * or http://www.netbeans.org/cddl.txt.
10  *
11  * When distributing Covered Code, include this CDDL Header Notice in each file
12  * and include the License file at http://www.netbeans.org/cddl.txt.
13  * If applicable, add the following below the CDDL Header, with the fields
14  * enclosed by brackets [] replaced by your own identifying information:
15  * "Portions Copyrighted [year] [name of copyright owner]"
16  *
17  * The Original Software is NetBeans. The Initial Developer of the Original
18  * Software is Sun Microsystems, Inc. Portions Copyright 2000-2001 Sun
19  * Microsystems, Inc. All Rights Reserved.
20  *
21  * Contributor(s): Thomas Ball
22  *
23  * Version: $Revision: 1.5 $
24  */

25
26 package org.netbeans.modules.classfile;
27
28 import java.io.IOException JavaDoc;
29
30 /**
31  * Exception thrown when a classfile with an invalid format is detected.
32  *
33  * @author Thomas Ball
34  */

35 public final class InvalidClassFormatException extends IOException JavaDoc {
36     /**
37      * Constructs an <code>InvalidClassFormatException</code> with
38      * <code>null</code> as its error detail message.
39      */

40     InvalidClassFormatException() {
41     super();
42     }
43
44     /**
45      * Constructs an <code>InvalidClassFormatException</code> with the
46      * specified detail message. The error message string <code>s</code>
47      * can later be retrieved by the
48      * <code>{@link java.lang.Throwable#getMessage}</code>
49      * method of class <code>java.lang.Throwable</code>.
50      *
51      * @param s the detail message.
52      */

53     InvalidClassFormatException(String JavaDoc s) {
54     super(s);
55     }
56
57
58     /**
59      * Constructs an <code>InvalidClassFormatException</code> with the
60      * specified cause, which is used to define the error message.
61      *
62      * @param cause the exception which is used to define the error message.
63      */

64     InvalidClassFormatException(Throwable JavaDoc cause) {
65         super(cause.getLocalizedMessage());
66         initCause(cause);
67     }
68     
69     private static final long serialVersionUID = -7043855006167696889L;
70 }
71
72
Popular Tags