/** * Decides if this interceptor should invalidate the session or mark the session * to be invalidated upon the next request that contains this interceptor in the stack. * * @see com.opensymphony.xwork.interceptor.AroundInterceptor#after(com.opensymphony.xwork.ActionInvocation, java.lang.String) */ protected void after(ActionInvocation invocation, String result) throws Exception { SessionMap sessionMap = (SessionMap) invocation.getInvocationContext().get(ActionContext.SESSION); if (NOW.equalsIgnoreCase(type)) { if (LOG.isDebugEnabled()) LOG.debug("type=now, invalidating session now"); sessionMap.invalidate(); LOG.info("session invalidated"); } else if (NEXT_REQUEST.equalsIgnoreCase(type)) { if (LOG.isDebugEnabled()) LOG.debug("type=NextRequest, mark key in session, such that next request that have this interceptor will invalidate the session"); sessionMap.put(key, "true"); } else if (NO_OPERATION.equalsIgnoreCase(type)) { if (LOG.isDebugEnabled()) LOG.debug("no operation"); } else { LOG.warn("unrecognized type, type should be either "+NOW+", "+NEXT_REQUEST+" or "+NO_OPERATION); } }