AlfrescoFacesPortlet.java 文件源码

java
阅读 18 收藏 0 点赞 0 评论 0

项目:community-edition-old 作者:
/**
 * Handles errors that occur during a process action request
 */
private void handleError(ActionRequest request, ActionResponse response, Throwable error)
   throws PortletException, IOException
{
   // get the error bean from the session and set the error that occurred.
   PortletSession session = request.getPortletSession();
   ErrorBean errorBean = (ErrorBean)session.getAttribute(ErrorBean.ERROR_BEAN_NAME, 
                          PortletSession.PORTLET_SCOPE);
   if (errorBean == null)
   {
      errorBean = new ErrorBean();
      session.setAttribute(ErrorBean.ERROR_BEAN_NAME, errorBean, PortletSession.PORTLET_SCOPE);
   }
   errorBean.setLastError(error);

   response.setRenderParameter(ERROR_OCCURRED, "true");
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号