Hi All,
I'm trying to create an instance of PageManager using the following line of
code
public class Simplest extends GenericServletPortlet {
private PageManager pageManager = null;
public void init(PortletConfig config) throws PortletException{
super.init(config);
pageManager = (PageManager)getPortletContext().getAttribute(
CommonPortletServices.CPS_PAGE_MANAGER_COMPONENT);
if (null == pageManager)
{
System.out.println ("page manager is null");
}
System.out.println ("here " + pageManager.getClass().toString());
}
------------------------------
I also have created a jetspeed-portlet.xml with the following content:
<portlet-app id="simplest" version="1.0"
xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"
xmlns:js="http://portals.apache.org/jetspeed"
xmlns:dc="http://www.purl.org/dc">
<dc:title>Jetspeed-2 Simplest Portlets</dc:title>
<dc:title xml:lang="en">Jetspeed-2 Simplest Portlets</dc:title>
<dc:creator>Tarun Mangal</dc:creator>
<portlet>
<portlet-name>Simplest</portlet-name>
<dc:title>Simplest</dc:title>
<dc:creator>J2 Team</dc:creator>
</portlet>
<js:services>
<js:service name='PageManager'/>
</js:services>
</portlet-app>
-------------------------------------------
When i start Tomcat server and call for the portlet, I get a message on the
Tomcat start window "page manager is null"
Can you please tell what is the correct procedure of creating an instance of
a service.
Thanks,
Tarun