public final class ExceptionFactory
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private MariaDbConnection |
connection |
static ExceptionFactory |
INSTANCE |
private Options |
options |
private java.sql.Statement |
statement |
private long |
threadId |
Modifier | Constructor and Description |
---|---|
private |
ExceptionFactory(long threadId,
Options options) |
|
ExceptionFactory(long threadId,
Options options,
MariaDbConnection connection,
java.sql.Statement statement) |
Modifier and Type | Method and Description |
---|---|
private static java.lang.String |
buildMsgText(java.lang.String initialMessage,
long threadId,
Options options,
java.lang.Exception cause) |
java.sql.SQLException |
create(java.sql.SQLException cause) |
java.sql.SQLException |
create(java.lang.String message) |
java.sql.SQLException |
create(java.lang.String message,
java.lang.Exception cause) |
java.sql.SQLException |
create(java.lang.String message,
java.lang.String sqlState) |
java.sql.SQLException |
create(java.lang.String message,
java.lang.String sqlState,
java.lang.Exception cause) |
java.sql.SQLException |
create(java.lang.String message,
java.lang.String sqlState,
int errorCode) |
java.sql.SQLException |
create(java.lang.String message,
java.lang.String sqlState,
int errorCode,
java.lang.Exception cause) |
private static java.sql.SQLException |
createException(java.lang.String initialMessage,
java.lang.String sqlState,
int errorCode,
long threadId,
Options options,
MariaDbConnection connection,
java.sql.Statement statement,
java.lang.Exception cause) |
Options |
getOptions() |
long |
getThreadId() |
java.sql.SQLException |
notSupported(java.lang.String message) |
static ExceptionFactory |
of(long threadId,
Options options) |
ExceptionFactory |
raiseStatementError(MariaDbConnection connection,
java.sql.Statement stmt) |
java.lang.String |
toString() |
public static final ExceptionFactory INSTANCE
private final long threadId
private final Options options
private MariaDbConnection connection
private java.sql.Statement statement
public ExceptionFactory(long threadId, Options options, MariaDbConnection connection, java.sql.Statement statement)
private ExceptionFactory(long threadId, Options options)
public static ExceptionFactory of(long threadId, Options options)
private static java.sql.SQLException createException(java.lang.String initialMessage, java.lang.String sqlState, int errorCode, long threadId, Options options, MariaDbConnection connection, java.sql.Statement statement, java.lang.Exception cause)
private static java.lang.String buildMsgText(java.lang.String initialMessage, long threadId, Options options, java.lang.Exception cause)
public ExceptionFactory raiseStatementError(MariaDbConnection connection, java.sql.Statement stmt)
public java.sql.SQLException create(java.sql.SQLException cause)
public java.sql.SQLException notSupported(java.lang.String message)
public java.sql.SQLException create(java.lang.String message)
public java.sql.SQLException create(java.lang.String message, java.lang.Exception cause)
public java.sql.SQLException create(java.lang.String message, java.lang.String sqlState)
public java.sql.SQLException create(java.lang.String message, java.lang.String sqlState, java.lang.Exception cause)
public java.sql.SQLException create(java.lang.String message, java.lang.String sqlState, int errorCode)
public java.sql.SQLException create(java.lang.String message, java.lang.String sqlState, int errorCode, java.lang.Exception cause)
public long getThreadId()
public Options getOptions()
public java.lang.String toString()
toString
in class java.lang.Object