Package org.exoplatform.services.portletcontainer

Examples of org.exoplatform.services.portletcontainer.PortletContainerException


                }
            }

        } else {

            PortletContainerException pcException;

            if (pir instanceof ErrorResponse) {
                ErrorResponse errorResponse = (ErrorResponse) pir;
                pcException = new PortletContainerException(errorResponse.getMessage(), errorResponse.getCause());
            } else {
                pcException = new PortletContainerException("Unknown invocation response type [" + pir.getClass()
                        + "]. Expected a FragmentResponse or an ErrorResponse");
            }

            //
            PortletExceptionHandleService portletExceptionService = getApplicationComponent(PortletExceptionHandleService.class);
View Full Code Here


                } else {
                    uicomponent.setConfiguredTitle(null);
                }
            }
        } catch (Exception e) {
            PortletContainerException pcException = new PortletContainerException(e);
            PortletExceptionHandleService portletExceptionService = uicomponent
                    .getApplicationComponent(PortletExceptionHandleService.class);
            if (portletExceptionService != null) {
                portletExceptionService.handle(pcException);
            }
View Full Code Here

                }
            }

        } else {

            PortletContainerException pcException;

            if (pir instanceof ErrorResponse) {
                ErrorResponse errorResponse = (ErrorResponse) pir;
                pcException = new PortletContainerException(errorResponse.getMessage(), errorResponse.getCause());
            } else {
                pcException = new PortletContainerException("Unknown invocation response type [" + pir.getClass()
                        + "]. Expected a FragmentResponse or an ErrorResponse");
            }

            //
            PortletExceptionHandleService portletExceptionService = getApplicationComponent(PortletExceptionHandleService.class);
View Full Code Here

            FragmentResponse fragmentResponse = (FragmentResponse)portletResponse;
            content = new String(fragmentResponse.getBytes(), "UTF-8");
         }
         else
         {
            PortletContainerException pcException;

            //
            if (portletResponse instanceof ErrorResponse)
            {
               ErrorResponse errorResponse = (ErrorResponse)portletResponse;
               pcException = new PortletContainerException(errorResponse.getMessage(), errorResponse.getCause());
            }
            else
            {
               pcException =
                  new PortletContainerException("Unknown invocation response type [" + portletResponse.getClass()
                     + "]. Expected a FragmentResponse or an ErrorResponse");
            }

            //
            PortletExceptionHandleService portletExceptionService = uiPortlet_.getApplicationComponent(PortletExceptionHandleService.class);
View Full Code Here

                  }
                  else
                  {

                     PortletContainerException pcException;

                     if (response instanceof ErrorResponse)
                     {
                        ErrorResponse errorResponse = (ErrorResponse)response;
                        pcException =
                           new PortletContainerException(errorResponse.getMessage(), errorResponse.getCause());
                     }
                     else
                     {
                        pcException =
                           new PortletContainerException("Unknown invocation response type [" + response.getClass()
                              + "]. Expected a FragmentResponse or an ErrorResponse");
                     }

                     //
                     PortletExceptionHandleService portletExceptionService = uicomponent.getApplicationComponent(PortletExceptionHandleService.class);
                     if (portletExceptionService != null)
                     {
                        portletExceptionService.handle(pcException);
                     }

                     // Log the error
                     log.error("Portlet render threw an exception", pcException);

                     markup = Text.create(context.getApplicationResourceBundle().getString("UIPortlet.message.RuntimeError"));
                  }
               }
            }
         }
      }
      catch (Exception e)
      {
         PortletContainerException pcException = new PortletContainerException(e);
         PortletExceptionHandleService portletExceptionService = uicomponent.getApplicationComponent(PortletExceptionHandleService.class);
         if (portletExceptionService != null)
         {
            portletExceptionService.handle(pcException);
         }
View Full Code Here

                }
            }

        } else {

            PortletContainerException pcException;

            if (pir instanceof ErrorResponse) {
                ErrorResponse errorResponse = (ErrorResponse) pir;
                pcException = new PortletContainerException(errorResponse.getMessage(), errorResponse.getCause());
            } else {
                pcException = new PortletContainerException("Unknown invocation response type [" + pir.getClass()
                        + "]. Expected a FragmentResponse or an ErrorResponse");
            }

            //
            PortletExceptionHandleService portletExceptionService = getApplicationComponent(PortletExceptionHandleService.class);
View Full Code Here

                } else {
                    uicomponent.setConfiguredTitle(null);
                }
            }
        } catch (Exception e) {
            PortletContainerException pcException = new PortletContainerException(e);
            PortletExceptionHandleService portletExceptionService = uicomponent
                    .getApplicationComponent(PortletExceptionHandleService.class);
            if (portletExceptionService != null) {
                portletExceptionService.handle(pcException);
            }
View Full Code Here

                  }
                  else
                  {

                     PortletContainerException pcException;

                     if (response instanceof ErrorResponse)
                     {
                        ErrorResponse errorResponse = (ErrorResponse)response;
                        pcException =
                           new PortletContainerException(errorResponse.getMessage(), errorResponse.getCause());
                     }
                     else
                     {
                        pcException =
                           new PortletContainerException("Unknown invocation response type [" + response.getClass()
                              + "]. Expected a FragmentResponse or an ErrorResponse");
                     }

                     PortletExceptionHandleService portletExceptionService =
                        (PortletExceptionHandleService)container
                           .getComponentInstanceOfType(PortletExceptionHandleService.class);
                     portletExceptionService.handle(pcException);

                     markup = Text.create("This portlet encountered an error and could not be displayed.");
                  }
               }
            }
         }
      }
      catch (Exception e)
      {
         PortletContainerException pcException = new PortletContainerException(e);
         PortletExceptionHandleService portletExceptionService =
            (PortletExceptionHandleService)container.getComponentInstanceOfType(PortletExceptionHandleService.class);
         if (portletExceptionService != null)
         {
             portletExceptionService.handle(pcException);
View Full Code Here

            FragmentResponse fragmentResponse = (FragmentResponse)portletResponse;
            content = fragmentResponse.getContent();
         }
         else
         {
            PortletContainerException pcException;

            if (portletResponse instanceof ErrorResponse)
            {
               ErrorResponse errorResponse = (ErrorResponse)portletResponse;
               pcException = new PortletContainerException(errorResponse.getMessage(), errorResponse.getCause());
            }
            else
            {
               pcException =
                  new PortletContainerException("Unknown invocation response type [" + portletResponse.getClass()
                     + "]. Expected a FragmentResponse or an ErrorResponse");
            }

            PortletExceptionHandleService portletExceptionService =
               (PortletExceptionHandleService)uiPortlet_.getApplicationComponent(PortletExceptionHandleService.class);
View Full Code Here

                } else {
                    uicomponent.setConfiguredTitle(null);
                }
            }
        } catch (Exception e) {
            PortletContainerException pcException = new PortletContainerException(e);
            PortletExceptionHandleService portletExceptionService = uicomponent
                    .getApplicationComponent(PortletExceptionHandleService.class);
            if (portletExceptionService != null) {
                portletExceptionService.handle(pcException);
            }
View Full Code Here

TOP

Related Classes of org.exoplatform.services.portletcontainer.PortletContainerException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.