FileDocCategorySizeDatePackage
RequestDisplay.javaAPI DocExample814Fri Feb 13 07:43:42 GMT 2004com.jspservletcookbook

RequestDisplay

public class RequestDisplay extends HttpServlet

Fields Summary
Constructors Summary
Methods Summary
public voiddoGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)

    
   ContextObject obj = (ContextObject) request.getAttribute("com.jspservletcookbook.RequestObject");
    //display the attribute's Map keys
      response.setContentType("text/html");
      java.io.PrintWriter out = response.getWriter();
      out.println("<html><head><title>Request Attribute</title></head><body>");
      out.println("<h2>Request attribute values</h2>");
      if (obj != null)
      out.println( obj.getValues() );
      out.println("</body></html>");