net.sourceforge.orbroker.exception
Interface ExceptionEvaluator

All Known Implementing Classes:
DefaultExceptionEvaluator

public interface ExceptionEvaluator

Interface to interrogate an SQLException.

Author:
Nils Kilden-Pedersen
See Also:
Broker.setExceptionEvaluator(ExceptionEvaluator)

Method Summary
 boolean isConstraint(SQLException source)
          Is SQLException a constraint violation?
 boolean isDeadlock(SQLException source)
          Is SQLException a deadlock?
 boolean isStaleConnection(SQLException source)
          Is SQLException caused by stale connection?
 

Method Detail

isConstraint

public boolean isConstraint(SQLException source)
Is SQLException a constraint violation?

Parameters:
source - Exception source
Returns:
true, if SQLException is caused by a database constraint.

isDeadlock

public boolean isDeadlock(SQLException source)
Is SQLException a deadlock?

Parameters:
source - Exception source
Returns:
true, if SQLException is caused by a dead lock.

isStaleConnection

public boolean isStaleConnection(SQLException source)
Is SQLException caused by stale connection?

Parameters:
source - Exception source
Returns:
true, if SQLException is caused by a stale connection.