Debian Codegraph @

src/jakarta/json/JsonException.java

raw symbols SCIP
1 /*
2 * Copyright (c) 2011, 2021 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.json;
18
19 /**
20 * <code>JsonException</code> indicates that some exception happened during
21 * JSON processing.
22 */
23 public class JsonException extends RuntimeException {
24
25 /** for serialization */
26 private static final long serialVersionUID = 359810709545392112L;
27
28 /**
29 * Constructs a new runtime exception with the specified detail message.
30 * The cause is not initialized, and may subsequently be initialized by a
31 * call to {@link #initCause}.
32 *
33 * @param message the detail message. The detail message is saved for
34 * later retrieval by the {@link #getMessage()} method.
35 */
36 public JsonException(String message) {
37 super(message);
38 }
39
40 /**
41 * Constructs a new runtime exception with the specified detail message and
42 * cause. <p>Note that the detail message associated with
43 * {@code cause} is <i>not</i> automatically incorporated in
44 * this runtime exception's detail message.
45 *
46 * @param message the detail message (which is saved for later retrieval
47 * by the {@link #getMessage()} method).
48 * @param cause the cause (which is saved for later retrieval by the
49 * {@link #getCause()} method). (A <code>null</code> value is
50 * permitted, and indicates that the cause is nonexistent or
51 * unknown.)
52 */
53 public JsonException(String message, Throwable cause) {
54 super(message, cause);
55 }
56
57 }
58