Search in sources :

Example 6 with ViewBeanManager

use of com.iplanet.jato.ViewBeanManager in project OpenAM by OpenRock.

the class SCServlet method initializeRequestContext.

/**
     * Initialize request context and set the viewbean manager
     * @param requestContext current request context
     */
protected void initializeRequestContext(RequestContext requestContext) {
    super.initializeRequestContext(requestContext);
    ViewBeanManager viewBeanManager = new ViewBeanManager(requestContext, PACKAGE_NAME);
    ((RequestContextImpl) requestContext).setViewBeanManager(viewBeanManager);
}
Also used : RequestContextImpl(com.iplanet.jato.RequestContextImpl) ViewBeanManager(com.iplanet.jato.ViewBeanManager)

Example 7 with ViewBeanManager

use of com.iplanet.jato.ViewBeanManager in project OpenAM by OpenRock.

the class TaskServlet method initializeRequestContext.

/**
     * Initializes request context and set the viewbean manager.
     *
     * @param requestContext current request context
     */
protected void initializeRequestContext(RequestContext requestContext) {
    super.initializeRequestContext(requestContext);
    ViewBeanManager viewBeanManager = new ViewBeanManager(requestContext, PACKAGE_NAME);
    ((RequestContextImpl) requestContext).setViewBeanManager(viewBeanManager);
}
Also used : RequestContextImpl(com.iplanet.jato.RequestContextImpl) ViewBeanManager(com.iplanet.jato.ViewBeanManager)

Example 8 with ViewBeanManager

use of com.iplanet.jato.ViewBeanManager in project OpenAM by OpenRock.

the class ConsoleServletBase method onRequestHandlerNotFound.

/**
     * Forwards to invalid URL view bean, in case of an invalid target 
     * request handler (page).
     *
     * @param requestContext - request context
     * @param handlerName - name of handler
     * @throws ServletException
     */
protected void onRequestHandlerNotFound(RequestContext requestContext, String handlerName) throws ServletException {
    ViewBeanManager viewBeanManager = requestContext.getViewBeanManager();
    ViewBean targetView = viewBeanManager.getViewBean(AMInvalidURLViewBean.class);
    targetView.forwardTo(requestContext);
    throw new CompleteRequestException();
}
Also used : CompleteRequestException(com.iplanet.jato.CompleteRequestException) ViewBeanManager(com.iplanet.jato.ViewBeanManager) ViewBean(com.iplanet.jato.view.ViewBean)

Example 9 with ViewBeanManager

use of com.iplanet.jato.ViewBeanManager in project OpenAM by OpenRock.

the class ConsoleServletBase method browserRedirect.

private void browserRedirect(RequestContext requestContext, String url) {
    ViewBeanManager mgr = requestContext.getViewBeanManager();
    AMLoginViewBean vb = (AMLoginViewBean) mgr.getViewBean(AMLoginViewBean.class);
    if (getDebug().messageEnabled()) {
        getDebug().message("ConsoleServletBase.browserRedirect " + "redirecting unauthenticated user to " + url);
    }
    vb.setLoginURL(url);
    vb.forwardTo(requestContext);
}
Also used : ViewBeanManager(com.iplanet.jato.ViewBeanManager)

Example 10 with ViewBeanManager

use of com.iplanet.jato.ViewBeanManager in project OpenAM by OpenRock.

the class IDMServlet method initializeRequestContext.

/**
     * Initialize request context and set the viewbean manager
     * @param requestContext current request context
     */
protected void initializeRequestContext(RequestContext requestContext) {
    super.initializeRequestContext(requestContext);
    ViewBeanManager viewBeanManager = new ViewBeanManager(requestContext, PACKAGE_NAME);
    ((RequestContextImpl) requestContext).setViewBeanManager(viewBeanManager);
}
Also used : RequestContextImpl(com.iplanet.jato.RequestContextImpl) ViewBeanManager(com.iplanet.jato.ViewBeanManager)

Aggregations

ViewBeanManager (com.iplanet.jato.ViewBeanManager)30 RequestContextImpl (com.iplanet.jato.RequestContextImpl)18 CompleteRequestException (com.iplanet.jato.CompleteRequestException)10 ViewBean (com.iplanet.jato.view.ViewBean)6 SessionID (com.iplanet.dpro.session.SessionID)1 LoginViewBean (com.sun.identity.authentication.UI.LoginViewBean)1 ISLocaleContext (com.sun.identity.common.ISLocaleContext)1 L10NMessageImpl (com.sun.identity.shared.locale.L10NMessageImpl)1 RequestDispatcher (javax.servlet.RequestDispatcher)1 ServletException (javax.servlet.ServletException)1 HttpServletRequest (javax.servlet.http.HttpServletRequest)1 HttpServletResponse (javax.servlet.http.HttpServletResponse)1 JspException (javax.servlet.jsp.JspException)1