Package org.apache.pluto.om.portlet

Examples of org.apache.pluto.om.portlet.PortletApplicationDefinition


    /* (non-Javadoc)
     * @see org.apache.pluto.om.entity.PortletApplicationEntityListCtrl#add(java.lang.String)
     */
    public PortletApplicationEntity add(String definitionId) {
        PortletApplicationDefinitionList padl = this.registry.getPortletApplicationDefinitionList();
        PortletApplicationDefinition pad = padl.get(org.apache.cocoon.portal.pluto.om.common.ObjectIDImpl.createFromString(definitionId));
        PortletApplicationEntityImpl pae = new PortletApplicationEntityImpl(definitionId, pad);
        this.portletApplicationEntities.put(pae.getId(), pae);
        return pae;
    }
View Full Code Here


    // Support implementation.
   
    public void preBuild(Object parameter) throws Exception
    {
        Vector structure = (Vector)parameter;
        PortletApplicationDefinition portletApplication = (PortletApplicationDefinition)structure.get(0);
        Map servletMap = (Map)structure.get(1);

        Iterator iterator = this.iterator();
        while (iterator.hasNext()) {
            PortletDefinition portlet = (PortletDefinition)iterator.next();
View Full Code Here

    /* (non-Javadoc)
     * @see org.apache.pluto.om.entity.PortletApplicationEntityListCtrl#add(java.lang.String)
     */
    public PortletApplicationEntity add(String definitionId) {
        PortletApplicationDefinitionList padl = this.registry.getPortletApplicationDefinitionList();
        PortletApplicationDefinition pad = padl.get(org.apache.cocoon.portal.pluto.om.common.ObjectIDImpl.createFromString(definitionId));
        PortletApplicationEntityImpl pae = new PortletApplicationEntityImpl(definitionId, pad);
        this.portletApplicationEntities.put(pae.getId(), pae);
        return pae;
    }
View Full Code Here

    // Support implementation.
   
    public void preBuild(Object parameter) throws Exception
    {
        Vector structure = (Vector)parameter;
        PortletApplicationDefinition portletApplication = (PortletApplicationDefinition)structure.get(0);
        Map servletMap = (Map)structure.get(1);

        Iterator iterator = this.iterator();
        while (iterator.hasNext()) {
            PortletDefinition portlet = (PortletDefinition)iterator.next();
View Full Code Here

    /* (non-Javadoc)
     * @see org.apache.cocoon.portal.pluto.om.common.Support#postLoad(java.lang.Object)
     */
    public void postLoad(Object parameter) throws Exception {
        Vector structure = (Vector)parameter;
        PortletApplicationDefinition portletApplication = (PortletApplicationDefinition)structure.get(0);

        ((Support)portletApplication).postLoad(this);

        ((Support)servlets).postLoad(this);

View Full Code Here

    /* (non-Javadoc)
     * @see org.apache.cocoon.portal.pluto.om.common.Support#preBuild(java.lang.Object)
     */
    public void preBuild(Object parameter) throws Exception {
        Vector structure = (Vector)parameter;
        PortletApplicationDefinition portletApplication = (PortletApplicationDefinition)structure.get(0);
        String contextString = (String)structure.get(1);

        setContextRoot(contextString);

        HashMap servletMap = new HashMap(1);
View Full Code Here

    /* (non-Javadoc)
     * @see org.apache.cocoon.portal.pluto.om.common.Support#preStore(java.lang.Object)
     */
    public void preStore(Object parameter) throws Exception {
        Vector structure = (Vector)parameter;
        PortletApplicationDefinition portletApplication = (PortletApplicationDefinition)structure.get(0);

        ((Support)portletApplication).preStore(null);

        ((Support)servlets).preStore(this);
    }
View Full Code Here

            throw new IllegalArgumentException("portletGUID [" + portletGUID
                    + "] was not in required format: portletGUIDs must contain a '.' character.");
        }
       
        String contextName = portletDefinitionId.substring(0, dotIndex);
        PortletApplicationDefinition portletApplicationDefinition = portletApplicationDefinitionList.get(ObjectIDImpl.createFromString(contextName));
        PortletDefinition portletDefinition = null;
        if (portletApplicationDefinition != null) {
            PortletDefinitionList portletDefinitionList = portletApplicationDefinition.getPortletDefinitionList();
            portletDefinition = portletDefinitionList.get(ObjectIDImpl.createFromString(portletDefinitionId));
        }
        return portletDefinition;
    }
View Full Code Here

                               
                                // Parse the portlet.xml file --> PortletApplicationDefinition
                                xmlFile = "portlet.xml";
                                PortletApplicationUnmarshaller pau = new PortletApplicationUnmarshaller();
                                pau.init(new FileInputStream(portletXmlFile), contextName);
                                PortletApplicationDefinition portletApplicationDefinition = pau.getPortletApplicationDefinition(webApplicationDefinition);
                           
                                // Add this PortletApplicationDefinition to the list
                                portletApplicationDefinitionList.add(portletApplicationDefinition.getId().toString(), portletApplicationDefinition);
                            } catch (Exception e) {
                                log.error( "Unable to parse " + xmlFile + " for context '" + contextName + "'", e);
                            }
                        }
                    }
View Full Code Here

            }
           
            // Now get the portlet application definition out of portlet.xml
            PortletApplicationUnmarshaller pau = new PortletApplicationUnmarshaller();
            pau.init(new FileInputStream(portletXml), webModule);
            PortletApplicationDefinition portletApplicationDefinition = pau.getPortletApplicationDefinition(webApplicationDefinition);
         
            ControllerFactory controllerFactory = new ControllerFactoryImpl();

            ServletDefinitionListCtrl servletDefinitionSetCtrl = (ServletDefinitionListCtrl)controllerFactory.get(webApplicationDefinition.getServletDefinitionList());
            ServletMappingListImpl servletMappings = webApplicationDefinition.getServletMappings();

            Iterator portlets = portletApplicationDefinition.getPortletDefinitionList().iterator();
            while (portlets.hasNext()) {

                PortletDefinition portlet = (PortletDefinition)portlets.next();

                // Check if already exists
View Full Code Here

TOP

Related Classes of org.apache.pluto.om.portlet.PortletApplicationDefinition

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.