|
Novell exteNd Director 5.2 API |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Defines constants for response phrase and response status.
A response type indicates the type of value the component will find in the response phrase. Values are are CONTENT, HTML, TEXT, and URL.
A response status is an HTTP status code, the same values that are defined as named constants in javax.servlet.http.HttpServletResponse.
1xx: Informational - Request received, continuing process
2xx: Success - The action was successfully received, understood, and accepted
3xx: Redirection - Further action must be taken in order to complete the request
4xx: Client Error - The request contains bad syntax or cannot be fulfilled
5xx: Server Error - The server failed to fulfill an apparently valid request
Field Summary | |
static int |
CONTENT
HTTP status code: Content. |
static int |
HTML
HTTP status code: HTML. |
static int |
R000
HTTP status code: unknown. |
static int |
R100
HTTP status code: unknown. |
static int |
R101
HTTP status code: Switching Protocols. |
static int |
R200
HTTP status code: OK, request succeeded. |
static int |
R201
HTTP status code: OK, new content created ( POST command ). |
static int |
R202
HTTP status code: Request accepted but processing not completed. |
static int |
R203
HTTP status code: OK, Non-Authoritative Information. |
static int |
R204
HTTP status code: OK, but no uri to return. |
static int |
R205
HTTP status code: OK, reset uri. |
static int |
R206
HTTP status code: OK, partial uri. |
static int |
R300
HTTP status code: Multiple Choices. |
static int |
R301
HTTP status code: Request content has been assigned a new permanent URL. |
static int |
R302
HTTP status code: Request content resides temporarily under a different URL. |
static int |
R303
HTTP status code: Document has not been modified ( conditional GET ). |
static int |
R304
HTTP status code: Not modified. |
static int |
R305
HTTP status code: Use proxy. |
static int |
R307
HTTP status code: Temporary redirect. |
static int |
R400
HTTP status code: Bad request. |
static int |
R401
HTTP status code: Unauthorized, request requires authorization. |
static int |
R402
HTTP status code: Payment required. |
static int |
R403
HTTP status code: Forbidden for unspecified reason. |
static int |
R404
HTTP status code: Not found. |
static int |
R405
HTTP status code: Method not allowed. |
static int |
R406
HTTP status code: Not acceptable. |
static int |
R407
HTTP status code: Proxy Authentication Requried. |
static int |
R408
HTTP status code: Request Time-out. |
static int |
R409
HTTP status code: Conflict. |
static int |
R410
HTTP status code: Gone. |
static int |
R411
HTTP status code: Length required. |
static int |
R412
HTTP status code: Precondition failed. |
static int |
R413
HTTP status code: Request entity too large. |
static int |
R414
HTTP status code: Request-URI too large. |
static int |
R415
HTTP status code: Unsupported media type. |
static int |
R416
HTTP status code: Requested range not satisfiable. |
static int |
R417
HTTP status code: Expectation failed. |
static int |
R500
HTTP status code: Internal server error. |
static int |
R501
HTTP status code: Not implemented. |
static int |
R502
HTTP status code: Bad gateway; invalid response from gateway or upstream server. |
static int |
R503
HTTP status code: Service temporarily unavailable. |
static int |
R504
HTTP status code: Gateway Time-out. |
static int |
R505
HTTP status code: HTTP Version not supported. |
static int |
TEXT
HTTP status code: Text. |
static int |
URL
HTTP status code: URL. |
Method Summary | |
boolean |
containsHeader(String key)
Returns true if the specified key is found on the HttpServletResponseHeader. |
String |
getContentType()
Returns the response content type |
EbiContext |
getContext()
Deprecated. (since v5.0) |
HttpServletResponse |
getHttpServletResponse()
Deprecated. (since v5.0) Use EbiHttpResponse.getHttpServletResponse() |
int |
getResponseType()
Deprecated. (since v5.0) |
int |
getStatus()
Deprecated. (since v5.0) |
String |
getType()
Returns the type of respons |
boolean |
getUpdateHttpServletResponse()
Deprecated. |
boolean |
hasHttpServletResponse()
Checks to see if this response has an HttpServletResponse. |
boolean |
isResponseType(int responseType)
Deprecated. (since v5.0) |
boolean |
isStatus(int status)
Deprecated. (since v5.0) |
void |
sendRedirect(String url)
Sets the response to redirect to the passed in URL. |
void |
setContentType(String contentType)
Sets the response content type. |
void |
setContext(EbiContext context)
Deprecated. (since v5.0) |
void |
setDateHeader(String key,
long value)
Deprecated. (since v5.0) |
void |
setHeader(String key,
String value)
Set a key/value pair on the HttpServletResponse header. |
void |
setHttpServletResponse(HttpServletResponse httpServletResponse)
Deprecated. (since v5.0) |
void |
setResponse(int responseCode,
String responsePhrase)
Set the response status and phrase Ignored by Portlet Reponses |
void |
setResponsePhrase(String responsePhrase)
Deprecated. (Since v5.0) use EbiRequestContext.setResponsePhrase(String) |
void |
setResponseType(int responseType)
Set the response type note: Ignored by Portlet Reponses |
void |
setStatus(int status)
Sets the response status. |
void |
setUpdateHttpServletResponse(boolean updateHttpServletResponse)
Deprecated. (since v5.0) |
Field Detail |
public static final int R000
javax.servlet.http.HttpServletResponse.
public static final int R100
javax.servlet.http.HttpServletResponse.
public static final int R101
javax.servlet.http.HttpServletResponse.
public static final int R200
javax.servlet.http.HttpServletResponse.
public static final int R201
javax.servlet.http.HttpServletResponse.
public static final int R202
javax.servlet.http.HttpServletResponse.
public static final int R203
javax.servlet.http.HttpServletResponse.
public static final int R204
javax.servlet.http.HttpServletResponse.
public static final int R205
javax.servlet.http.HttpServletResponse.
public static final int R206
javax.servlet.http.HttpServletResponse.
public static final int R300
javax.servlet.http.HttpServletResponse.
public static final int R301
javax.servlet.http.HttpServletResponse.
public static final int R302
javax.servlet.http.HttpServletResponse.
public static final int R303
javax.servlet.http.HttpServletResponse.
public static final int R304
javax.servlet.http.HttpServletResponse.
public static final int R305
javax.servlet.http.HttpServletResponse.
public static final int R307
javax.servlet.http.HttpServletResponse.
public static final int R400
javax.servlet.http.HttpServletResponse.
public static final int R401
javax.servlet.http.HttpServletResponse.
public static final int R402
javax.servlet.http.HttpServletResponse.
public static final int R403
javax.servlet.http.HttpServletResponse.
public static final int R404
javax.servlet.http.HttpServletResponse.
public static final int R405
javax.servlet.http.HttpServletResponse.
public static final int R406
javax.servlet.http.HttpServletResponse.
public static final int R407
javax.servlet.http.HttpServletResponse.
public static final int R408
javax.servlet.http.HttpServletResponse.
public static final int R409
javax.servlet.http.HttpServletResponse.
public static final int R410
javax.servlet.http.HttpServletResponse.
public static final int R411
javax.servlet.http.HttpServletResponse.
public static final int R412
javax.servlet.http.HttpServletResponse.
public static final int R413
javax.servlet.http.HttpServletResponse.
public static final int R414
javax.servlet.http.HttpServletResponse.
public static final int R415
javax.servlet.http.HttpServletResponse.
public static final int R416
javax.servlet.http.HttpServletResponse.
public static final int R417
javax.servlet.http.HttpServletResponse.
public static final int R500
javax.servlet.http.HttpServletResponse.
public static final int R501
javax.servlet.http.HttpServletResponse.
public static final int R502
javax.servlet.http.HttpServletResponse.
public static final int R503
javax.servlet.http.HttpServletResponse.
public static final int R504
javax.servlet.http.HttpServletResponse.
public static final int R505
javax.servlet.http.HttpServletResponse.
public static final int CONTENT
javax.servlet.http.HttpServletResponse.
public static final int TEXT
javax.servlet.http.HttpServletResponse.
public static final int URL
javax.servlet.http.HttpServletResponse.
public static final int HTML
javax.servlet.http.HttpServletResponse.
Method Detail |
public HttpServletResponse getHttpServletResponse()
EbiHttpResponse.getHttpServletResponse()
The wrapped response may not implement EbiHttpResponse
here is an example of the proper code to use:
EbiResponse res = ctxt.getEbiResponse(); if (res instanceofEbiHttpResponse
){ HttpServletResponse hres = ((EbiHttpResponse)res).getHttpServletResponse(); }
public void setHttpServletResponse(HttpServletResponse httpServletResponse)
Use the proper factory to create and set the response. for example
com.sssw.fw.factory.EboFactory.createEbinContext(req,res)httpServletResponse
- public boolean hasHttpServletResponse()
returns true if the response object implement EbiHttpResponse and the wrapped HttpServletResponse is not null
public String getType()
TYPE_RENDER, TYPE_ACTION, TYPE_HTTP
public boolean getUpdateHttpServletResponse()
Out dated and no longer used
public void setUpdateHttpServletResponse(boolean updateHttpServletResponse)
updateHttpServletResponse
- indicator of status for updateHttpServletResponse flag.public void sendRedirect(String url)
To be sure that the response supports a redirect use the following code
javax.poretlet.RenderResponse does not support a redirectEbiResponse res = ctxt.getEbiResponse(); if (!res instanceof EbiRenderResponse}){ res.sendRedirect }
url
- Redirects user to given URLpublic void setContentType(String contentType)
contentType
- the responses content type.public String getContentType()
Note: EbiActionResponse does not support this method and will throw an Unsupported exception
public EbiContext getContext()
Note: EbiActionResponse does not support this method and will throw an Unsupported exception
public void setContext(EbiContext context)
context
- to associate with the response.public void setHeader(String key, String value)
key
- value
- public void setDateHeader(String key, long value)
EbiHttpResponse.getHttpServletResponse()
to set http specific headerskey
- value
- public boolean containsHeader(String key)
public void setStatus(int status)
status
- of response status.public int getStatus()
public boolean isStatus(int status)
status
- value used in comparison.public void setResponse(int responseCode, String responsePhrase)
responseCode
- status.responsePhrase
- phrase.public void setResponseType(int responseType)
responseType
- of response type.public int getResponseType()
public boolean isResponseType(int responseType)
response
- type value for comparison.public void setResponsePhrase(String responsePhrase)
EbiRequestContext.setResponsePhrase(String)
responsePhrase
- phrase value.
|
Novell exteNd Director 5.2 API |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |