cziegeler 2004/05/24 05:42:44
Modified: src/samples/org/apache/cocoon/samples/parentcm
Generator.java
src/samples/org/apache/cocoon/acting/modular TestAction.java
Log:
Move deprecated abstract classes into "deprecated" block
Revision Changes Path
1.3 +6 -6
cocoon-2.1/src/samples/org/apache/cocoon/samples/parentcm/Generator.java
Index: Generator.java
===================================================================
RCS file:
/home/cvs/cocoon-2.1/src/samples/org/apache/cocoon/samples/parentcm/Generator.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- Generator.java 5 Mar 2004 13:03:02 -0000 1.2
+++ Generator.java 24 May 2004 12:42:44 -0000 1.3
@@ -16,11 +16,11 @@
package org.apache.cocoon.samples.parentcm;
import org.apache.avalon.excalibur.pool.Poolable;
-import org.apache.avalon.framework.component.ComponentException;
import org.apache.avalon.framework.parameters.Parameters;
+import org.apache.avalon.framework.service.ServiceException;
import org.apache.cocoon.ProcessingException;
import org.apache.cocoon.environment.SourceResolver;
-import org.apache.cocoon.generation.ComposerGenerator;
+import org.apache.cocoon.generation.ServiceableGenerator;
import org.xml.sax.SAXException;
import org.xml.sax.helpers.AttributesImpl;
@@ -37,7 +37,7 @@
* @author <a href="mailto:[EMAIL PROTECTED]">Leo Sutic</a>
* @version CVS $Id$
*/
-public class Generator extends ComposerGenerator implements Poolable {
+public class Generator extends ServiceableGenerator implements Poolable {
/**
* Current time.
@@ -52,9 +52,9 @@
Time timeGiver = null;
try {
- timeGiver = (Time) manager.lookup(Time.ROLE);
+ timeGiver = (Time) this.manager.lookup(Time.ROLE);
this.time = timeGiver.getTime ();
- } catch (ComponentException ce) {
+ } catch (ServiceException ce) {
throw new ProcessingException ("Could not obtain current time.",
ce);
} finally {
manager.release(timeGiver);
1.4 +9 -3
cocoon-2.1/src/samples/org/apache/cocoon/acting/modular/TestAction.java
Index: TestAction.java
===================================================================
RCS file:
/home/cvs/cocoon-2.1/src/samples/org/apache/cocoon/acting/modular/TestAction.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- TestAction.java 5 Mar 2004 13:03:02 -0000 1.3
+++ TestAction.java 24 May 2004 12:42:44 -0000 1.4
@@ -22,7 +22,7 @@
import org.apache.avalon.framework.configuration.ConfigurationException;
import org.apache.avalon.framework.parameters.Parameters;
import org.apache.avalon.framework.thread.ThreadSafe;
-import org.apache.cocoon.acting.ComposerAction;
+import org.apache.cocoon.acting.ServiceableAction;
import org.apache.cocoon.components.modules.input.InputModule;
import org.apache.cocoon.components.modules.output.OutputModule;
import org.apache.cocoon.environment.Redirector;
@@ -45,7 +45,7 @@
*
* @version CVS $Id$
*/
-public class TestAction extends ComposerAction
+public class TestAction extends ServiceableAction
implements Configurable, ThreadSafe {
String INPUT_MODULE_ROLE = InputModule.ROLE;
@@ -64,6 +64,9 @@
String outputHint = "request-attr"; // default to request attributes
+ /* (non-Javadoc)
+ * @see
org.apache.avalon.framework.configuration.Configurable#configure(org.apache.avalon.framework.configuration.Configuration)
+ */
public void configure(Configuration config) throws
ConfigurationException {
this.inputConf = config.getChild("input-module");
@@ -76,6 +79,9 @@
+ /* (non-Javadoc)
+ * @see
org.apache.cocoon.acting.Action#act(org.apache.cocoon.environment.Redirector,
org.apache.cocoon.environment.SourceResolver, java.util.Map, java.lang.String,
org.apache.avalon.framework.parameters.Parameters)
+ */
public Map act( Redirector redirector, SourceResolver resolver, Map
objectModel,
String source, Parameters param ) throws Exception {