ate 2005/03/23 14:53:53
Modified: portal/src/java/org/apache/jetspeed/util/descriptor
PortletApplicationWar.java
Log:
Resolving http://issues.apache.org/jira/browse/JS2-210:
portlet.xml checksum determination and handling
Revision Changes Path
1.21 +12 -2
jakarta-jetspeed-2/portal/src/java/org/apache/jetspeed/util/descriptor/PortletApplicationWar.java
Index: PortletApplicationWar.java
===================================================================
RCS file:
/home/cvs/jakarta-jetspeed-2/portal/src/java/org/apache/jetspeed/util/descriptor/PortletApplicationWar.java,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- PortletApplicationWar.java 28 Jan 2005 01:39:07 -0000 1.20
+++ PortletApplicationWar.java 23 Mar 2005 22:53:53 -0000 1.21
@@ -96,6 +96,7 @@
protected FileSystemHelper warStruct;
private MutableWebApplication webApp;
private MutablePortletApplication portletApp;
+ private long paChecksum;
protected final List openedResources;
protected static final String[] ELEMENTS_BEFORE_SERVLET = new
String[]{"icon", "display-name", "description",
@@ -124,7 +125,16 @@
this.webAppContextRoot = webAppContextRoot;
this.openedResources = new ArrayList();
this.warStruct = warStruct;
+ this.paChecksum = warStruct.getChecksum(PORTLET_XML_PATH);
+ if (paChecksum == 0)
+ {
+ throw new IOException("Cannot find required "+PORTLET_XML_PATH+"
for Portlet Application "+paName);
+ }
+ }
+ public long getPortletApplicationChecksum()
+ {
+ return paChecksum;
}
/**
@@ -239,7 +249,7 @@
extMetaDataXml.close();
}
}
-
+ portletApp.setChecksum(paChecksum);
return portletApp;
}
finally
@@ -690,4 +700,4 @@
{
return warStruct;
}
-}
\ No newline at end of file
+}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]