|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.derby.impl.jdbc.Util
This class understands the message protocol and looks up SQLExceptions based on keys, so that the Local JDBC driver's messages can be localized. REMIND: May want to investigate putting some of this in the protocol side, for the errors that any Cloudscape JDBC driver might return. The ASSERT mechanism is a wrapper of the basic services, to ensure that failed asserts at this level will behave well in a JDBC environment.
Constructor Summary | |
Util()
|
Method Summary | |
static void |
ASSERT(EmbedConnection conn,
boolean mustBeTrue,
java.lang.String msg)
Mimic SanityManager.ASSERT in a JDBC-friendly way, and providing system cleanup for JDBC failures. |
static java.sql.SQLException |
generateCsSQLException(StandardException se)
|
static java.sql.SQLException |
generateCsSQLException(java.lang.String error)
|
static java.sql.SQLException |
generateCsSQLException(java.lang.String error,
java.lang.Object arg1)
|
static java.sql.SQLException |
generateCsSQLException(java.lang.String error,
java.lang.Object arg1,
java.lang.Object arg2)
|
static java.sql.SQLException |
generateCsSQLException(java.lang.String error,
java.lang.Object arg1,
java.lang.Object arg2,
java.lang.Object arg3)
|
(package private) static java.sql.SQLException |
generateCsSQLException(java.lang.String error,
java.lang.Object arg1,
java.lang.Throwable t)
|
static java.sql.SQLException |
javaException(java.lang.Throwable t)
|
private static java.sql.SQLException |
newEmbedSQLException(java.lang.String messageId,
int severity)
|
static java.sql.SQLException |
newEmbedSQLException(java.lang.String messageId,
java.lang.Object[] args,
int severity)
|
private static java.sql.SQLException |
newEmbedSQLException(java.lang.String messageId,
java.lang.Object[] args,
int severity,
java.lang.Throwable t)
|
private static java.sql.SQLException |
newEmbedSQLException(java.lang.String messageId,
java.lang.Object[] args,
java.sql.SQLException next,
int severity,
java.lang.Throwable t)
This looks up the message and sqlstate values and generates the appropriate exception off of them. |
(package private) static java.sql.SQLException |
newException(java.lang.String messageID,
java.lang.Object a1,
java.lang.Object a2,
java.lang.Object a3)
|
static java.sql.SQLException |
noCurrentConnection()
|
static java.sql.SQLException |
notImplemented()
|
static java.sql.SQLException |
notImplemented(java.lang.String feature)
|
(package private) static java.sql.SQLException |
setStreamFailure(java.io.IOException e)
|
(package private) static void |
THROWASSERT(EmbedConnection conn,
java.lang.String msg)
Mimic SanityManager.THROWASSERT in a JDBC-friendly way, and providing system cleanup for JDBC failures. |
(package private) static java.sql.SQLException |
typeMisMatch(int targetSQLType)
|
static java.lang.String |
typeName(int jdbcType)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Util()
Method Detail |
private static java.sql.SQLException newEmbedSQLException(java.lang.String messageId, java.lang.Object[] args, java.sql.SQLException next, int severity, java.lang.Throwable t)
public static java.sql.SQLException newEmbedSQLException(java.lang.String messageId, java.lang.Object[] args, int severity)
private static java.sql.SQLException newEmbedSQLException(java.lang.String messageId, java.lang.Object[] args, int severity, java.lang.Throwable t)
private static java.sql.SQLException newEmbedSQLException(java.lang.String messageId, int severity)
public static void ASSERT(EmbedConnection conn, boolean mustBeTrue, java.lang.String msg) throws java.sql.SQLException
java.sql.SQLException
- the exceptionstatic void THROWASSERT(EmbedConnection conn, java.lang.String msg) throws java.sql.SQLException
java.sql.SQLException
static java.sql.SQLException newException(java.lang.String messageID, java.lang.Object a1, java.lang.Object a2, java.lang.Object a3)
public static java.sql.SQLException generateCsSQLException(java.lang.String error)
public static java.sql.SQLException generateCsSQLException(java.lang.String error, java.lang.Object arg1)
public static java.sql.SQLException generateCsSQLException(java.lang.String error, java.lang.Object arg1, java.lang.Object arg2)
public static java.sql.SQLException generateCsSQLException(java.lang.String error, java.lang.Object arg1, java.lang.Object arg2, java.lang.Object arg3)
static java.sql.SQLException generateCsSQLException(java.lang.String error, java.lang.Object arg1, java.lang.Throwable t)
public static java.sql.SQLException generateCsSQLException(StandardException se)
public static java.sql.SQLException noCurrentConnection()
public static java.sql.SQLException javaException(java.lang.Throwable t)
public static java.sql.SQLException notImplemented()
public static java.sql.SQLException notImplemented(java.lang.String feature)
static java.sql.SQLException setStreamFailure(java.io.IOException e)
static java.sql.SQLException typeMisMatch(int targetSQLType)
public static java.lang.String typeName(int jdbcType)
|
Built on Mon 2007-06-04 09:58:47+0400, from revision ??? | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |