org.granite.tide.data
Class PersistenceExceptionConverter

java.lang.Object
  extended by org.granite.tide.data.PersistenceExceptionConverter
All Implemented Interfaces:
ExceptionConverter

public class PersistenceExceptionConverter
extends Object
implements ExceptionConverter


Field Summary
static String ENTITY_EXISTS
           
static String ENTITY_NOT_FOUND
           
static String NO_RESULT
           
static String NON_UNIQUE_RESULT
           
static String OPTIMISTIC_LOCK
           
static String OTHER
           
static String ROLLBACK
           
static String TRANSACTION_REQUIRED
           
 
Constructor Summary
PersistenceExceptionConverter()
           
 
Method Summary
 boolean accepts(Throwable t, Throwable finalException)
           
 ServiceException convert(Throwable t, String detail, Map<String,Object> extendedData)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ENTITY_EXISTS

public static final String ENTITY_EXISTS
See Also:
Constant Field Values

ENTITY_NOT_FOUND

public static final String ENTITY_NOT_FOUND
See Also:
Constant Field Values

NON_UNIQUE_RESULT

public static final String NON_UNIQUE_RESULT
See Also:
Constant Field Values

NO_RESULT

public static final String NO_RESULT
See Also:
Constant Field Values

OPTIMISTIC_LOCK

public static final String OPTIMISTIC_LOCK
See Also:
Constant Field Values

TRANSACTION_REQUIRED

public static final String TRANSACTION_REQUIRED
See Also:
Constant Field Values

ROLLBACK

public static final String ROLLBACK
See Also:
Constant Field Values

OTHER

public static final String OTHER
See Also:
Constant Field Values
Constructor Detail

PersistenceExceptionConverter

public PersistenceExceptionConverter()
Method Detail

accepts

public boolean accepts(Throwable t,
                       Throwable finalException)
Specified by:
accepts in interface ExceptionConverter

convert

public ServiceException convert(Throwable t,
                                String detail,
                                Map<String,Object> extendedData)
Specified by:
convert in interface ExceptionConverter