Spring的异常处理采用的是未检查异常(unchecked exception),因此 开发人员可以自己决定是否须要捕获异常。MongoDB的模板的实现方式是把捕获到的底层的异常封装成未检查异常, 这些异常都是...
基于74个网页-相关网页
未检查异常作为运行时exception类是理想的异常侯选处理不可恢复性出错,如资源不可用或者空指针。
Unchecked exceptions which are descendents of RuntimeException class are the ideal candidate exceptions handle non-recoverable errors such as resource non-availability or some null Pointers.
您不必在这个级别上处理异常,因为 Spring 将它们转换为一套通用的未检查异常(unchecked exceptions)。
You don't have to handle exceptions at this level because Spring translates them to a common set of unchecked exceptions.
使用引入(Introduction),Aspect可以向类中添加新的方法和变量、声明一个类实现一个接口或将检查异常转换为未检查异常(unchecked exception)。
Using introduction, aspects can add new methods and variables to a class, declare that a class implements an interface, or convert checked to unchecked exceptions.
应用推荐