|
|||||||||
| Home >> All >> com >> lutris >> http >> [ debug overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
com.lutris.http.debug
Class HttpDebug

java.lang.Objectcom.lutris.http.debug.HttpDebug
- public class HttpDebug
- extends java.lang.Object
This class is used for debugging. It generates html formatted output. It can be used to display http request, http response information. The interfaces DebugRequest and DebugResponse are used to define how this debugging class interacts with the various type of request and response classes including: HttpServletRequest, HttpServletResponse, HttpPresentationRequest, HttpPresentationResponse, HttpRequest, HttpResponse, etc.
- Since:
- LBS1.7
- Version:
- $Revision: 1.27.14.1 $
| Field Summary | |
private static java.lang.String |
BODY_BG_COLOR
|
private static java.lang.String |
FRAME_COLOR
|
private static java.lang.String |
HEADER_BG_COLOR
|
private static java.lang.String |
HEADER_FG_COLOR
|
private static java.lang.String |
HIGHLIGHT_BG_COLOR
|
private static java.lang.String |
SPACE_BG_COLOR
|
| Constructor Summary | |
HttpDebug()
|
|
| Method Summary | |
private static void |
addCookieInformation(com.lutris.html.HtmlTable tbl,
DebugRequest request)
Adds request cookie data rows to a table. |
private static void |
addCookieInformation(com.lutris.html.HtmlTable tbl,
DebugResponse response)
Adds response cookie data rows to a table. |
private static void |
addHeaderInformation(com.lutris.html.HtmlTable tbl,
DebugRequest request)
Adds request headers data rows to a table. |
private static void |
addHeaderInformation(com.lutris.html.HtmlTable tbl,
DebugResponse response)
Adds response headers data rows to a table. |
private static void |
addParameterInformation(com.lutris.html.HtmlTable tbl,
DebugRequest request)
Adds request parameters data rows to a table. |
private static void |
addRequestInformation(com.lutris.html.HtmlTable tbl,
DebugRequest request)
Given a HTML table object, this method extracts all useful information from a httpRequest object and composes a new table row for each datum. |
private static void |
addResponseDataInformation(com.lutris.html.HtmlTable tbl,
DebugResponse response)
Given a HTML table object, this method adds a section for the response data (what was writtent to the output stream). |
private static void |
addResponseInformation(com.lutris.html.HtmlTable tbl,
DebugResponse response)
Given a HTML table object, this method extracts all useful information from a httpResponse object and composes a new table row for each datum. |
private static void |
addTrace(com.lutris.html.HtmlTable tbl,
DebugRequest request)
Adds a dump of the request object trace. |
private static java.lang.String |
capitalize(java.lang.String s)
Capitialize the first letter of a string and any character following a "-" character. |
private static void |
formatCookiesAsHtml(com.lutris.html.HtmlTable tbl,
javax.servlet.http.Cookie[] cookies,
java.lang.String header,
boolean showFields)
Format the cookies as HTML. |
static java.lang.String |
formatSessionInfo(java.lang.String info,
java.lang.String title)
|
static java.lang.String |
formatTraceDebugInfo(java.lang.String trace)
Adds a dump of the response object trace. |
static java.lang.String |
getRequestDebugInfo(DebugRequest request)
Returns HTML containing all the useful information in a HTTP Request. |
static java.lang.String |
getResponseDebugInfo(DebugResponse response)
Returns HTML containing all the useful information in a HTTP Response. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
SPACE_BG_COLOR
private static final java.lang.String SPACE_BG_COLOR
- See Also:
- Constant Field Values
HEADER_BG_COLOR
private static final java.lang.String HEADER_BG_COLOR
- See Also:
- Constant Field Values
BODY_BG_COLOR
private static final java.lang.String BODY_BG_COLOR
- See Also:
- Constant Field Values
HIGHLIGHT_BG_COLOR
private static final java.lang.String HIGHLIGHT_BG_COLOR
- See Also:
- Constant Field Values
HEADER_FG_COLOR
private static final java.lang.String HEADER_FG_COLOR
- See Also:
- Constant Field Values
FRAME_COLOR
private static final java.lang.String FRAME_COLOR
- See Also:
- Constant Field Values
| Constructor Detail |
HttpDebug
public HttpDebug()
| Method Detail |
getRequestDebugInfo
public static java.lang.String getRequestDebugInfo(DebugRequest request) throws java.lang.Exception
- Returns HTML containing all the useful information
in a HTTP Request.
getResponseDebugInfo
public static java.lang.String getResponseDebugInfo(DebugResponse response) throws java.lang.Exception
- Returns HTML containing all the useful information
in a HTTP Response.
addRequestInformation
private static void addRequestInformation(com.lutris.html.HtmlTable tbl, DebugRequest request) throws java.lang.Exception
- Given a HTML table object, this method extracts all useful information
from a httpRequest object and composes a new table row for each
datum.
addHeaderInformation
private static void addHeaderInformation(com.lutris.html.HtmlTable tbl, DebugRequest request) throws java.lang.Exception
- Adds request headers data rows to a table.
addCookieInformation
private static void addCookieInformation(com.lutris.html.HtmlTable tbl, DebugRequest request) throws java.lang.Exception
- Adds request cookie data rows to a table.
formatCookiesAsHtml
private static void formatCookiesAsHtml(com.lutris.html.HtmlTable tbl, javax.servlet.http.Cookie[] cookies, java.lang.String header, boolean showFields) throws java.lang.Exception
- Format the cookies as HTML.
addParameterInformation
private static void addParameterInformation(com.lutris.html.HtmlTable tbl, DebugRequest request) throws java.lang.Exception
- Adds request parameters data rows to a table.
addResponseInformation
private static void addResponseInformation(com.lutris.html.HtmlTable tbl, DebugResponse response) throws java.lang.Exception
- Given a HTML table object, this method extracts all useful information
from a httpResponse object and composes a new table row for each
datum.
addResponseDataInformation
private static void addResponseDataInformation(com.lutris.html.HtmlTable tbl, DebugResponse response) throws java.lang.Exception
- Given a HTML table object, this method adds a section for the
response data (what was writtent to the output stream).
If that data was not saved (most likeley scenerio), the table is
left untouched.
addHeaderInformation
private static void addHeaderInformation(com.lutris.html.HtmlTable tbl, DebugResponse response) throws java.lang.Exception
- Adds response headers data rows to a table.
addCookieInformation
private static void addCookieInformation(com.lutris.html.HtmlTable tbl, DebugResponse response) throws java.lang.Exception
- Adds response cookie data rows to a table.
addTrace
private static void addTrace(com.lutris.html.HtmlTable tbl, DebugRequest request)
- Adds a dump of the request object trace.
formatTraceDebugInfo
public static java.lang.String formatTraceDebugInfo(java.lang.String trace)
- Adds a dump of the response object trace.
formatSessionInfo
public static java.lang.String formatSessionInfo(java.lang.String info, java.lang.String title)
capitalize
private static java.lang.String capitalize(java.lang.String s)
- Capitialize the first letter of a string and any character
following a "-" character. This is the convention for Http
headers.
|
|||||||||
| Home >> All >> com >> lutris >> http >> [ debug overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
com.lutris.http.debug.HttpDebug