Package cn.sinozg.applet.common.filter
Class WrapperFilter
java.lang.Object
cn.sinozg.applet.common.filter.WrapperFilter
- All Implemented Interfaces:
jakarta.servlet.Filter
包装http 请求 过滤器
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate cn.sinozg.applet.common.properties.AppValue是否启用防重复private cn.sinozg.applet.common.service.CipherServiceprivate final org.slf4j.Logger -
Constructor Summary
ConstructorsConstructorDescriptionWrapperFilter(cn.sinozg.applet.common.properties.AppValue app, cn.sinozg.applet.common.service.CipherService cipherService) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface jakarta.servlet.Filter
destroy, init
-
Field Details
-
app
private cn.sinozg.applet.common.properties.AppValue app是否启用防重复 -
cipherService
private cn.sinozg.applet.common.service.CipherService cipherService -
log
private final org.slf4j.Logger log
-
-
Constructor Details
-
WrapperFilter
public WrapperFilter() -
WrapperFilter
public WrapperFilter(cn.sinozg.applet.common.properties.AppValue app, cn.sinozg.applet.common.service.CipherService cipherService)
-
-
Method Details
-
doFilter
public void doFilter(jakarta.servlet.ServletRequest request, jakarta.servlet.ServletResponse response, jakarta.servlet.FilterChain chain) throws IOException, jakarta.servlet.ServletException - Specified by:
doFilterin interfacejakarta.servlet.Filter- Throws:
IOExceptionjakarta.servlet.ServletException
-
isWrapper
private boolean isWrapper(jakarta.servlet.http.HttpServletRequest request) 判断请求是否需要包装- Parameters:
request- request- Returns:
- 是否需要包装
-