Package com.semanticcms.core.servlet
Class CacheFilter
- java.lang.Object
-
- com.semanticcms.core.servlet.CacheFilter
-
- All Implemented Interfaces:
Filter
public class CacheFilter extends Object implements Filter
Resolves the cache to use for the current request.- See Also:
ConcurrencyCoordinator
-
-
Constructor Summary
Constructors Constructor Description CacheFilter()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
destroy()
void
doFilter(ServletRequest request, ServletResponse response, FilterChain chain)
static Cache
getCache(ServletRequest request)
Gets the cache to use for the current request.void
init(FilterConfig config)
-
-
-
Method Detail
-
getCache
public static Cache getCache(ServletRequest request) throws IllegalStateException
Gets the cache to use for the current request. All uses of this cache must synchronize on the map itself.- Throws:
IllegalStateException
- if the filter is not active on the current request
-
init
public void init(FilterConfig config) throws ServletException
- Specified by:
init
in interfaceFilter
- Throws:
ServletException
-
doFilter
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException
- Specified by:
doFilter
in interfaceFilter
- Throws:
IOException
ServletException
-
-