org.objectweb.cjdbc.common.exceptions.driver.protocol
Class BackendDriverException

java.lang.Object
  extended byjava.lang.Throwable
      extended byjava.lang.Exception
          extended byorg.objectweb.cjdbc.common.exceptions.driver.protocol.SerializableException
              extended byorg.objectweb.cjdbc.common.exceptions.driver.protocol.BackendDriverException
All Implemented Interfaces:
java.io.Serializable

public class BackendDriverException
extends SerializableException

This class is an SQLException (typically from backend) made serializable.

Version:
1.0
Author:
Marc Herbert
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.objectweb.cjdbc.common.exceptions.driver.protocol.SerializableException
 
Fields inherited from class java.lang.Exception
 
Fields inherited from class java.lang.Throwable
 
Constructor Summary
BackendDriverException(CJDBCInputStream in)
           
BackendDriverException(java.lang.Throwable start)
          Converts a chain of Throwables to a new chain of SerializableException starting with a BackendDriverException.
 
Method Summary
private static SerializableException convertNext(java.lang.Throwable regularEx)
          Get the first cause found (new or old style), and convert it to a new BackendDriverException object (which is Serializable)
 
Methods inherited from class org.objectweb.cjdbc.common.exceptions.driver.protocol.SerializableException
convertStackTrace, fillInStackTrace, getErrorCode, getSerializableStackTrace, getSQLState, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, sendToStream, setErrorCode, setSQLState, setStackTrace
 
Methods inherited from class java.lang.Throwable
getCause, getLocalizedMessage, getMessage, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BackendDriverException

public BackendDriverException(CJDBCInputStream in)
                       throws java.io.IOException
See Also:
SerializableException.SerializableException(CJDBCInputStream)

BackendDriverException

public BackendDriverException(java.lang.Throwable start)
Converts a chain of Throwables to a new chain of SerializableException starting with a BackendDriverException. The returned chain has the same length. We don't use super's method but re-implement it since we want to also convert SQLException old-style chaining into a new style chain. "SyntheticSQLException-s" from SQLExceptionFactory also currently use old style chaining (with setNextException).

Parameters:
start - head of chain to convert.
See Also:
SerializableException.SerializableException(Throwable)
Method Detail

convertNext

private static SerializableException convertNext(java.lang.Throwable regularEx)
Get the first cause found (new or old style), and convert it to a new BackendDriverException object (which is Serializable)



Copyright © 2002, 2005 - ObjectWeb Consortium - All Rights Reserved.