|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface StatusViewRenderer
Interface for an object that can display "status views" to the end user under certain conditions. These include errors (failed location request) and intermediate steps in a request flow (a "please wait" page). To avoid dependencies on any specific web application framework, Veriplace abstracts this process into an interface.
The SDK includes simple implementations of this interface for servlets
(ServletStatusViewRenderer) and Spring servlets
(SpringStatusViewRenderer). If you use the
AbstractVeriplaceServlet class or the JSP tags,
a ServletStatusViewRenderer is created for you; see VeriplaceServletHelper
for how to customize its properties. Spring applications should define their own
SpringStatusViewRenderer bean if desired.
You do not need to use a StatusViewRenderer at all, as long as your code checks for
exceptions and returns the appropriate output. Be sure to handle the WaitingException
if you will be making asynchronous requests.
| Method Summary | |
|---|---|
boolean |
canRenderWaitingView()
Returns true if this StatusViewRenderer is able to display content for the "please wait" condition. |
boolean |
renderErrorView(HttpServletRequest request,
HttpServletResponse response,
VeriplaceState state,
java.lang.Exception exception)
Displays an appropriate error response for a given exception. |
boolean |
renderWaitingView(HttpServletRequest request,
HttpServletResponse response,
VeriplaceState state,
java.lang.String callbackUrl)
Displays appropriate content for the "please wait" condition. |
| Method Detail |
|---|
boolean renderErrorView(HttpServletRequest request,
HttpServletResponse response,
VeriplaceState state,
java.lang.Exception exception)
throws StatusViewException,
ServletException
StatusViewException - if there was an error in rendering the view
ServletException
boolean renderWaitingView(HttpServletRequest request,
HttpServletResponse response,
VeriplaceState state,
java.lang.String callbackUrl)
throws StatusViewException,
ServletException
callbackUrl - the URL to use for an automatic refresh
StatusViewException - if there was an error in rendering the view
ServletExceptionboolean canRenderWaitingView()
renderWaitingView(HttpServletRequest, HttpServletResponse, VeriplaceState, String)
will never be called.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||