Debian Codegraph @

src/main/org/h2/jdbc/JdbcException.java

raw
1 /*
2 * Copyright 2004-2023 H2 Group. Multiple-Licensed under the MPL 2.0,
3 * and the EPL 1.0 (https://h2database.com/html/license.html).
4 * Initial Developer: H2 Group
5 */
6 package org.h2.jdbc;
7
8 /**
9 * This interface contains additional methods for database exceptions.
10 */
11 public interface JdbcException {
12
13 /**
14 * Returns the H2-specific error code.
15 *
16 * @return the H2-specific error code
17 */
18 public int getErrorCode();
19
20 /**
21 * INTERNAL
22 * @return original message
23 */
24 String getOriginalMessage();
25
26 /**
27 * Returns the SQL statement.
28 * <p>
29 * SQL statements that contain '--hide--' are not listed.
30 * </p>
31 *
32 * @return the SQL statement
33 */
34 String getSQL();
35
36 /**
37 * INTERNAL
38 * @param sql to set
39 */
40 void setSQL(String sql);
41
42 /**
43 * Returns the class name, the message, and in the server mode, the stack
44 * trace of the server
45 *
46 * @return the string representation
47 */
48 @Override
49 String toString();
50
51 }