cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: xml-cocoon2/src/org/apache/cocoon/environment/http HttpEnvironment.java
Date Tue, 05 Jun 2001 21:36:24 GMT
dims        01/06/05 14:36:24

  Modified:    src/org/apache/cocoon/acting Action.java
                        DatabaseAddAction.java
                        DatabaseAuthenticatorAction.java
                        DatabaseDeleteAction.java DatabaseUpdateAction.java
                        FormValidatorAction.java HelloAction.java
                        LangSelect.java OraAddAction.java
                        ResourceExistsAction.java SendmailAction.java
                        SessionInvalidatorAction.java
                        SessionPropagatorAction.java
                        SessionValidatorAction.java
               src/org/apache/cocoon/components/language/markup/sitemap/java
                        sitemap.xsl
               src/org/apache/cocoon/environment/http HttpEnvironment.java
  Added:       src/org/apache/cocoon/environment Redirector.java
  Log:
  - Added Redirector interface as per Giacomo's email
  - Modified act method in Action interface to include a new parameter.
  
  Revision  Changes    Path
  1.3       +3 -2      xml-cocoon2/src/org/apache/cocoon/acting/Action.java
  
  Index: Action.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/Action.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- Action.java	2001/05/22 14:30:42	1.2
  +++ Action.java	2001/06/05 21:36:20	1.3
  @@ -11,13 +11,14 @@
   import org.apache.avalon.framework.component.Component;
   import org.apache.avalon.framework.parameters.Parameters;
   import org.apache.avalon.framework.thread.ThreadSafe;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.SourceResolver;
   import org.xml.sax.SAXException;
   
   /**
    *
    * @author <a href="mailto:Giacomo.Pati@pwr.ch">Giacomo Pati</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:30:42 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:20 $
    */
   public interface Action extends Component, ThreadSafe {
       /**
  @@ -45,7 +46,7 @@
        *                    be skipped.
        * @exception Exception Indicates something is totally wrong
        */
  -    Map act(SourceResolver resolver, Map objectModel, String source, Parameters par)
  +    Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String source,
Parameters par)
       throws Exception;
   }
   
  
  
  
  1.6       +3 -2      xml-cocoon2/src/org/apache/cocoon/acting/DatabaseAddAction.java
  
  Index: DatabaseAddAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/DatabaseAddAction.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- DatabaseAddAction.java	2001/05/23 03:51:43	1.5
  +++ DatabaseAddAction.java	2001/06/05 21:36:20	1.6
  @@ -30,6 +30,7 @@
   import org.apache.cocoon.ProcessingException;
   import org.apache.cocoon.Roles;
   import org.apache.cocoon.environment.Request;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.SourceResolver;
   import org.apache.cocoon.generation.ImageDirectoryGenerator;
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -43,7 +44,7 @@
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
    * @author <a href="mailto:balld@apache.org">Donald Ball</a>
  - * @version CVS $Revision: 1.5 $ $Date: 2001/05/23 03:51:43 $
  + * @version CVS $Revision: 1.6 $ $Date: 2001/06/05 21:36:20 $
    */
   public class DatabaseAddAction extends AbstractDatabaseAction {
       protected static final Map addStatements = new HashMap();
  @@ -54,7 +55,7 @@
        * the file referenced by the "form-descriptor" parameter conforms
        * to the AbstractDatabaseAction specifications.
        */
  -    public Map act(SourceResolver resolver, Map objectModel, String source, Parameters
param) throws Exception {
  +    public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String
source, Parameters param) throws Exception {
           DataSourceComponent datasource = null;
           Connection conn = null;
           Map results = new HashMap();
  
  
  
  1.3       +5 -4      xml-cocoon2/src/org/apache/cocoon/acting/DatabaseAuthenticatorAction.java
  
  Index: DatabaseAuthenticatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/DatabaseAuthenticatorAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DatabaseAuthenticatorAction.java	2001/05/22 14:30:47	1.2
  +++ DatabaseAuthenticatorAction.java	2001/06/05 21:36:20	1.3
  @@ -1,4 +1,4 @@
  -// $Id: DatabaseAuthenticatorAction.java,v 1.2 2001/05/22 14:30:47 cziegeler Exp $
  +// $Id: DatabaseAuthenticatorAction.java,v 1.3 2001/06/05 21:36:20 dims Exp $
   package org.apache.cocoon.acting;
   
   import java.sql.Connection;
  @@ -13,6 +13,7 @@
   import org.apache.cocoon.Constants;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.Session;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.SourceResolver;
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
   import org.apache.log.Logger;
  @@ -50,14 +51,14 @@
    * not verified.
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:30:47 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:20 $
    */
   public class DatabaseAuthenticatorAction extends AbstractDatabaseAction
   {
       /**
        * Main invocation routine.
        */
  -    public Map act (SourceResolver resolver, Map objectModel, String src,
  +    public Map act (Redirector redirector, SourceResolver resolver, Map objectModel, String
src,
               Parameters parameters) throws Exception {
           DataSourceComponent datasource = null;
           Connection conn = null;
  @@ -223,5 +224,5 @@
       }
   }
   
  -// $Id: DatabaseAuthenticatorAction.java,v 1.2 2001/05/22 14:30:47 cziegeler Exp $
  +// $Id: DatabaseAuthenticatorAction.java,v 1.3 2001/06/05 21:36:20 dims Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.3       +3 -2      xml-cocoon2/src/org/apache/cocoon/acting/DatabaseDeleteAction.java
  
  Index: DatabaseDeleteAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/DatabaseDeleteAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DatabaseDeleteAction.java	2001/05/22 14:30:50	1.2
  +++ DatabaseDeleteAction.java	2001/06/05 21:36:20	1.3
  @@ -26,6 +26,7 @@
   import org.apache.cocoon.ProcessingException;
   import org.apache.cocoon.Roles;
   import org.apache.cocoon.environment.Request;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.SourceResolver;
   import org.apache.cocoon.generation.ImageDirectoryGenerator;
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -38,7 +39,7 @@
    * the keys.
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:30:50 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:20 $
    */
   public final class DatabaseDeleteAction extends AbstractDatabaseAction {
       private static final Map deleteStatements = new HashMap();
  @@ -48,7 +49,7 @@
        * the file referenced by the "form-descriptor" parameter conforms
        * to the AbstractDatabaseAction specifications.
        */
  -    public final Map act(SourceResolver resolver, Map objectModel, String source, Parameters
param) throws Exception {
  +    public final Map act(Redirector redirector, SourceResolver resolver, Map objectModel,
String source, Parameters param) throws Exception {
           DataSourceComponent datasource = null;
           Connection conn = null;
           int currentIndex = 0;
  
  
  
  1.3       +3 -2      xml-cocoon2/src/org/apache/cocoon/acting/DatabaseUpdateAction.java
  
  Index: DatabaseUpdateAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/DatabaseUpdateAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DatabaseUpdateAction.java	2001/05/22 14:30:53	1.2
  +++ DatabaseUpdateAction.java	2001/06/05 21:36:20	1.3
  @@ -26,6 +26,7 @@
   import org.apache.cocoon.ProcessingException;
   import org.apache.cocoon.Roles;
   import org.apache.cocoon.environment.Request;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.SourceResolver;
   import org.apache.cocoon.generation.ImageDirectoryGenerator;
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -35,7 +36,7 @@
    * only one table at a time to update.
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:30:53 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:20 $
    */
   public class DatabaseUpdateAction extends AbstractDatabaseAction {
       private static final Map updateStatements = new HashMap();
  @@ -45,7 +46,7 @@
        * the file referenced by the "form-descriptor" parameter conforms
        * to the AbstractDatabaseAction specifications.
        */
  -    public Map act(SourceResolver resolver, Map objectModel, String source, Parameters
param) throws Exception {
  +    public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String
source, Parameters param) throws Exception {
           DataSourceComponent datasource = null;
           Connection conn = null;
           int currentIndex = 0;
  
  
  
  1.4       +5 -4      xml-cocoon2/src/org/apache/cocoon/acting/FormValidatorAction.java
  
  Index: FormValidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/FormValidatorAction.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- FormValidatorAction.java	2001/05/22 14:30:57	1.3
  +++ FormValidatorAction.java	2001/06/05 21:36:20	1.4
  @@ -1,4 +1,4 @@
  -// $Id: FormValidatorAction.java,v 1.3 2001/05/22 14:30:57 cziegeler Exp $
  +// $Id: FormValidatorAction.java,v 1.4 2001/06/05 21:36:20 dims Exp $
   package org.apache.cocoon.acting;
   
   import java.util.Collections;
  @@ -9,6 +9,7 @@
   import org.apache.avalon.framework.parameters.Parameters;
   import org.apache.cocoon.Constants;
   import org.apache.cocoon.environment.Request;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.SourceResolver;
   import org.apache.cocoon.util.Tokenizer;
   import org.apache.log.Logger;
  @@ -49,14 +50,14 @@
    * all validated parameters to the sitemap via {name} expression.
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.3 $ $Date: 2001/05/22 14:30:57 $
  + * @version CVS $Revision: 1.4 $ $Date: 2001/06/05 21:36:20 $
    */
   public class FormValidatorAction extends AbstractValidatorAction
   {
       /**
        * Main invocation routine.
        */
  -    public Map act (SourceResolver resolver, Map objectModel, String src,
  +    public Map act (Redirector redirector, SourceResolver resolver, Map objectModel, String
src,
               Parameters parameters) throws Exception {
           Request req = (Request)
               objectModel.get (Constants.REQUEST_OBJECT);
  @@ -178,5 +179,5 @@
       }
   }
   
  -// $Id: FormValidatorAction.java,v 1.3 2001/05/22 14:30:57 cziegeler Exp $
  +// $Id: FormValidatorAction.java,v 1.4 2001/06/05 21:36:20 dims Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.3       +3 -2      xml-cocoon2/src/org/apache/cocoon/acting/HelloAction.java
  
  Index: HelloAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/HelloAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- HelloAction.java	2001/05/22 14:31:01	1.2
  +++ HelloAction.java	2001/06/05 21:36:20	1.3
  @@ -15,6 +15,7 @@
   import org.apache.cocoon.Constants;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.Session;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.SourceResolver;
   
   /**
  @@ -22,7 +23,7 @@
    * has been created or not.
    *
    * @author <a href="mailto:Giacomo.Pati@pwr.ch">Giacomo Pati</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:31:01 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:20 $
    */
   public class HelloAction extends ComposerAction {
   
  @@ -30,7 +31,7 @@
        * A simple Action that logs if the <code>Session</code> object
        * has been created
        */
  -    public Map act (SourceResolver resolver, Map objectModel, String src, Parameters par)
throws Exception {
  +    public Map act (Redirector redirector, SourceResolver resolver, Map objectModel, String
src, Parameters par) throws Exception {
           Request request = (Request) objectModel.get(Constants.REQUEST_OBJECT);
           if (request != null) {
               Session session = request.getSession (false);
  
  
  
  1.4       +2 -1      xml-cocoon2/src/org/apache/cocoon/acting/LangSelect.java
  
  Index: LangSelect.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/LangSelect.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- LangSelect.java	2001/06/01 16:14:55	1.3
  +++ LangSelect.java	2001/06/05 21:36:20	1.4
  @@ -21,6 +21,7 @@
   import org.apache.cocoon.Constants;
   import org.apache.cocoon.acting.Action;
   import org.apache.cocoon.environment.Cookie;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.Response;
   import org.apache.cocoon.environment.Session;
  @@ -119,7 +120,7 @@
        * Puts lang parameter to session and to objectModel
        * if it is not already there.
        */
  -    public Map act(SourceResolver resolver, Map objectModel, String source,
  +    public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String
source,
               Parameters par) throws Exception {
   
           String lang;
  
  
  
  1.3       +3 -2      xml-cocoon2/src/org/apache/cocoon/acting/OraAddAction.java
  
  Index: OraAddAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/OraAddAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- OraAddAction.java	2001/05/22 14:31:08	1.2
  +++ OraAddAction.java	2001/06/05 21:36:21	1.3
  @@ -29,6 +29,7 @@
   import org.apache.avalon.framework.parameters.Parameters;
   import org.apache.cocoon.Constants;
   import org.apache.cocoon.ProcessingException;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.SourceResolver;
   import org.apache.cocoon.generation.ImageDirectoryGenerator;
  @@ -39,7 +40,7 @@
    * only one table at a time to update.
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:31:08 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:21 $
    */
   public class OraAddAction extends DatabaseAddAction {
       private static final Map selectLOBStatements = new HashMap();
  @@ -49,7 +50,7 @@
        * the file referenced by the "form-descriptor" parameter conforms
        * to the AbstractDatabaseAction specifications.
        */
  -    public Map act(SourceResolver resolver, Map objectModel, String source, Parameters
param) throws Exception {
  +    public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String
source, Parameters param) throws Exception {
           DataSourceComponent datasource = null;
           Connection conn = null;
           int currentIndex = 0;
  
  
  
  1.5       +3 -2      xml-cocoon2/src/org/apache/cocoon/acting/ResourceExistsAction.java
  
  Index: ResourceExistsAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/ResourceExistsAction.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- ResourceExistsAction.java	2001/05/31 17:37:39	1.4
  +++ ResourceExistsAction.java	2001/06/05 21:36:21	1.5
  @@ -24,6 +24,7 @@
   import org.apache.cocoon.ProcessingException;
   import org.apache.cocoon.Roles;
   import org.apache.cocoon.components.url.URLFactory;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.SourceResolver;
   import org.xml.sax.InputSource;
  @@ -34,11 +35,11 @@
    * null otherwise. It has only been tested with context urls.
    *
    * @author <a href="mailto:balld@apache.org">Donald Ball</a>
  - * @version CVS $Revision: 1.4 $ $Date: 2001/05/31 17:37:39 $
  + * @version CVS $Revision: 1.5 $ $Date: 2001/06/05 21:36:21 $
    */
   public class ResourceExistsAction extends ComposerAction {
   
  -    public Map act(SourceResolver resolver, Map objectModel, String source, Parameters
parameters) throws Exception {
  +    public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String
source, Parameters parameters) throws Exception {
           HashMap results = new HashMap();
           String urlstring = parameters.getParameter("url",null);
           try {
  
  
  
  1.3       +2 -1      xml-cocoon2/src/org/apache/cocoon/acting/SendmailAction.java
  
  Index: SendmailAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/SendmailAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- SendmailAction.java	2001/05/22 14:31:13	1.2
  +++ SendmailAction.java	2001/06/05 21:36:21	1.3
  @@ -24,6 +24,7 @@
   import org.apache.avalon.framework.configuration.ConfigurationException;
   import org.apache.avalon.framework.parameters.Parameters;
   import org.apache.cocoon.Constants;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.SourceResolver;
   import org.apache.log.Logger;
  @@ -69,7 +70,7 @@
       getLogger().debug("SendmailAction: using "+default_properties.get("mail.smtp.host")+"
as the smtp server");
     }
   
  -  public Map act(SourceResolver resolver, Map objectModel, String source, Parameters parameters)
throws Exception {
  +  public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String
source, Parameters parameters) throws Exception {
       HashMap results = new HashMap();
       try {
         getLogger().debug("SendmailAction: act start");
  
  
  
  1.3       +5 -4      xml-cocoon2/src/org/apache/cocoon/acting/SessionInvalidatorAction.java
  
  Index: SessionInvalidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/SessionInvalidatorAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- SessionInvalidatorAction.java	2001/05/22 14:31:16	1.2
  +++ SessionInvalidatorAction.java	2001/06/05 21:36:21	1.3
  @@ -1,4 +1,4 @@
  -// $Id: SessionInvalidatorAction.java,v 1.2 2001/05/22 14:31:16 cziegeler Exp $
  +// $Id: SessionInvalidatorAction.java,v 1.3 2001/06/05 21:36:21 dims Exp $
   package org.apache.cocoon.acting;
   
   import java.util.Collections;
  @@ -7,6 +7,7 @@
   import org.apache.avalon.framework.logger.AbstractLoggable;
   import org.apache.avalon.framework.parameters.Parameters;
   import org.apache.cocoon.Constants;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.Session;
   import org.apache.cocoon.environment.SourceResolver;
  @@ -17,14 +18,14 @@
    * empty map if everything is ok, null otherwise.
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:31:16 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:21 $
    */
   public class SessionInvalidatorAction extends AbstractAction
   {
       /**
        * Main invocation routine.
        */
  -    public Map act (SourceResolver resolver, Map objectModel, String src,
  +    public Map act (Redirector redirector, SourceResolver resolver, Map objectModel, String
src,
               Parameters parameters) throws Exception {
           Request req = (Request)
               objectModel.get (Constants.REQUEST_OBJECT);
  @@ -49,5 +50,5 @@
       }
   }
   
  -// $Id: SessionInvalidatorAction.java,v 1.2 2001/05/22 14:31:16 cziegeler Exp $
  +// $Id: SessionInvalidatorAction.java,v 1.3 2001/06/05 21:36:21 dims Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.3       +5 -4      xml-cocoon2/src/org/apache/cocoon/acting/SessionPropagatorAction.java
  
  Index: SessionPropagatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/SessionPropagatorAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- SessionPropagatorAction.java	2001/05/22 14:31:19	1.2
  +++ SessionPropagatorAction.java	2001/06/05 21:36:21	1.3
  @@ -1,4 +1,4 @@
  -// $Id: SessionPropagatorAction.java,v 1.2 2001/05/22 14:31:19 cziegeler Exp $
  +// $Id: SessionPropagatorAction.java,v 1.3 2001/06/05 21:36:21 dims Exp $
   package org.apache.cocoon.acting;
   
   import java.util.Collections;
  @@ -8,6 +8,7 @@
   import org.apache.avalon.framework.logger.AbstractLoggable;
   import org.apache.avalon.framework.parameters.Parameters;
   import org.apache.cocoon.Constants;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.Session;
   import org.apache.cocoon.environment.SourceResolver;
  @@ -27,14 +28,14 @@
    * </pre>
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:31:19 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:21 $
    */
   public class SessionPropagatorAction extends ComposerAction
   {
       /**
        * Main invocation routine.
        */
  -    public Map act (SourceResolver resolver, Map objectModel, String src,
  +    public Map act (Redirector redirector, SourceResolver resolver, Map objectModel, String
src,
               Parameters parameters) throws Exception {
           Request req = (Request)
               objectModel.get (Constants.REQUEST_OBJECT);
  @@ -77,6 +78,6 @@
       }
   }
   
  -// $Id: SessionPropagatorAction.java,v 1.2 2001/05/22 14:31:19 cziegeler Exp $
  +// $Id: SessionPropagatorAction.java,v 1.3 2001/06/05 21:36:21 dims Exp $
   // vim: set et ts=4 sw=4:
   
  
  
  
  1.3       +5 -4      xml-cocoon2/src/org/apache/cocoon/acting/SessionValidatorAction.java
  
  Index: SessionValidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/SessionValidatorAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- SessionValidatorAction.java	2001/05/22 14:31:24	1.2
  +++ SessionValidatorAction.java	2001/06/05 21:36:21	1.3
  @@ -1,4 +1,4 @@
  -// $Id: SessionValidatorAction.java,v 1.2 2001/05/22 14:31:24 cziegeler Exp $
  +// $Id: SessionValidatorAction.java,v 1.3 2001/06/05 21:36:21 dims Exp $
   package org.apache.cocoon.acting;
   
   import java.util.Collections;
  @@ -8,6 +8,7 @@
   import org.apache.avalon.framework.logger.AbstractLoggable;
   import org.apache.avalon.framework.parameters.Parameters;
   import org.apache.cocoon.Constants;
  +import org.apache.cocoon.environment.Redirector;
   import org.apache.cocoon.environment.Request;
   import org.apache.cocoon.environment.Session;
   import org.apache.cocoon.environment.SourceResolver;
  @@ -51,14 +52,14 @@
    * all validated parameters to the sitemap via {name} expression.
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.2 $ $Date: 2001/05/22 14:31:24 $
  + * @version CVS $Revision: 1.3 $ $Date: 2001/06/05 21:36:21 $
    */
   public class SessionValidatorAction extends AbstractValidatorAction
   {
       /**
        * Main invocation routine.
        */
  -    public Map act (SourceResolver resolver, Map objectModel, String src,
  +    public Map act (Redirector redirector, SourceResolver resolver, Map objectModel, String
src,
               Parameters parameters) throws Exception {
           Request req = (Request)
               objectModel.get (Constants.REQUEST_OBJECT);
  @@ -188,5 +189,5 @@
       }
   }
   
  -// $Id: SessionValidatorAction.java,v 1.2 2001/05/22 14:31:24 cziegeler Exp $
  +// $Id: SessionValidatorAction.java,v 1.3 2001/06/05 21:36:21 dims Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.11      +6 -5      xml-cocoon2/src/org/apache/cocoon/components/language/markup/sitemap/java/sitemap.xsl
  
  Index: sitemap.xsl
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/components/language/markup/sitemap/java/sitemap.xsl,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- sitemap.xsl	2001/05/25 19:00:47	1.10
  +++ sitemap.xsl	2001/06/05 21:36:23	1.11
  @@ -82,6 +82,7 @@
       import org.apache.cocoon.ConnectionResetException;
       import org.apache.cocoon.acting.Action;
       import org.apache.cocoon.environment.Environment;
  +    import org.apache.cocoon.environment.Redirector;
       import org.apache.cocoon.matching.Matcher;
       import org.apache.cocoon.selection.Selector;
       import org.apache.cocoon.sitemap.AbstractSitemap;
  @@ -99,7 +100,7 @@
        *
        * @author &lt;a href="mailto:giacomo@apache.org"&gt;Giacomo Pati&lt;/a&gt;
        * @author &lt;a href="mailto:bloritsch@apache.org"&gt;Berin Loritsch&lt;/a&gt;
  -     * @version CVS $Id: sitemap.xsl,v 1.10 2001/05/25 19:00:47 giacomo Exp $
  +     * @version CVS $Id: sitemap.xsl,v 1.11 2001/06/05 21:36:23 dims Exp $
        */
       public class <xsl:value-of select="@file-name"/> extends AbstractSitemap {
         static final String LOCATION = "<xsl:value-of select="translate(@file-path, '/',
'.')"/>.<xsl:value-of select="@file-name"/>";
  @@ -758,7 +759,7 @@
       <!-- generate the invocation of the act method of the action component -->
       <xsl:choose>
         <xsl:when test="./*[namespace-uri()='http://apache.org/cocoon/sitemap/1.0' and
local-name() != 'parameter']">
  -        if ((map = <xsl:value-of select="$action-name"/> (environment, objectModel,
substitute(listOfMaps,<xsl:value-of select="$action-source"/>), <xsl:value-of select="$component-param"/>))
!= null) {
  +        if ((map = <xsl:value-of select="$action-name"/> ((Redirector)environment,
environment, objectModel, substitute(listOfMaps,<xsl:value-of select="$action-source"/>),
<xsl:value-of select="$component-param"/>)) != null) {
            getLogger().debug("Action <xsl:value-of select="translate($action-name,'&quot;','
')"/>");
             listOfMaps.add (map);
             <xsl:apply-templates/>
  @@ -766,7 +767,7 @@
           }
         </xsl:when>
         <xsl:otherwise>
  -        map = <xsl:value-of select="$action-name"/> (environment, objectModel, substitute(listOfMaps,<xsl:value-of
select="$action-source"/>), <xsl:value-of select="$component-param"/>);
  +        map = <xsl:value-of select="$action-name"/> ((Redirector)environment, environment,
objectModel, substitute(listOfMaps,<xsl:value-of select="$action-source"/>), <xsl:value-of
select="$component-param"/>);
         </xsl:otherwise>
       </xsl:choose>
     </xsl:template> <!-- match="map:act[@type]" -->
  @@ -811,7 +812,7 @@
       <!-- generate the invocation of the act method of the action component -->
       <xsl:choose>
         <xsl:when test="./*[namespace-uri()='http://apache.org/cocoon/sitemap/1.0' and
local-name() != 'parameter']">
  -        if ((map = <xsl:value-of select="$action-name"/> (environment, objectModel,
substitute(listOfMaps,<xsl:value-of select="$action-source"/>), <xsl:value-of select="$component-param"/>))
!= null) {
  +        if ((map = <xsl:value-of select="$action-name"/> ((Redirector)environment,
environment, objectModel, substitute(listOfMaps,<xsl:value-of select="$action-source"/>),
<xsl:value-of select="$component-param"/>)) != null) {
            getLogger().debug("Action <xsl:value-of select="translate($action-name,'&quot;','
')"/>");
             listOfMaps.add (map);
             <xsl:apply-templates/>
  @@ -819,7 +820,7 @@
           }
         </xsl:when>
         <xsl:otherwise>
  -        map = <xsl:value-of select="$action-name"/> (environment, objectModel, substitute(listOfMaps,<xsl:value-of
select="$action-source"/>), <xsl:value-of select="$component-param"/>);
  +        map = <xsl:value-of select="$action-name"/> ((Redirector)environment, environment,
objectModel, substitute(listOfMaps,<xsl:value-of select="$action-source"/>), <xsl:value-of
select="$component-param"/>);
         </xsl:otherwise>
       </xsl:choose>
     </xsl:template> <!-- match="map:act[@type]" mode="set" -->
  
  
  
  1.1                  xml-cocoon2/src/org/apache/cocoon/environment/Redirector.java
  
  Index: Redirector.java
  ===================================================================
  /*****************************************************************************
   * Copyright (C) The Apache Software Foundation. All rights reserved.        *
   * ------------------------------------------------------------------------- *
   * This software is published under the terms of the Apache Software License *
   * version 1.1, a copy of which has been included  with this distribution in *
   * the LICENSE file.                                                         *
   *****************************************************************************/
  
  package org.apache.cocoon.environment;
  
  import java.io.IOException;
  
  /**
   * Interface for an redirector abstraction
   *
   * @author <a href="mailto:dims@yahoo.com">Davanum Srinivas</a>
   * @version CVS $Revision: 1.1 $ $Date: 2001/06/05 21:36:24 $
   */
  
  public interface Redirector {
  
      /**
       * Redirect to the given URL
       */
      void redirect(boolean sessionmode, String url) throws IOException;
  }
  
  
  
  
  1.4       +2 -1      xml-cocoon2/src/org/apache/cocoon/environment/http/HttpEnvironment.java
  
  Index: HttpEnvironment.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/environment/http/HttpEnvironment.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- HttpEnvironment.java	2001/05/31 15:31:29	1.3
  +++ HttpEnvironment.java	2001/06/05 21:36:24	1.4
  @@ -20,10 +20,11 @@
   import org.apache.cocoon.Constants;
   import org.apache.cocoon.environment.AbstractEnvironment;
   import org.apache.cocoon.environment.Session;
  +import org.apache.cocoon.environment.Redirector;
   import org.xml.sax.InputSource;
   import org.xml.sax.SAXException;
   
  -public class HttpEnvironment extends AbstractEnvironment {
  +public class HttpEnvironment extends AbstractEnvironment implements Redirector {
   
       public static final String HTTP_REQUEST_OBJECT = "httprequest";
       public static final String HTTP_RESPONSE_OBJECT= "httpresponse";
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          cocoon-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-cvs-help@xml.apache.org


Mime
View raw message