Examples of WebAppController


Examples of org.exoplatform.web.WebAppController

    * @return Gadget Application
    * @throws Exception
    */
   private GadgetApplication getApplication()
   {
      WebAppController webController = getApplicationComponent(WebAppController.class);
      GadgetApplication application = webController.getApplication("eXoGadgets/" + gadgetId);
      if (application == null)
      {
         GadgetRegistryService gadgetService = getApplicationComponent(GadgetRegistryService.class);
         Gadget model;
         try
         {
            model = gadgetService.getGadget(gadgetId);
         }
         catch (Exception ex)
         {
            return null;
         }
         if (model != null)
         {
            application = GadgetUtil.toGadgetApplication(model);
            webController.addApplication(application);
         }
      }
      return application;
   }
View Full Code Here

Examples of org.exoplatform.web.WebAppController

     *
     * If it does not exist a new PortletApplication object is created, init and cached in the controller
     */
    private PortletApplication getPortletApplication() throws Exception {
        ExoContainer container = ExoContainerContext.getCurrentContainer();
        WebAppController controller = (WebAppController) container.getComponentInstanceOfType(WebAppController.class);
        PortletApplication application = controller.getApplication(applicationId_);
        if (application == null) {
            if (appProvider != null) {
                // We are only expecting one
                application = appProvider.createApplication(getPortletConfig());
            } else {
                application = new PortletApplication(getPortletConfig());
            }
            application.onInit();
            application = controller.addApplication(application);
        }
        return application;
    }
View Full Code Here

Examples of org.exoplatform.web.WebAppController

        List<ExoContainer> containers = rootContainer.getComponentInstancesOfType(ExoContainer.class);
        containers.add(rootContainer);
        try {
            for (ExoContainer container : containers) {
                ExoContainerContext.setCurrentContainer(container);
                WebAppController controller = (WebAppController) container.getComponentInstanceOfType(WebAppController.class);
                // TODO: figure out what is happening with the controller not existing during shutdown
                if (controller != null) {
                    PortletApplication application = controller.getApplication(applicationId_);
                    if (application != null) {
                        application.onDestroy();
                        controller.removeApplication(applicationId_);
                    }
                }
            }
        } catch (Exception ex) {
            log.error("Error while destroying the porlet", ex);
View Full Code Here

Examples of org.exoplatform.web.WebAppController

      try
      {
         for (ExoContainer container : containers)
         {
            ExoContainerContext.setCurrentContainer(container);
            WebAppController controller =
               (WebAppController)container.getComponentInstanceOfType(WebAppController.class);
            //TODO: figure out what is happening with the controller not existing during shutdown
            if (controller != null)
            {
               PortletApplication application = controller.getApplication(applicationId_);
               if (application != null)
               {
                  application.onDestroy();
                  controller.removeApplication(applicationId_);
               }
            }
         }
      }
      catch (Exception ex)
View Full Code Here

Examples of org.exoplatform.web.WebAppController

    * controller
    */
   private PortletApplication getPortletApplication() throws Exception
   {
      ExoContainer container = ExoContainerContext.getCurrentContainer();
      WebAppController controller = (WebAppController)container.getComponentInstanceOfType(WebAppController.class);
      PortletApplication application = controller.getApplication(applicationId_);
      if (application == null)
      {
         application = new PortletApplication(getPortletConfig());
         application.onInit();
         controller.addApplication(application);
      }
      return application;
   }
View Full Code Here

Examples of org.exoplatform.web.WebAppController

     *
     * If it does not exist a new PortletApplication object is created, init and cached in the controller
     */
    private PortletApplication getPortletApplication() throws Exception {
        ExoContainer container = ExoContainerContext.getCurrentContainer();
        WebAppController controller = (WebAppController) container.getComponentInstanceOfType(WebAppController.class);
        PortletApplication application = controller.getApplication(applicationId_);
        if (application == null) {
            if (appProvider != null) {
                // We are only expecting one
                application = appProvider.createApplication(getPortletConfig());
            } else {
                application = new PortletApplication(getPortletConfig());
            }
            application.onInit();
            application = controller.addApplication(application);
        }
        return application;
    }
View Full Code Here

Examples of org.exoplatform.web.WebAppController

        List<ExoContainer> containers = rootContainer.getComponentInstancesOfType(ExoContainer.class);
        containers.add(rootContainer);
        try {
            for (ExoContainer container : containers) {
                ExoContainerContext.setCurrentContainer(container);
                WebAppController controller = (WebAppController) container.getComponentInstanceOfType(WebAppController.class);
                // TODO: figure out what is happening with the controller not existing during shutdown
                if (controller != null) {
                    PortletApplication application = controller.getApplication(applicationId_);
                    if (application != null) {
                        application.onDestroy();
                        controller.removeApplication(applicationId_);
                    }
                }
            }

        } catch (Exception ex) {
View Full Code Here

Examples of org.exoplatform.web.WebAppController

        }

        User user = (managedUser == null || managedUser.getUserName() == null) ? User.anonymous() : new User(managedUser.getUserName());

        final PortalContainer container = PortalContainer.getInstance();
        final WebAppController controller = (WebAppController) container.getComponentInstanceOfType(WebAppController.class);
        URIResolver uriResolver = new URIResolver() {
            @Override
            public String resolveURI(SiteId siteId) {
                SiteKey siteKey = Util.from(siteId);
                NavigationResource navResource = new NavigationResource(siteKey, "");
View Full Code Here

Examples of org.jboss.as.webservices.util.WebAppController

    @Override
    public void start(final StartContext ctx) throws StartException {
        ROOT_LOGGER.starting(name);
        String serverTempDir = serverConfigInjectorValue.getValue().getServerTempDir().getAbsolutePath();
        ClassLoader cl = ClassLoaderProvider.getDefaultProvider().getServerJAXRPCIntegrationClassLoader();
        pclwa = new WebAppController(hostInjector.getValue().getHost(), "org.jboss.ws.core.server.PortComponentLinkServlet",
                cl, "/jbossws", "/pclink", serverTempDir);
    }
View Full Code Here

Examples of org.jboss.as.webservices.util.WebAppController

    @Override
    public void start(final StartContext ctx) throws StartException {
        ROOT_LOGGER.starting(name);
        String serverTempDir = serverConfigInjectorValue.getValue().getServerTempDir().getAbsolutePath();
        ClassLoader cl = ClassLoaderProvider.getDefaultProvider().getServerJAXRPCIntegrationClassLoader();
        pclwa = new WebAppController(hostInjector.getValue().getHost(), "org.jboss.ws.core.server.PortComponentLinkServlet",
                cl, "/jbossws", "/pclink", serverTempDir);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.