|
Java Platform 1.2 Beta 4 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.lang.Throwable | +--java.lang.Exception | +--java.sql.SQLException
The SQLException class provides information on a database access error.
Each SQLException provides several kinds of information:
Constructor Summary | |
SQLException()
Construct an SQLException; reason defaults to null, SQLState defaults to null and vendorCode defaults to 0. |
|
SQLException(String reason,
String SQLState,
int vendorCode)
Construct a fully-specified SQLException |
|
SQLException(String reason,
String SQLState)
Construct an SQLException with a reason and SQLState; vendorCode defaults to 0. |
|
SQLException(String reason)
Construct an SQLException with a reason; SQLState defaults to null and vendorCode defaults to 0. |
Method Summary | |
int | getErrorCode()
Get the vendor specific exception code |
SQLException | getNextException()
Get the exception chained to this one. |
String | getSQLState()
Get the SQLState |
void | setNextException(SQLException ex)
Add an SQLException to the end of the chain. |
Methods inherited from class java.lang.Throwable | |
fillInStackTrace , getLocalizedMessage , getMessage , printStackTrace , printStackTrace , printStackTrace , toString |
Methods inherited from class java.lang.Object | |
clone , equals , finalize , getClass , hashCode , notify , notifyAll , wait , wait , wait |
Constructor Detail |
public SQLException(String reason, String SQLState, int vendorCode)
reason
- a description of the exception
SQLState
- an XOPEN code identifying the exception
vendorCode
- a database vendor specific exception codepublic SQLException(String reason, String SQLState)
reason
- a description of the exception
SQLState
- an XOPEN code identifying the exceptionpublic SQLException(String reason)
reason
- a description of the exceptionpublic SQLException()
Method Detail |
public String getSQLState()
public int getErrorCode()
public SQLException getNextException()
public void setNextException(SQLException ex)
ex
- the new end of the SQLException chain
|
Java Platform 1.2 Beta 4 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |