首页>代码>java servlet Filter的入门实例源代码下载>/使用过滤器优化后代码/demo3/src/com/sxt/JingHuaFilter.java
package com.sxt;


import java.io.IOException;

import javax.servlet.Filter;
import javax.servlet.FilterChain;
import javax.servlet.FilterConfig;
import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;
import javax.servlet.http.HttpServlet;

public class JingHuaFilter extends HttpServlet implements Filter{

	/**
	 * Constructor of the object.
	 */
	public JingHuaFilter() {
		super();
	}

	/**
	 * Destruction of the servlet. <br>
	 */
	public void destroy() {
		super.destroy(); // Just puts "destroy" string in log
		// Put your code here
	}

	/**
	 * Initialization of the servlet. <br>
	 *
	 * @throws ServletException if an error occure
	 */
	public void init() throws ServletException {
		// Put your code here
	}

	public void doFilter(ServletRequest arg0, ServletResponse arg1, FilterChain arg2) throws IOException, ServletException {
		// TODO Auto-generated method stub
		System.out.println("¾»»¯Ë®...");
		arg2.doFilter(arg0, arg1);
		
	}

	public void init(FilterConfig arg0) throws ServletException {
		// TODO Auto-generated method stub
		
	}

}
最近下载更多
王华伟  LV19 2022年6月7日
最代码-宋家辉  LV61 2021年5月14日
Y.z.x  LV1 2021年5月12日
wangdongtai  LV31 2020年6月4日
ly3812  LV17 2020年3月26日
13940562934  LV22 2019年10月17日
gangui  LV1 2019年6月19日
daidin  LV11 2019年1月2日
hdhbshs  LV16 2018年12月24日
三生石sh1  LV13 2018年12月24日
最近浏览更多
微信网友_7290996505972736  LV4 2024年12月11日
Mike-胖 2024年10月9日
暂无贡献等级
ling7314  LV4 2023年11月14日
3040205658 2022年10月21日
暂无贡献等级
王华伟  LV19 2022年6月7日
Air不得01 2022年5月4日
暂无贡献等级
采暖11  LV11 2021年12月24日
level  LV5 2021年6月21日
ewewrfas  LV2 2021年5月25日
最代码-宋家辉  LV61 2021年5月14日
顶部 客服 微信二维码 底部
>扫描二维码关注最代码为好友扫描二维码关注最代码为好友