Skip to content

Package: SecurityException

SecurityException

nameinstructionbranchcomplexitylinemethod
SecurityException()
M: 3 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
SecurityException(String)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
SecurityException(String, String)
M: 5 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
SecurityException(String, Throwable)
M: 5 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%
SecurityException(Throwable)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 2 C: 0
0%
M: 1 C: 0
0%

Coverage

1: /*
2: * Copyright (c) 1997, 2020 Oracle and/or its affiliates. All rights reserved.
3: *
4: * This program and the accompanying materials are made available under the
5: * terms of the Eclipse Public License v. 2.0, which is available at
6: * http://www.eclipse.org/legal/epl-2.0.
7: *
8: * This Source Code may also be made available under the following Secondary
9: * Licenses when the conditions for such availability set forth in the
10: * Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
11: * version 2 with the GNU Classpath Exception, which is available at
12: * https://www.gnu.org/software/classpath/license.html.
13: *
14: * SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
15: */
16:
17: package jakarta.resource.spi;
18:
19: /**
20: * A <code>SecurityException</code> indicates error conditions
21: * related to the security
22: * contract between an application server and resource adapter. The common
23: * error conditions represented by this exception are:
24: * <UL>
25: * <LI>Invalid security information (represented as a Subject instance) passed
26: * across the security contract - for example, credentials have expired or
27: * have invalid format.
28: * <LI>Lack of support for a specific security mechanism in an EIS or resource
29: * adapter.
30: * <LI>Failure to create a connection to an EIS because of failed
31: * authentication or authorization.
32: * <LI>Failure to authenticate a resource principal to an EIS instance
33: * or failure
34: * to establish a secure association with an underlying EIS instance.
35: * <LI>Access control exception to indicate that a requested access to an EIS
36: * resource or a request to create a new connection is denied.
37: * </UL>
38: *
39: * @version 1.0
40: * @author Rahul Sharma
41: * @author Ram Jeyaraman
42: */
43:
44: public class SecurityException extends jakarta.resource.ResourceException {
45:
46: /**
47: * Constructs a new instance with null as its detail message.
48: */
49: public SecurityException() { super(); }
50:
51: /**
52: * Constructs a new instance with the specified detail message.
53: *
54: * @param message the detail message.
55: */
56: public SecurityException(String message) {
57:         super(message);
58: }
59:
60: /**
61: * Constructs a new throwable with the specified cause.
62: *
63: * @param cause a chained exception of type <code>Throwable</code>.
64: */
65: public SecurityException(Throwable cause) {
66:         super(cause);
67: }
68:
69: /**
70: * Constructs a new throwable with the specified detail message and cause.
71: *
72: * @param message the detail message.
73: *
74: * @param cause a chained exception of type <code>Throwable</code>.
75: */
76: public SecurityException(String message, Throwable cause) {
77:         super(message, cause);
78: }
79:
80: /**
81: * Constructs a new throwable with the specified detail message and
82: * an error code.
83: *
84: * @param message a description of the exception.
85: * @param errorCode a string specifying the vendor specific error code.
86: */
87: public SecurityException(String message, String errorCode) {
88:         super(message, errorCode);
89: }
90: }