@Test public void testCacheControlMustRevalidate() throws Exception { final HandlerMethod handler = new HandlerMethod( controller, controller.getClass().getMethod("handlePubliclyCachedPageAndRevalidatedRequest")); interceptor.preHandle(request, response, handler); System.err.println("CC: " + response.getHeader("Cache-Control")); assertNotNull(response.getHeader("Cache-Control")); assertTrue(response.getHeader("Cache-Control").contains("must-revalidate")); assertFalse(response.getHeader("Cache-Control").contains("private")); }
@Override public final boolean preHandle( final HttpServletRequest request, final HttpServletResponse response, final Object handler) throws Exception { this.assignCacheControlHeader(request, response, handler); return super.preHandle(request, response, handler); }
CacheControlHandlerInterceptor extends HandlerInterceptorAdapter implements HandlerInterceptor { @Override public final boolean preHandle( final HttpServletRequest request, final HttpServletResponse response, final Object handler) throws Exception { this.assignCacheControlHeader(request, response, handler); return super.preHandle(request, response, handler); } }
CacheControlHandlerInterceptor extends HandlerInterceptorAdapter implements HandlerInterceptor { @Override public final boolean preHandle( final HttpServletRequest request, final HttpServletResponse response, final Object handler) throws Exception { this.assignCacheControlHeader(request, response, handler); return super.preHandle(request, response, handler); } CacheControlHandlerInterceptor(); }
CacheControlHandlerInterceptor extends HandlerInterceptorAdapter implements HandlerInterceptor { @Override public final boolean preHandle( final HttpServletRequest request, final HttpServletResponse response, final Object handler) throws Exception { this.assignCacheControlHeader(request, response, handler); return super.preHandle(request, response, handler); } CacheControlHandlerInterceptor(); @Override final boolean preHandle(
			final HttpServletRequest request,
			final HttpServletResponse response, 
			final Object handler); final void setUseExpiresHeader(final boolean useExpiresHeader); }
CacheControlHandlerInterceptor extends HandlerInterceptorAdapter implements HandlerInterceptor { @Override public final boolean preHandle( final HttpServletRequest request, final HttpServletResponse response, final Object handler) throws Exception { this.assignCacheControlHeader(request, response, handler); return super.preHandle(request, response, handler); } CacheControlHandlerInterceptor(); @Override final boolean preHandle(
			final HttpServletRequest request,
			final HttpServletResponse response, 
			final Object handler); final void setUseExpiresHeader(final boolean useExpiresHeader);  }