1. 程式人生 > >Servlet封裝類

Servlet封裝類

Servlet 提供了四個封裝類:

public class ServletRequestWrapper extends java.lang.Object implements ServletRequest  // 
public class ServletResponseWrapper extends java.lang.Object implements ServletResponse  // 
public class HttpServletRequestWrapper extends ServletRequestWrapper implements HttpServletRequest  //
public class HttpServletResponseWrapper extends ServletResponseWrapper implements HttpServletResponse //

直接擴充套件這些封裝類就可以修飾相應的的 request 和 response 物件了。