Class DefaultAjaxHandler
java.lang.Object
org.springframework.context.support.ApplicationObjectSupport
org.springframework.web.context.support.WebApplicationObjectSupport
org.springframework.webflow.context.servlet.AbstractAjaxHandler
org.springframework.webflow.context.servlet.DefaultAjaxHandler
- All Implemented Interfaces:
- org.springframework.beans.factory.Aware,- org.springframework.context.ApplicationContextAware,- org.springframework.web.context.ServletContextAware,- AjaxHandler
Default 
AjaxHandler implementation.
 Detects Ajax requests through an "Accept" header with the value
 AJAX_ACCEPT_CONTENT_TYPE or a request parameter with the name
 AJAX_SOURCE_PARAM.
 
Also for a redirect during an Ajax request it sets the response headers
 REDIRECT_URL_HEADER and POPUP_VIEW_HEADER. The latter is
 set if the redirect occurs on a view state with popup="true".
- Since:
- 2.5
- Author:
- Rossen Stoyanchev
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final String"Accept" header value that indicates an Ajax request.static final StringRequest parameter alternative that indicate an Ajax request.static final StringResponse header to be set on a redirect that should be issued from a popup window.static final StringResponse header to be set on an Ajax redirect with the redirect locationFields inherited from class org.springframework.context.support.ApplicationObjectSupportlogger
- 
Constructor SummaryConstructorsConstructorDescriptionCreate a DefaultAjaxHandler that is not part of a chain of AjaxHandler's.DefaultAjaxHandler(AbstractAjaxHandler delegate) Create a DefaultAjaxHandler as part of a chain of AjaxHandler's.
- 
Method SummaryModifier and TypeMethodDescriptionprotected booleanisAjaxRequestInternal(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) protected voidsendAjaxRedirectInternal(String targetUrl, jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, boolean popup) Methods inherited from class org.springframework.webflow.context.servlet.AbstractAjaxHandlerisAjaxRequest, sendAjaxRedirectMethods inherited from class org.springframework.web.context.support.WebApplicationObjectSupportgetServletContext, getTempDir, getWebApplicationContext, initApplicationContext, initServletContext, isContextRequired, setServletContextMethods inherited from class org.springframework.context.support.ApplicationObjectSupportgetApplicationContext, getMessageSourceAccessor, initApplicationContext, obtainApplicationContext, requiredContextClass, setApplicationContext
- 
Field Details- 
AJAX_ACCEPT_CONTENT_TYPE"Accept" header value that indicates an Ajax request.- See Also:
 
- 
AJAX_SOURCE_PARAMRequest parameter alternative that indicate an Ajax request.- See Also:
 
- 
REDIRECT_URL_HEADERResponse header to be set on an Ajax redirect with the redirect location- See Also:
 
- 
POPUP_VIEW_HEADERResponse header to be set on a redirect that should be issued from a popup window.- See Also:
 
 
- 
- 
Constructor Details- 
DefaultAjaxHandlerpublic DefaultAjaxHandler()Create a DefaultAjaxHandler that is not part of a chain of AjaxHandler's.
- 
DefaultAjaxHandlerCreate a DefaultAjaxHandler as part of a chain of AjaxHandler's.
 
- 
- 
Method Details- 
isAjaxRequestInternalprotected boolean isAjaxRequestInternal(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) - Specified by:
- isAjaxRequestInternalin class- AbstractAjaxHandler
 
- 
sendAjaxRedirectInternalprotected void sendAjaxRedirectInternal(String targetUrl, jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, boolean popup) - Specified by:
- sendAjaxRedirectInternalin class- AbstractAjaxHandler
 
 
-