KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > java > security > spec > InvalidKeySpecException


1 /*
2  * @(#)InvalidKeySpecException.java 1.16 03/12/19
3  *
4  * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
5  * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
6  */

7
8 package java.security.spec;
9
10 import java.security.GeneralSecurityException JavaDoc;
11
12 /**
13  * This is the exception for invalid key specifications.
14  *
15  * @author Jan Luehe
16  *
17  * @version 1.16, 12/19/03
18  *
19  * @see KeySpec
20  *
21  * @since 1.2
22  */

23
24 public class InvalidKeySpecException extends GeneralSecurityException JavaDoc {
25
26     private static final long serialVersionUID = 3546139293998810778L;
27
28     /**
29      * Constructs an InvalidKeySpecException with no detail message. A
30      * detail message is a String that describes this particular
31      * exception.
32      */

33     public InvalidKeySpecException() {
34     super();
35     }
36
37     /**
38      * Constructs an InvalidKeySpecException with the specified detail
39      * message. A detail message is a String that describes this
40      * particular exception.
41      *
42      * @param msg the detail message.
43      */

44     public InvalidKeySpecException(String JavaDoc msg) {
45     super(msg);
46     }
47
48     /**
49      * Creates a <code>InvalidKeySpecException</code> with the specified
50      * detail message and cause.
51      *
52      * @param message the detail message (which is saved for later retrieval
53      * by the {@link #getMessage()} method).
54      * @param cause the cause (which is saved for later retrieval by the
55      * {@link #getCause()} method). (A <tt>null</tt> value is permitted,
56      * and indicates that the cause is nonexistent or unknown.)
57      * @since 1.5
58      */

59     public InvalidKeySpecException(String JavaDoc message, Throwable JavaDoc cause) {
60         super(message, cause);
61     }
62
63     /**
64      * Creates a <code>InvalidKeySpecException</code> with the specified cause
65      * and a detail message of <tt>(cause==null ? null : cause.toString())</tt>
66      * (which typically contains the class and detail message of
67      * <tt>cause</tt>).
68      *
69      * @param cause the cause (which is saved for later retrieval by the
70      * {@link #getCause()} method). (A <tt>null</tt> value is permitted,
71      * and indicates that the cause is nonexistent or unknown.)
72      * @since 1.5
73      */

74     public InvalidKeySpecException(Throwable JavaDoc cause) {
75         super(cause);
76     }
77 }
78
Popular Tags