ate 2005/03/01 18:35:16
Modified: components/registry/src/java/org/apache/jetspeed/om/portlet/impl
Tag: deployment-refactoring
PortletDefinitionImpl.java
Log:
Registry changes (Portlet Classloader is now only maintained in the
PortletFactory)
Revision Changes Path
No revision
No revision
1.26.2.1 +15 -5
jakarta-jetspeed-2/components/registry/src/java/org/apache/jetspeed/om/portlet/impl/PortletDefinitionImpl.java
Index: PortletDefinitionImpl.java
===================================================================
RCS file:
/home/cvs/jakarta-jetspeed-2/components/registry/src/java/org/apache/jetspeed/om/portlet/impl/PortletDefinitionImpl.java,v
retrieving revision 1.26
retrieving revision 1.26.2.1
diff -u -r1.26 -r1.26.2.1
--- PortletDefinitionImpl.java 15 Oct 2004 18:44:18 -0000 1.26
+++ PortletDefinitionImpl.java 2 Mar 2005 02:35:15 -0000 1.26.2.1
@@ -31,6 +31,7 @@
import org.apache.commons.logging.LogFactory;
import org.apache.jetspeed.components.portletregistry.PortletRegistry;
import org.apache.jetspeed.components.portletregistry.RegistryException;
+import org.apache.jetspeed.factory.PortletFactory;
import org.apache.jetspeed.om.common.GenericMetadata;
import org.apache.jetspeed.om.common.MutableDescription;
import org.apache.jetspeed.om.common.MutableDisplayName;
@@ -93,6 +94,7 @@
*
*/
protected static PortletRegistry registry;
+ protected static PortletFactory portletFactory;
private long id;
private String className;
@@ -124,7 +126,6 @@
private MutablePortletApplication app;
protected long appId;
- private ClassLoader portletClassLoader;
private String expirationCache;
/** Metadata property */
@@ -288,7 +289,11 @@
*/
public ClassLoader getPortletClassLoader()
{
- return portletClassLoader;
+ if ( portletFactory != null )
+ {
+ return portletFactory.getPortletApplicationClassLoader(app);
+ }
+ return null;
}
/**
@@ -320,7 +325,8 @@
*/
public void setPortletClassLoader( ClassLoader loader )
{
- this.portletClassLoader = loader;
+ // no-op: ClassLoader is only stored in the PortletFactory
+ ;
}
/**
@@ -911,4 +917,8 @@
PortletDefinitionImpl.registry = registry;
}
-}
\ No newline at end of file
+ public static void setPortletFactory(PortletFactory portletFactory)
+ {
+ PortletDefinitionImpl.portletFactory = portletFactory;
+ }
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]