public class GDSException
extends java.lang.Exception
Constructor and Description |
---|
GDSException(int fbErrorCode)
Create a new instance.
|
GDSException(int type,
int intParam)
Create a new instance.
|
GDSException(int type,
int fbErrorCode,
java.lang.String strParam)
Construct instance of this class.
|
GDSException(int type,
int fbErrorCode,
java.lang.String strParam,
java.lang.Throwable cause)
Construct instance of this class.
|
GDSException(int type,
java.lang.String strParam)
Create a new instance.
|
GDSException(int fbErrorCode,
java.lang.Throwable cause)
Create a new instance.
|
GDSException(java.lang.String message)
Create a new instance with only a simple message.
|
Modifier and Type | Method and Description |
---|---|
static GDSException |
createWithXAErrorCode(java.lang.String message,
int xaErrorCode)
Factory method to create a new instance with a given
XA
error code. |
int |
getFbErrorCode()
Get the Firebird-specific error code for this exception.
|
int |
getIntParam()
Get the
int parameter for this exception. |
java.lang.String |
getMessage()
Returns a string representation of this exception.
|
GDSException |
getNext()
Get the next chained exception.
|
java.lang.String |
getParam()
Returns the parameter depending on the type of the error code.
|
java.lang.String |
getSQLState()
Get the SQL state of this exception.
|
int |
getXAErrorCode()
Get the XaErrorCode value.
|
boolean |
isWarning()
Retrieve whether this exception is a warning.
|
void |
setNext(GDSException e)
Set the next exception in the chain.
|
void |
setXAErrorCode(int xaErrorCode)
Set the XaErrorCode value.
|
public GDSException(int type, int intParam)
type
- type of the exception, should be always
ISCConstants.isc_arg_gds
, otherwise no message will be
displayed.intParam
- Additional int parameter about the new exceptionpublic GDSException(int type, java.lang.String strParam)
type
- type of the exception, should be always
ISCConstants.isc_arg_gds
, otherwise no message will be
displayed.strParam
- value of the string parameter that will substitute
{0}
entry in error message corresponding to the
specified error code.public GDSException(int type, int fbErrorCode, java.lang.String strParam)
type
- type of the exception, should be always
ISCConstants.isc_arg_gds
, otherwise no message will be displayed.fbErrorCode
- Firebird error code, one of the constants declared
in GDS
interface.strParam
- value of the string parameter that will substitute
{0}
entry in error message corresponding to the specified
error code.public GDSException(int type, int fbErrorCode, java.lang.String strParam, java.lang.Throwable cause)
type
- type of the exception, should be always
ISCConstants.isc_arg_gds
, otherwise no message will be displayed.fbErrorCode
- Firebird error code, one of the constants declared
in GDS
interface.strParam
- value of the string parameter that will substitute
{0}
entry in error message corresponding to the specified
error code.cause
- Cause of this exceptionpublic GDSException(int fbErrorCode)
fbErrorCode
- Firebird error code, one of the constants declared
in GDS
interfacepublic GDSException(int fbErrorCode, java.lang.Throwable cause)
fbErrorCode
- Firebird error code, one of the constants declared
in GDS
interfacecause
- Cause of this exceptionpublic GDSException(java.lang.String message)
message
- Message for the new exceptionpublic static GDSException createWithXAErrorCode(java.lang.String message, int xaErrorCode)
XA
error code.message
- Message for the new instancexaErrorCode
- The XA
error codepublic int getFbErrorCode()
public java.lang.String getSQLState()
null
if this
object does not represent an error.public int getIntParam()
int
parameter for this exception.int
parameterpublic int getXAErrorCode()
public void setXAErrorCode(int xaErrorCode)
xaErrorCode
- The new XaErrorCode value.public void setNext(GDSException e)
e
- The next chained exceptionpublic GDSException getNext()
public boolean isWarning()
true
if this is a warning,
false
otherwisepublic java.lang.String getMessage()
getMessage
in class java.lang.Throwable
public java.lang.String getParam()
Copyright © 2001-2019 Jaybird (Firebird JDBC/JCA) team. All rights reserved.