|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.wicket.request.Request org.apache.wicket.request.http.WebRequest
public abstract class WebRequest
Base class for request that provides additional web-related information.
Field Summary | |
---|---|
static java.lang.String |
HEADER_AJAX
marker for Ajax requests |
protected static java.lang.String |
HEADER_AJAX_BASE_URL
marker for Ajax-relative url |
protected static java.lang.String |
PARAM_AJAX
marker for Ajax requests |
protected static java.lang.String |
PARAM_AJAX_BASE_URL
marker for Ajax-relative url |
Constructor Summary | |
---|---|
WebRequest()
|
Method Summary | |
---|---|
WebRequest |
cloneWithUrl(Url url)
Returns request with specified URL and same POST parameters as this request. |
javax.servlet.http.Cookie |
getCookie(java.lang.String cookieName)
|
abstract java.util.List<javax.servlet.http.Cookie> |
getCookies()
|
abstract Time |
getDateHeader(java.lang.String name)
Returns the value of the specified request header as a long value that
represents a Date object. |
abstract java.lang.String |
getHeader(java.lang.String name)
Returns the value of the specified request header as a String |
abstract java.util.List<java.lang.String> |
getHeaders(java.lang.String name)
Returns all the values of the specified request header. |
Time |
getIfModifiedSinceHeader()
Convenience method for retrieving If-Modified-Since header. |
boolean |
isAjax()
Returns whether this request is an Ajax request. |
boolean |
shouldPreserveClientUrl()
Signals whether or not request processing should preserve the current client url - in other words, handle this request without redirecting. |
Methods inherited from class org.apache.wicket.request.Request |
---|
getCharset, getClientUrl, getContainerRequest, getContextPath, getFilterPath, getLocale, getOriginalUrl, getPostParameters, getPrefixToContextPath, getQueryParameters, getRequestParameters, getUrl |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final java.lang.String PARAM_AJAX
public static final java.lang.String HEADER_AJAX
protected static final java.lang.String PARAM_AJAX_BASE_URL
protected static final java.lang.String HEADER_AJAX_BASE_URL
Constructor Detail |
---|
public WebRequest()
Method Detail |
---|
public abstract java.util.List<javax.servlet.http.Cookie> getCookies()
public javax.servlet.http.Cookie getCookie(java.lang.String cookieName)
cookieName
-
null
if the cookie does not existpublic abstract java.util.List<java.lang.String> getHeaders(java.lang.String name)
name
-
public abstract java.lang.String getHeader(java.lang.String name)
String
name
-
public abstract Time getDateHeader(java.lang.String name)
long
value that
represents a Date
object. Use this method with headers that contain dates, such
as If-Modified-Since
.
name
-
null
if not foundpublic final Time getIfModifiedSinceHeader()
null
if not setpublic boolean isAjax()
true
if this request is an ajax request, false
otherwise.public boolean shouldPreserveClientUrl()
false
.
For example, this method can be used to preserve the url that caused a 404 in the browser if
Wicket is also responsible for rendering the 404 page. If this method returns the default
value of false
then Wicket will redirect to the bookmarkable url of the error page,
instead of preserving the url that caused the 404 in the browser.
true
if current client url should be preservedpublic WebRequest cloneWithUrl(Url url)
cloneWithUrl
in class Request
url
- Url instance
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |