public class PassThroughFilterChain
extends java.lang.Object
javax.servlet.FilterConfig
interface which
simply passes the call through to a given Filter/FilterChain combination
(indicating the next Filter in the chain along with the FilterChain that it is
supposed to work on) or to a given Servlet (indicating the end of the chain).javax.servlet.Filter
,
javax.servlet.Servlet
,
MockFilterChain
Modifier and Type | Field and Description |
---|---|
private Filter |
filter |
private FilterChain |
nextFilterChain |
private Servlet |
servlet |
Constructor and Description |
---|
PassThroughFilterChain(Filter filter,
FilterChain nextFilterChain)
Create a new PassThroughFilterChain that delegates to the given Filter,
calling it with the given FilterChain.
|
PassThroughFilterChain(Servlet servlet)
Create a new PassThroughFilterChain that delegates to the given Servlet.
|
Modifier and Type | Method and Description |
---|---|
void |
doFilter(ServletRequest request,
ServletResponse response)
Pass the call on to the Filter/Servlet.
|
private Filter filter
private FilterChain nextFilterChain
private Servlet servlet
public PassThroughFilterChain(Filter filter, FilterChain nextFilterChain)
filter
- the Filter to delegate tonextFilterChain
- the FilterChain to use for that next Filterpublic PassThroughFilterChain(Servlet servlet)
servlet
- the Servlet to delegate to