org.springframework.data.mongodb.core
Class MongoExceptionTranslator
java.lang.Object
org.springframework.data.mongodb.core.MongoExceptionTranslator
- All Implemented Interfaces:
- PersistenceExceptionTranslator
public class MongoExceptionTranslator
- extends Object
- implements PersistenceExceptionTranslator
Simple PersistenceExceptionTranslator
for Mongo. Convert the given runtime exception to an appropriate
exception from the org.springframework.dao
hierarchy. Return null if no translation is
appropriate: any other exception may have resulted from user code, and should not be translated.
- Author:
- Oliver Gierke
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MongoExceptionTranslator
public MongoExceptionTranslator()
translateExceptionIfPossible
public DataAccessException translateExceptionIfPossible(RuntimeException ex)
- Specified by:
translateExceptionIfPossible
in interface PersistenceExceptionTranslator
Copyright © 2012. All Rights Reserved.