You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pluto-user@portals.apache.org by Robert Lerner <ro...@educ.umu.se> on 2004/11/03 18:19:19 UTC

portletentityregistry

Hi All,

I'm trying to test integrating pluto in a portalApplication. To get 
something up'n running fast I was thinking I'd use the object model from 
the pluto-portal. But i cant really understand how theese things are 
intra connected. I have the portletentityregistry.xml
    <application id="3">
        <definition-id>test-portlet</definition-id>
        <portlet id="1">
            <definition-id>test-portlet.MyTestPortlet</definition-id>
            <preferences/>
        </portlet>
    </application>

I got a portlet deployed in tomcat(4) in test-portlet with a servlet, 
added by pluto, that is mapped to MyTestPortlet/* . This all works well 
in the pluto portal.
But in my portal i can't really get a hold of a complete portletEntity. 
I do it like this (adapted from PortletFragment):

PortletEntity portletEntity = PortletEntityRegistry
                .getPortletEntity(ObjectID.createFromString("3.1"));

portletEntity.getPortletDefinition(); <<--- throws a nullpointer exception
portletEntity.getPortletApplicationEntity().getPortletApplicationDefinition(); 
<<-- is null

The PortletEntityRegistry clearly manages to read from my 
portletentityregistry.xml as i can write out portletEntity and see that 
is has the properties I've defined in the xml.

I'm kind of stuck here, any help would be greatly apreciated.

Best Regards
/Robert