cziegeler 01/05/30 08:31:14
Modified: src/org/apache/cocoon/environment Source.java
src/org/apache/cocoon/sitemap Handler.java
Log:
Fixed sitemap regenerating bug
Revision Changes Path
1.4 +10 -1 xml-cocoon2/src/org/apache/cocoon/environment/Source.java
Index: Source.java
===================================================================
RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/environment/Source.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- Source.java 2001/05/28 10:03:47 1.3
+++ Source.java 2001/05/30 15:31:06 1.4
@@ -24,7 +24,7 @@
* for accessing any resource (URL, local file etc).
*
* @author <a href="mailto:[EMAIL PROTECTED]">Carsten Ziegeler</a>
- * @version CVS $Revision: 1.3 $ $Date: 2001/05/28 10:03:47 $
+ * @version CVS $Revision: 1.4 $ $Date: 2001/05/30 15:31:06 $
*/
public final class Source {
@@ -147,5 +147,14 @@
return null;
}
+ /**
+ * Refresh this object and update the last modified date
+ * and content length.
+ */
+ public void refresh() {
+ // reset connection
+ this.connection = null;
+ this.gotInfos = false;
+ }
}
1.6 +2 -1 xml-cocoon2/src/org/apache/cocoon/sitemap/Handler.java
Index: Handler.java
===================================================================
RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/sitemap/Handler.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- Handler.java 2001/05/25 14:25:59 1.5
+++ Handler.java 2001/05/30 15:31:11 1.6
@@ -42,7 +42,7 @@
* @author <a href="mailto:[EMAIL PROTECTED]">Carsten Ziegeler</a>
* @author <a href="mailto:[EMAIL PROTECTED]">Giacomo Pati</a>
* @author <a href="mailto:[EMAIL PROTECTED]">Stefano Mazzocchi</a>
- * @version CVS $Revision: 1.5 $ $Date: 2001/05/25 14:25:59 $
+ * @version CVS $Revision: 1.6 $ $Date: 2001/05/30 15:31:11 $
*/
public class Handler extends AbstractLoggable
implements Runnable, Configurable, Composable, Contextualizable, Processor,
Disposable {
@@ -112,6 +112,7 @@
protected boolean hasChanged () {
if (available()) {
if (check_reload) {
+ this.source.refresh();
return sitemap.modifiedSince(this.source.getLastModified());
}
return false;
----------------------------------------------------------------------
In case of troubles, e-mail: [EMAIL PROTECTED]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]