You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by cz...@apache.org on 2005/05/22 19:20:19 UTC
svn commit: r171346 -
/cocoon/trunk/src/java/org/apache/cocoon/sitemap/impl/AbstractVirtualSitemapComponent.java
Author: cziegeler
Date: Sun May 22 10:20:18 2005
New Revision: 171346
URL: http://svn.apache.org/viewcvs?rev=171346&view=rev
Log:
Release sources after each usage
Modified:
cocoon/trunk/src/java/org/apache/cocoon/sitemap/impl/AbstractVirtualSitemapComponent.java
Modified: cocoon/trunk/src/java/org/apache/cocoon/sitemap/impl/AbstractVirtualSitemapComponent.java
URL: http://svn.apache.org/viewcvs/cocoon/trunk/src/java/org/apache/cocoon/sitemap/impl/AbstractVirtualSitemapComponent.java?rev=171346&r1=171345&r2=171346&view=diff
==============================================================================
--- cocoon/trunk/src/java/org/apache/cocoon/sitemap/impl/AbstractVirtualSitemapComponent.java (original)
+++ cocoon/trunk/src/java/org/apache/cocoon/sitemap/impl/AbstractVirtualSitemapComponent.java Sun May 22 10:20:18 2005
@@ -15,7 +15,6 @@
*/
package org.apache.cocoon.sitemap.impl;
-import org.apache.avalon.framework.activity.Disposable;
import org.apache.avalon.framework.configuration.Configurable;
import org.apache.avalon.framework.configuration.Configuration;
import org.apache.avalon.framework.configuration.ConfigurationException;
@@ -63,7 +62,7 @@
* </ul>
*/
public abstract class AbstractVirtualSitemapComponent extends AbstractXMLPipe
- implements SitemapModelComponent, Serviceable, Disposable, Contextualizable, Configurable {
+ implements SitemapModelComponent, Serviceable, Contextualizable, Configurable {
private ProcessingNode node;
private String sourceMapName;
@@ -106,20 +105,16 @@
/**
* Release all resources.
*/
- public void dispose() {
- try {
- Iterator sources =
- this.sourceMap.values().iterator();
- while (sources.hasNext()) {
- Source source = (Source)sources.next();
- // FIXME
- // These are allready disposed, why?
- //this.resolver.release(source);
- }
- } catch (Exception e) {
- throw new RuntimeException("Could not dispose sources", e);
+ public void recycle() {
+ Iterator sources = this.sourceMap.values().iterator();
+ while (sources.hasNext()) {
+ Source source = (Source)sources.next();
+ // FIXME
+ // These are allready disposed, why?
+ //this.resolver.release(source);
}
- this.manager = null;
+ this.sourceMap.clear();
+ super.recycle();
}
/**