/** * Display the request header. */ private static void outputHeaders(FileWriter fw, LoggingHttpServletRequestWrapper req) throws IOException { // Get the header Enumeration reqHeaderNum = req.getHeaderNames(); // Do nothing if there is no header if (reqHeaderNum == null) { fw.write("No headers" + "\n"); return; } // Repeat the header element while (reqHeaderNum.hasMoreElements()) { // Get the key String key = (String) reqHeaderNum.nextElement(); // Output the header information outputHeaderElements(fw, req, key); } }
/** * Display the request header. */ private static void outputHeaders(FileWriter fw, LoggingHttpServletRequestWrapper req) throws IOException { // Get the header Enumeration reqHeaderNum = req.getHeaderNames(); // Do nothing if there is no header if (reqHeaderNum == null) { fw.write("No headers" + "\n"); return; } // Repeat the header element while (reqHeaderNum.hasMoreElements()) { // Get the key String key = (String) reqHeaderNum.nextElement(); // Output the header information outputHeaderElements(fw, req, key); } }