Search in sources :

Example 6 with PortletRegistryService

use of org.apache.pluto.container.driver.PortletRegistryService in project uPortal by Jasig.

the class PortletDefinitionRegistryImpl method getParentPortletApplicationDescriptor.

/* (non-Javadoc)
     * @see org.apereo.portal.portlet.registry.IPortletDefinitionRegistry#getParentPortletApplicationDescriptor(org.apereo.portal.portlet.om.IPortletDefinitionId)
     */
@Override
public PortletApplicationDefinition getParentPortletApplicationDescriptor(IPortletDefinitionId portletDefinitionId) {
    final IPortletDefinition portletDefinition = this.getPortletDefinition(portletDefinitionId);
    if (portletDefinition == null) {
        return null;
    }
    final Tuple<String, String> portletDescriptorKeys = this.getPortletDescriptorKeys(portletDefinition);
    final PortletRegistryService portletRegistryService = this.portalDriverContainerServices.getPortletRegistryService();
    try {
        return portletRegistryService.getPortletApplication(portletDescriptorKeys.first);
    } catch (PortletContainerException e) {
        this.logger.warn("No portlet application descriptor could be found likely not deployed. For portlet definition: " + portletDefinition, e);
        return null;
    }
}
Also used : PortletRegistryService(org.apache.pluto.container.driver.PortletRegistryService) PortletContainerException(org.apache.pluto.container.PortletContainerException) IPortletDefinition(org.apereo.portal.portlet.om.IPortletDefinition)

Aggregations

PortletContainerException (org.apache.pluto.container.PortletContainerException)6 PortletRegistryService (org.apache.pluto.container.driver.PortletRegistryService)6 IPortletDefinition (org.apereo.portal.portlet.om.IPortletDefinition)5 PortletDefinition (org.apache.pluto.container.om.portlet.PortletDefinition)3 Supports (org.apache.pluto.container.om.portlet.Supports)2 ArrayList (java.util.ArrayList)1 List (java.util.List)1 DisplayName (org.apache.pluto.container.om.portlet.DisplayName)1 PortletApplicationDefinition (org.apache.pluto.container.om.portlet.PortletApplicationDefinition)1