Examples of DriverPortletContext


Examples of org.apache.pluto.container.driver.DriverPortletContext

        if (!portletContexts.containsKey(applicationName)) {
          PortletDescriptorRegistry portletRegistry = PortletDescriptorRegistry.getRegistry();

            PortletApplicationDefinition portletApp = portletRegistry.getPortletAppDD(servletContext, applicationName, contextPath);

            DriverPortletContext portletContext = new DriverPortletContextImpl(servletContext, portletApp, rdService);

            portletContexts.put(applicationName, portletContext);

            fireRegistered(portletContext);

            if (LOG.isInfoEnabled()) {
                LOG.info("Registered portlet application for context '/" + applicationName + "'");

                LOG.info("Registering "+portletApp.getPortlets().size()+" portlets for context /"+portletContext.getApplicationName());
            }

            classLoaders.put(portletApp.getName(), Thread.currentThread().getContextClassLoader());
            for (PortletDefinition portlet: portletApp.getPortlets()) {
                String appName = portletContext.getApplicationName();
                if (appName == null) {
                    throw new PortletContainerException("Portlet application name should not be null.");
                }
                portletConfigs.put(
                    portletContext.getApplicationName() + "/" + portlet.getPortletName(),
                    new DriverPortletConfigImpl(portletContext, portlet)
                );
            }
        } else {
             if (LOG.isInfoEnabled()) {
View Full Code Here

Examples of org.apache.pluto.container.driver.DriverPortletContext

    /**
     * @see org.apache.pluto.container.driver.PortletRegistryService#getPortletApplication(java.lang.String)
     */
    public PortletApplicationDefinition getPortletApplication(String applicationName) throws PortletContainerException {
        DriverPortletContext ipc = portletContexts.get(applicationName);
        if (ipc != null) {
            return ipc.getPortletApplicationDefinition();
        }
        String msg = "Unable to retrieve portlet application: '"+applicationName+"'";
        LOG.warn(msg);
        throw new PortletContainerException(msg);
    }
View Full Code Here

Examples of org.apache.pluto.container.driver.DriverPortletContext

      String contextPath = getContextPath(servletContext);
        if (!portletContexts.containsKey(contextPath)) {

            PortletApplicationDefinition portletApp = portletRegistry.getPortletAppDD(servletContext, contextPath, contextPath);

            DriverPortletContext portletContext = new DriverPortletContextImpl(servletContext, portletApp, rdService);

            portletContexts.put(contextPath, portletContext);

            fireRegistered(portletContext);

            if (LOG.isInfoEnabled()) {
                LOG.info("Registered portlet application for context '" + contextPath + "'");

                LOG.info("Registering "+portletApp.getPortlets().size()+" portlets for context /"+portletContext.getApplicationName());
            }

            classLoaders.put(portletApp.getName(), Thread.currentThread().getContextClassLoader());
            for (PortletDefinition portlet: portletApp.getPortlets()) {
                String appName = portletContext.getApplicationName();
                if (appName == null) {
                    throw new PortletContainerException("Portlet application name should not be null.");
                }
                portletConfigs.put(
                    portletContext.getApplicationName() + "/" + portlet.getPortletName(),
                    new DriverPortletConfigImpl(portletContext, portlet)
                );
            }
        } else {
             if (LOG.isInfoEnabled()) {
View Full Code Here

Examples of org.apache.pluto.container.driver.DriverPortletContext

    /**
     * @see org.apache.pluto.container.driver.PortletRegistryService#getPortletApplication(java.lang.String)
     */
    public PortletApplicationDefinition getPortletApplication(String applicationName) throws PortletContainerException {
        DriverPortletContext ipc = portletContexts.get(applicationName);
        if (ipc != null) {
            return ipc.getPortletApplicationDefinition();
        }
        String msg = "Unable to retrieve portlet application: '"+applicationName+"'";
        LOG.warn(msg);
        throw new PortletContainerException(msg);
    }
View Full Code Here

Examples of org.apache.pluto.container.driver.DriverPortletContext

        if (!portletContexts.containsKey(contextPath)) {

            PortletApplicationDefinition portletApp = this
                    .getPortletAppDD(servletContext, contextPath, contextPath);

            DriverPortletContext portletContext = new DriverPortletContextImpl(servletContext, portletApp,
                    requestDispatcherService);

            portletContext.setAttribute(PlatformApiBroker.PORTLET_CONTEXT_ATTRIBUTE_NAME,platformApiBroker);
            portletContexts.put(contextPath, portletContext);

            fireRegistered(portletContext);

            if (logger.isInfoEnabled()) {
                logger.info("Registered portlet application for context '" + contextPath + "'");

                logger.info("Registering " + portletApp.getPortlets().size() + " portlets for context "
                        + portletContext.getApplicationName());
            }

            //TODO have the portlet servlet provide the portlet's classloader as parameter to this method
            //This approach is needed as all pluto callbacks in uPortal have an aspect that switches the thread classloader back
            //to uPortal's classloader.
            ClassLoader classLoader = ThreadContextClassLoaderAspect.getPreviousClassLoader();
            if (classLoader == null) {
                classLoader = Thread.currentThread().getContextClassLoader();
            }
            classLoaders.put(portletApp.getName(), classLoader);
            for (PortletDefinition portlet : portletApp.getPortlets()) {
                String appName = portletContext.getApplicationName();
                if (appName == null) {
                    throw new PortletContainerException("Portlet application name should not be null.");
                }
                portletConfigs.put(portletContext.getApplicationName() + "/" + portlet.getPortletName(),
                        new DriverPortletConfigImpl(portletContext, portlet));
            }
        }
        else {
            if (logger.isInfoEnabled()) {
View Full Code Here

Examples of org.apache.pluto.container.driver.DriverPortletContext

        throw new PortletContainerException(msg);
    }

    @Override
    public PortletApplicationDefinition getPortletApplication(String applicationName) throws PortletContainerException {
        DriverPortletContext ipc = portletContexts.get(applicationName);
        if (ipc != null) {
            return ipc.getPortletApplicationDefinition();
        }
        String msg = "Unable to retrieve portlet application: '" + applicationName + "'";
        logger.warn(msg);
        throw new PortletContainerException(msg);
    }
View Full Code Here

Examples of org.apache.pluto.container.driver.DriverPortletContext

        String applicationName = contextPath.substring(1);
        if (!portletContexts.containsKey(applicationName)) {

            PortletApplicationDefinition portletApp = portletRegistry.getPortletAppDD(servletContext, applicationName, contextPath);

            DriverPortletContext portletContext = new DriverPortletContextImpl(servletContext, portletApp, rdService);

            portletContexts.put(applicationName, portletContext);

            fireRegistered(portletContext);

            if (LOG.isInfoEnabled()) {
                LOG.info("Registered portlet application for context '/" + applicationName + "'");

                LOG.info("Registering "+portletApp.getPortlets().size()+" portlets for context /"+portletContext.getApplicationName());
            }

            classLoaders.put(portletApp.getName(), Thread.currentThread().getContextClassLoader());
            for (PortletDefinition portlet: portletApp.getPortlets()) {
                String appName = portletContext.getApplicationName();
                if (appName == null) {
                    throw new PortletContainerException("Portlet application name should not be null.");
                }
                portletConfigs.put(
                    portletContext.getApplicationName() + "/" + portlet.getPortletName(),
                    new DriverPortletConfigImpl(portletContext, portlet)
                );
            }
        } else {
             if (LOG.isInfoEnabled()) {
View Full Code Here

Examples of org.apache.pluto.container.driver.DriverPortletContext

    /**
     * @see org.apache.pluto.container.driver.PortletRegistryService#getPortletApplication(java.lang.String)
     */
    public PortletApplicationDefinition getPortletApplication(String applicationName) throws PortletContainerException {
        DriverPortletContext ipc = portletContexts.get(applicationName);
        if (ipc != null) {
            return ipc.getPortletApplicationDefinition();
        }
        String msg = "Unable to retrieve portlet application: '"+applicationName+"'";
        LOG.warn(msg);
        throw new PortletContainerException(msg);
    }
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.