org.springframework.data.redis
Class FallbackExceptionTranslationStrategy

java.lang.Object
  extended by org.springframework.data.redis.PassThroughExceptionTranslationStrategy
      extended by org.springframework.data.redis.FallbackExceptionTranslationStrategy
All Implemented Interfaces:
ExceptionTranslationStrategy

public class FallbackExceptionTranslationStrategy
extends PassThroughExceptionTranslationStrategy

FallbackExceptionTranslationStrategy returns RedisSystemException for unknown Exceptions.

Since:
1.4

Constructor Summary
FallbackExceptionTranslationStrategy(Converter<Exception,DataAccessException> converter)
           
 
Method Summary
protected  RedisSystemException getFallback(Exception e)
          Returns a new RedisSystemException wrapping the given Exception.
 DataAccessException translate(Exception e)
          Potentially translate the given Exception into DataAccessException.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FallbackExceptionTranslationStrategy

public FallbackExceptionTranslationStrategy(Converter<Exception,DataAccessException> converter)
Method Detail

translate

public DataAccessException translate(Exception e)
Description copied from interface: ExceptionTranslationStrategy
Potentially translate the given Exception into DataAccessException.

Specified by:
translate in interface ExceptionTranslationStrategy
Overrides:
translate in class PassThroughExceptionTranslationStrategy
Returns:

getFallback

protected RedisSystemException getFallback(Exception e)
Returns a new RedisSystemException wrapping the given Exception.

Parameters:
e -
Returns: