1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.apache.jetspeed.container.invoker;
18
19 import javax.servlet.ServletConfig;
20
21 import org.apache.jetspeed.factory.PortletFactory;
22 import org.apache.pluto.invoker.PortletInvoker;
23 import org.apache.pluto.om.portlet.PortletDefinition;
24
25 /***
26 * JetspeedPortletInvoker extends Pluto's portlet invoker and extends it
27 * with lifecycle management. Portlet Invokers can be pooled, and activated
28 * and passivated per request cycle.
29 *
30 * @author <a href="mailto:taylor@apache.org">David Sean Taylor</a>
31 * @version $Id: JetspeedPortletInvoker.java 516448 2007-03-09 16:25:47Z ate $
32 */
33 public interface JetspeedPortletInvoker extends PortletInvoker
34 {
35 /***
36 * Activating an invoker makes it ready to invoke portlets.
37 * If an invoker's state is not activated, it can not invoke.
38 *
39 * @param portletFactory The factory to get access to the portlet being invoked.
40 * @param portletDefinition The portlet's definition that is being invoked.
41 * @param servletConfig The servlet configuration of the portal.
42 * @param containerServlet
43 */
44 void activate(PortletFactory portletFactory, PortletDefinition portletDefinition, ServletConfig servletConfig);
45
46 /***
47 * Activating an invoker makes it ready to invoke portlets.
48 * If an invoker's state is not activated, it can not invoke.
49 * This second signature allows for activating with an extra property.
50 *
51 * @param portletFactory The factory to get access to the portlet being invoked.
52 * @param portletDefinition The portlet's definition that is being invoked.
53 * @param servletConfig The servlet configuration of the portal.
54 * @param property Implementation specific property
55 * @param containerServlet
56 */
57 void activate(PortletFactory portletFactory, PortletDefinition portletDefinition, ServletConfig servletConfig, String property);
58
59 /***
60 * Passivates an invoker, freeing it back to the invoker pool.
61 * If an invoker's state is passivated, it cannot be used to invoke portlets.
62 */
63 void passivate();
64
65 /***
66 * Returns true if the state of this invoke is 'activated', and false if it is 'passivated'.
67 * @return True if the current state of the invoker is 'activated' otherwise false.
68 */
69 boolean isActivated();
70 }