org.riotfamily.common.web.transaction
Class TransactionalHandlerInterceptor
java.lang.Object
org.riotfamily.common.web.transaction.TransactionalHandlerInterceptor
- All Implemented Interfaces:
- HandlerInterceptor
public class TransactionalHandlerInterceptor
- extends Object
- implements HandlerInterceptor
HandlerInterceptor that executes the handler within a transactional context.
- Since:
- 6.5
- Author:
- Felix Gnass [fgnass at neteye dot de]
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TransactionalHandlerInterceptor
public TransactionalHandlerInterceptor(PlatformTransactionManager tm)
setTransactionAttribute
public void setTransactionAttribute(TransactionAttribute transactionAttribute)
- Sets the
TransactionAttribute
. If not set, a
DefaultTransactionAttribute
with
TransactionDefinition.PROPAGATION_REQUIRED
is used.
preHandle
public boolean preHandle(HttpServletRequest request,
HttpServletResponse response,
Object handler)
throws Exception
- Specified by:
preHandle
in interface HandlerInterceptor
- Throws:
Exception
postHandle
public void postHandle(HttpServletRequest request,
HttpServletResponse response,
Object handler,
ModelAndView modelAndView)
throws Exception
- Specified by:
postHandle
in interface HandlerInterceptor
- Throws:
Exception
afterCompletion
public void afterCompletion(HttpServletRequest request,
HttpServletResponse response,
Object handler,
Exception ex)
throws Exception
- Specified by:
afterCompletion
in interface HandlerInterceptor
- Throws:
Exception