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 2002/02/04 10:12:51 UTC

cvs commit: xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess AbstractAttributeHelper.java AbstractAutoIncrementHelper.java AbstractOutputHelper.java AttributeHelper.java AutoIncrementHelper.java HsqlIdentityAutoIncrementHelper.java IfxSerialAutoIncrementHelper.java ManualAutoIncrementHelper.java MysqlAutoIncrementHelper.java OutputHelper.java RequestAttributeHelper.java RequestAttributeOutputHelper.java RequestParameterHelper.java

cziegeler    02/02/04 01:12:50

  Modified:    src/java/org/apache/cocoon/acting AbstractAction.java
                        AbstractComplementaryConfigurableAction.java
                        AbstractConfigurableAction.java
                        AbstractDatabaseAction.java
                        AbstractValidatorAction.java Action.java
                        ComposerAction.java ConfigurableComposerAction.java
                        ConfigurationHelper.java DatabaseAddAction.java
                        DatabaseAuthenticatorAction.java
                        DatabaseDeleteAction.java DatabaseSelectAction.java
                        DatabaseUpdateAction.java FormValidatorAction.java
                        HelloAction.java HttpHeaderAction.java
                        LangSelect.java LocaleAction.java OraAddAction.java
                        OraUpdateAction.java RequestParamAction.java
                        RequestParameterExistsAction.java
                        ResourceExistsAction.java ScriptAction.java
                        SendmailAction.java ServerPagesAction.java
                        SessionInvalidatorAction.java
                        SessionIsValidAction.java
                        SessionPropagatorAction.java
                        SessionStateAction.java SessionValidatorAction.java
                        ValidatorActionHelper.java
                        ValidatorActionResult.java
               src/java/org/apache/cocoon/caching
                        AggregatedCacheValidity.java CacheValidity.java
                        Cacheable.java CachedEventObject.java
                        CachedStreamObject.java CachingOutputStream.java
                        ComponentCacheKey.java CompositeCacheValidity.java
                        DeltaTimeCacheValidity.java
                        IncludeCacheValidity.java NOPCacheValidity.java
                        ParametersCacheValidity.java PipelineCacheKey.java
                        TimeStampCacheValidity.java
               src/scratchpad/src/org/apache/cocoon/acting
                        CookieCreatorAction.java CookieValidatorAction.java
                        DatabaseCookieAuthenticatorAction.java
                        ModularDatabaseAction.java
                        ModularDatabaseAddAction.java
                        ModularDatabaseDeleteAction.java
                        ModularDatabaseSelectAction.java
                        ModularDatabaseUpdateAction.java
                        SectionCutterAction.java
               src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess
                        AbstractAttributeHelper.java
                        AbstractAutoIncrementHelper.java
                        AbstractOutputHelper.java AttributeHelper.java
                        AutoIncrementHelper.java
                        HsqlIdentityAutoIncrementHelper.java
                        IfxSerialAutoIncrementHelper.java
                        ManualAutoIncrementHelper.java
                        MysqlAutoIncrementHelper.java OutputHelper.java
                        RequestAttributeHelper.java
                        RequestAttributeOutputHelper.java
                        RequestParameterHelper.java
  Log:
  Long licence
  
  Revision  Changes    Path
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractAction.java
  
  Index: AbstractAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ AbstractAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.logger.AbstractLoggable;
  @@ -19,7 +67,7 @@
    *
    * @author <a href="mailto:Giacomo.Pati@pwr.ch">Giacomo Pati</a>
    * @author <a href="mailto:haul@informatik.tu-darmstadt.de">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public abstract class AbstractAction extends AbstractLoggable
   implements Action {
  
  
  
  1.3       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractComplementaryConfigurableAction.java
  
  Index: AbstractComplementaryConfigurableAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractComplementaryConfigurableAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- AbstractComplementaryConfigurableAction.java	1 Feb 2002 15:48:08 -0000	1.2
  +++ AbstractComplementaryConfigurableAction.java	4 Feb 2002 09:12:47 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.component.Component;
  @@ -28,7 +76,7 @@
    * effective.  The name of the root configuration element is irrelevant.
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2002/02/01 15:48:08 $
  + * @version CVS $Revision: 1.3 $ $Date: 2002/02/04 09:12:47 $
    */
   public abstract class AbstractComplementaryConfigurableAction extends ConfigurableComposerAction {
       private static Map configurations = new HashMap();
  
  
  
  1.2       +67 -19    xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractConfigurableAction.java
  
  Index: AbstractConfigurableAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractConfigurableAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractConfigurableAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ AbstractConfigurableAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configurable;
  @@ -17,7 +65,7 @@
    * deploying more Actions that take default parameters.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $ */
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $ */
   public abstract class AbstractConfigurableAction extends AbstractAction implements Configurable {
   
       /**
  @@ -38,17 +86,17 @@
        */
       public void configure(Configuration conf) throws ConfigurationException {
           if (conf != null) {
  -    	    String key = null;
  -    	    String val = null;
  -    	    Configuration[] parameters = conf.getChildren();
  -    	    this.settings = new HashMap(parameters.length);
  -    	    for ( int i = 0; i < parameters.length; i++) {
  -    		    key = parameters[i].getName();
  -    		    val = parameters[i].getValue(null);
  -    		    if ( key != null )
  -    		        this.settings.put(key, val);
  -    	    }
  -    	}
  +            String key = null;
  +            String val = null;
  +            Configuration[] parameters = conf.getChildren();
  +            this.settings = new HashMap(parameters.length);
  +            for ( int i = 0; i < parameters.length; i++) {
  +                key = parameters[i].getName();
  +                val = parameters[i].getValue(null);
  +                if ( key != null )
  +                    this.settings.put(key, val);
  +            }
  +        }
       }
   
   }
  
  
  
  1.2       +68 -20    xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractDatabaseAction.java
  
  Index: AbstractDatabaseAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractDatabaseAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractDatabaseAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ AbstractDatabaseAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -147,7 +195,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.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public abstract class AbstractDatabaseAction extends AbstractComplementaryConfigurableAction implements Configurable, Disposable {
       protected Map files = new HashMap();
  @@ -280,12 +328,12 @@
               case Types.CHAR:
                   value = new Integer(set.getInt(dbcol));
                   break;
  -	    case Types.STRUCT:
  -		value = (Struct) set.getObject(dbcol);
  -		break;
  -	    case Types.OTHER:
  -		value = set.getObject(dbcol);
  -		break;
  +        case Types.STRUCT:
  +        value = (Struct) set.getObject(dbcol);
  +        break;
  +        case Types.OTHER:
  +        value = set.getObject(dbcol);
  +        break;
   
               default:
                   // The blob types have to be requested separately, via a Reader.
  @@ -523,14 +571,14 @@
   
                   statement.setTimestamp(position, ts);
                   break;
  -	    case Types.ARRAY:
  -		statement.setArray(position, (Array) value); // no way to convert string to array
  -		break;
  -	    case Types.STRUCT:
  +        case Types.ARRAY:
  +        statement.setArray(position, (Array) value); // no way to convert string to array
  +        break;
  +        case Types.STRUCT:
               case Types.OTHER:
  -		statement.setObject(position, value);
  +        statement.setObject(position, value);
                   break;
  -	    case Types.LONGVARBINARY:
  +        case Types.LONGVARBINARY:
                   statement.setTimestamp(position, new Timestamp((new java.util.Date()).getTime()));
               case Types.VARCHAR:
                   if ("string".equals(typeName)) {
  
  
  
  1.2       +72 -18    xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractValidatorAction.java
  
  Index: AbstractValidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/AbstractValidatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractValidatorAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ AbstractValidatorAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,4 +1,58 @@
  -// $Id: AbstractValidatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configurable;
  @@ -41,7 +95,7 @@
   *         &lt;constraint-set name="new-passwords-match"&gt;
   *                 &lt;validate name="oldpassword"/&gt;
   *                 &lt;validate name="newpassword"/&gt;
  -*                 &lt;validate name="renewpassword" 
  +*                 &lt;validate name="renewpassword"
   *                         equals-to-param="newpass"/&gt;
   *         &lt;/constraint-set&gt;
    * &lt;/root&gt;
  @@ -84,7 +138,7 @@
   * Constraints can be defined globally for a parameter and can be overridden
   * by redefinition in a constraint-set. Thus if e.g. a database field can take
   * at maximum 200 character, this property can be set globally.
  -* 
  +*
   *
   * <h3>The attributes recognized in "constraint-set"</h3>
   * <table>
  @@ -97,7 +151,7 @@
   * </table>
   * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
   * @author <a href="mailto:haul@informatik.tu-darmstadt.de">Christian Haul</a>
  -* @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  +* @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
   */
   public abstract class AbstractValidatorAction
   extends AbstractComplementaryConfigurableAction
  @@ -116,7 +170,7 @@
        * regular instance of java.lang.Double, java.lang.Long, etc.
        * @return The validated parameter.
        */
  -    public ValidatorActionHelper validateParameter (String name, Configuration constraints, 
  +    public ValidatorActionHelper validateParameter (String name, Configuration constraints,
               Configuration[] conf, Map params, boolean is_string) {
           String type = null;
           int i = 0;
  @@ -151,13 +205,13 @@
            * Validation phase
            */
           if ("string".equals (type)) {
  -            return validateString (name, constraints, 
  +            return validateString (name, constraints,
                       conf[i],params, is_string);
           } else if ("long".equals (type)) {
  -            return validateLong (name, constraints, 
  +            return validateLong (name, constraints,
                       conf[i], params, is_string);
           } else if ("double".equals (type)) {
  -            return validateDouble (name, constraints, 
  +            return validateDouble (name, constraints,
                       conf[i], params, is_string);
           } else {
               getLogger().debug ("VALIDATOR: unknown type " + type
  @@ -184,9 +238,9 @@
               getLogger().debug ("VALIDATOR: string parameter "
                       + name + " is null");
               if ( !nullable ) {
  -                return new ValidatorActionHelper ( value, 
  +                return new ValidatorActionHelper ( value,
                           ValidatorActionResult.ISNULL );
  -            } else { 
  +            } else {
                   value = dflt;
                   return new ValidatorActionHelper (value);
               }
  @@ -292,7 +346,7 @@
               getLogger().debug ("VALIDATOR: long parameter "
                       + name + " is null");
               if (!nullable) {
  -                return new ValidatorActionHelper ( value, 
  +                return new ValidatorActionHelper ( value,
                           ValidatorActionResult.ISNULL);
               } else {
                   value = dflt;
  @@ -326,7 +380,7 @@
               if (!"".equals (eqp)) {
                   getLogger().debug ("VALIDATOR: long parameter "
                           + name + " should be equal to " + params.get (eqp));
  -                // Request parameter is stored as string. 
  +                // Request parameter is stored as string.
                   // Need to convert it beforehand.
                   try {
                       Long _eqp = new Long ( Long.parseLong((String) params.get(eqp)) );
  @@ -374,8 +428,8 @@
           boolean nullable = getNullable (conf, constraints);
           Double value = null;
           Double dflt = null;
  -        { 
  -            String tmp = getDefault (conf, constraints); 
  +        {
  +            String tmp = getDefault (conf, constraints);
               if ( tmp!=null ) dflt = Double.valueOf(tmp);
           }
   
  @@ -386,7 +440,7 @@
               getLogger().debug ("VALIDATOR: double parameter "
                       + name + " is null");
               if (!nullable) {
  -                return new ValidatorActionHelper ( value, 
  +                return new ValidatorActionHelper ( value,
                           ValidatorActionResult.ISNULL);
               } else {
                   value = dflt;
  @@ -420,7 +474,7 @@
               if (!"".equals (eqp)) {
                   getLogger().debug ("VALIDATOR: Double parameter "
                           + name + " should be equal to " + params.get (eqp));
  -                // Request parameter is stored as string. 
  +                // Request parameter is stored as string.
                   // Need to convert it beforehand.
                   try {
                       Double _eqp = new Double ( Double.parseDouble((String) params.get(eqp)));
  @@ -519,7 +573,7 @@
   
       /**
        * Checks whether param is nullable, and returns it, otherwise it
  -     * returns the parsed Double value. 
  +     * returns the parsed Double value.
        *
        * FIXME:
        * Is the "is_string" parameter really needed?
  @@ -645,5 +699,5 @@
   
   }
   
  -// $Id: AbstractValidatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +// $Id: AbstractValidatorAction.java,v 1.2 2002/02/04 09:12:47 cziegeler Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/Action.java
  
  Index: Action.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/Action.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Action.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ Action.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.component.Component;
  @@ -17,7 +65,7 @@
   /**
    *
    * @author <a href="mailto:Giacomo.Pati@pwr.ch">Giacomo Pati</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public interface Action extends Component {
   
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/ComposerAction.java
  
  Index: ComposerAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/ComposerAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ComposerAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ ComposerAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.component.ComponentException;
  @@ -16,7 +64,7 @@
    * that extends this to access SitemapComponents.
    *
    * @author <a href="mailto:Giacomo.Pati@pwr.ch">Giacomo Pati</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public abstract class ComposerAction extends AbstractAction implements Composable {
   
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/ConfigurableComposerAction.java
  
  Index: ConfigurableComposerAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/ConfigurableComposerAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ConfigurableComposerAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ ConfigurableComposerAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.component.ComponentException;
  @@ -20,7 +68,7 @@
    *
    * @author <a href="mailto:Giacomo.Pati@pwr.ch">Giacomo Pati</a>
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $ */
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $ */
   public abstract class ConfigurableComposerAction extends AbstractConfigurableAction implements Composable {
   
       /** The component manager instance */
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/ConfigurationHelper.java
  
  Index: ConfigurationHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/ConfigurationHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ConfigurationHelper.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ ConfigurationHelper.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,15 +1,63 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   /**
    * Keep book on configurations together with their modification times
    *
    * @author Christian Haul &lt;haul@informatik.tu-darmstadt.de&gt;
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $ 
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   package org.apache.cocoon.acting;
   import org.apache.avalon.framework.configuration.Configuration;
  
  
  
  1.3       +61 -13    xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseAddAction.java
  
  Index: DatabaseAddAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseAddAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DatabaseAddAction.java	22 Jan 2002 00:17:11 -0000	1.2
  +++ DatabaseAddAction.java	4 Feb 2002 09:12:47 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -28,12 +76,12 @@
    * Adds record in a database. The action can update one or more tables,
    * and can add more than one row to a table at a time. The form descriptor
    * semantics for this are still in a bit of a state of flux. Note
  - * that if a secondary table relies on the value of a new primary key in a 
  + * that if a secondary table relies on the value of a new primary key in a
    * primary table, the primary key must be created using manual mode.
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
    * @author <a href="mailto:balld@apache.org">Donald Ball</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2002/01/22 00:17:11 $
  + * @version CVS $Revision: 1.3 $ $Date: 2002/02/04 09:12:47 $
    */
   public class DatabaseAddAction extends AbstractDatabaseAction implements ThreadSafe {
       protected static final Map addStatements = new HashMap();
  @@ -55,8 +103,8 @@
               reloadable = Boolean.getBoolean((String) this.settings.get("reloadable"));
           // read local parameter settings
           try {
  -            Configuration conf = 
  -                this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")), resolver, 
  +            Configuration conf =
  +                this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")), resolver,
                                         param.getParameterAsBoolean("reloadable",reloadable));
   
               datasource = this.getDataSource(conf);
  @@ -204,8 +252,8 @@
        * </dl>
        *
        * This method has a couple of side effects. If the mode is manual,
  -     * the key value is stored in the request object's attributes for use 
  -     * by other inserts. The key is the string "key:TABLENAME:DBCOL". 
  +     * the key value is stored in the request object's attributes for use
  +     * by other inserts. The key is the string "key:TABLENAME:DBCOL".
        * This method also puts the value of manually created keys in the results
        * map. That key is simply the value of the dbcol attribute. Note this
        * stuff is definitely up in the air.
  
  
  
  1.2       +57 -3     xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseAuthenticatorAction.java
  
  Index: DatabaseAuthenticatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseAuthenticatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DatabaseAuthenticatorAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ DatabaseAuthenticatorAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,4 +1,58 @@
  -// $Id: DatabaseAuthenticatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -54,7 +108,7 @@
    * not verified.
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public class DatabaseAuthenticatorAction extends AbstractDatabaseAction implements ThreadSafe
   {
  @@ -273,5 +327,5 @@
       }
   }
   
  -// $Id: DatabaseAuthenticatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +// $Id: DatabaseAuthenticatorAction.java,v 1.2 2002/02/04 09:12:47 cziegeler Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.3       +58 -10    xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseDeleteAction.java
  
  Index: DatabaseDeleteAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseDeleteAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DatabaseDeleteAction.java	22 Jan 2002 00:17:11 -0000	1.2
  +++ DatabaseDeleteAction.java	4 Feb 2002 09:12:47 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -32,7 +80,7 @@
    * the keys.
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2002/01/22 00:17:11 $
  + * @version CVS $Revision: 1.3 $ $Date: 2002/02/04 09:12:47 $
    */
   public final class DatabaseDeleteAction extends AbstractDatabaseAction implements ThreadSafe {
       private static final Map deleteStatements = new HashMap();
  @@ -53,8 +101,8 @@
               reloadable = Boolean.getBoolean((String) this.settings.get("reloadable"));
           // read local parameter settings
           try {
  -            Configuration conf = 
  -                this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")), resolver, 
  +            Configuration conf =
  +                this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")), resolver,
                                         param.getParameterAsBoolean("reloadable",reloadable));
   
               String query = this.getDeleteQuery(conf);
  
  
  
  1.2       +60 -12    xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseSelectAction.java
  
  Index: DatabaseSelectAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseSelectAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DatabaseSelectAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ DatabaseSelectAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -32,7 +80,7 @@
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
    * @author <a href="mailto:vgritsenko@apache.org">Vadim Gritsenko</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public class DatabaseSelectAction extends AbstractDatabaseAction implements ThreadSafe {
   
  @@ -54,8 +102,8 @@
               reloadable = Boolean.getBoolean((String) this.settings.get("reloadable"));
           // read local parameter settings
           try {
  -            Configuration conf = 
  -                this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")), 
  +            Configuration conf =
  +                this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")),
                                         resolver,
                                         param.getParameterAsBoolean("reloadable",reloadable));
   
  @@ -64,7 +112,7 @@
               Configuration[] keys = conf.getChild("table").getChild("keys").getChildren("key");
               Configuration[] values = conf.getChild("table").getChild("values").getChildren("value");
   
  -            PreparedStatement statement = null; 
  +            PreparedStatement statement = null;
               ResultSet rset = null;
               boolean result = false;
   
  @@ -173,7 +221,7 @@
                       }
                       queryBuffer.append(values[i].getAttribute("dbcol"));
                   }
  -                
  +
                   queryBuffer.append(" FROM ");
                   queryBuffer.append(table.getAttribute("name"));
   
  
  
  
  1.3       +57 -9     xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseUpdateAction.java
  
  Index: DatabaseUpdateAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/DatabaseUpdateAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DatabaseUpdateAction.java	22 Jan 2002 00:17:11 -0000	1.2
  +++ DatabaseUpdateAction.java	4 Feb 2002 09:12:47 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -29,7 +77,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: 2002/01/22 00:17:11 $
  + * @version CVS $Revision: 1.3 $ $Date: 2002/02/04 09:12:47 $
    */
   public class DatabaseUpdateAction extends AbstractDatabaseAction implements ThreadSafe {
       private static final Map updateStatements = new HashMap();
  @@ -50,7 +98,7 @@
               reloadable = Boolean.getBoolean((String) this.settings.get("reloadable"));
           // read local parameter settings
           try {
  -            Configuration conf = 
  +            Configuration conf =
                   this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")), resolver,
                                         param.getParameterAsBoolean("reloadable",reloadable));
   
  
  
  
  1.2       +72 -18    xml-cocoon2/src/java/org/apache/cocoon/acting/FormValidatorAction.java
  
  Index: FormValidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/FormValidatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- FormValidatorAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ FormValidatorAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,4 +1,58 @@
  -// $Id: FormValidatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configuration;
  @@ -17,7 +71,7 @@
    * This is the action used to validate Request parameters.
    * The parameters are described via the external xml
    * file (its format is defined in AbstractValidatorAction).
  - * 
  + *
    * <h3>Variant 1</h3>
    * <pre>
    * &lt;map:act type="form-validator"&gt;
  @@ -55,7 +109,7 @@
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
    * @author <a href="mailto:haul@informatik.tu-darmstadt.de">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public class FormValidatorAction extends AbstractValidatorAction implements ThreadSafe
   {
  @@ -73,24 +127,24 @@
               return null;
           }
   
  -	// read global parameter settings
  -	boolean reloadable = Constants.DESCRIPTOR_RELOADABLE_DEFAULT;
  -	if (this.settings.containsKey("reloadable"))
  -	    reloadable = Boolean.getBoolean((String) this.settings.get("reloadable"));
  -	String constraints = (String) this.settings.get("constraint-set");
  -	// read local settings
  +    // read global parameter settings
  +    boolean reloadable = Constants.DESCRIPTOR_RELOADABLE_DEFAULT;
  +    if (this.settings.containsKey("reloadable"))
  +        reloadable = Boolean.getBoolean((String) this.settings.get("reloadable"));
  +    String constraints = (String) this.settings.get("constraint-set");
  +    // read local settings
           try {
               Configuration conf = this.getConfiguration (
  -                    parameters.getParameter ("descriptor", (String) this.settings.get("descriptor")), resolver, 
  -		    parameters.getParameterAsBoolean("reloadable", reloadable));
  +                    parameters.getParameter ("descriptor", (String) this.settings.get("descriptor")), resolver,
  +            parameters.getParameterAsBoolean("reloadable", reloadable));
               String valstr = parameters.getParameter ("validate", (String) settings.get("validate",""));
               String valsetstr = parameters.getParameter ("validate-set", (String) settings.get("validate-set",""));
               Configuration[] desc = conf.getChildren ("parameter");
               Configuration[] csets = conf.getChildren ("constraint-set");
               HashMap actionMap = new HashMap ();
               HashMap resultMap = new HashMap ();
  -	    boolean allOK = true;
  -            /* 
  +        boolean allOK = true;
  +            /*
                * old obsoleted method
                */
               if (!"".equals (valstr.trim ())) {
  @@ -127,7 +181,7 @@
                       resultMap.put (name, result.getResult());
                   }
               }
  -            /* 
  +            /*
                * new set-based method
                */
               if (!"".equals (valsetstr.trim ())) {
  @@ -146,7 +200,7 @@
                   }
                   if (!found) {
                       getLogger().debug ("FORMVALIDATOR: given set "
  -                            + valsetstr 
  +                            + valsetstr
                               + " does not exist in a description file");
                       return null;
                   }
  @@ -159,7 +213,7 @@
                   String name = null;
                   HashMap params = new HashMap (set.length);
                   getLogger().debug ("FORMVALIDATOR: given set "
  -                        + valsetstr 
  +                        + valsetstr
                           + " contains " + set.length + " rules");
                   /* put required params into hash */
                   for (int i = 0; i < set.length; i ++) {
  @@ -174,7 +228,7 @@
                   }
                   for (int i = 0; i < set.length; i ++) {
                       name = set[i].getAttribute ("name", null);
  -                    result = validateParameter (name, set[i], 
  +                    result = validateParameter (name, set[i],
                               desc, params, true);
                       if (!result.isOK()) {
                           getLogger().debug ("FORMVALIDATOR: "
  @@ -205,5 +259,5 @@
       }
   }
   
  -// $Id: FormValidatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +// $Id: FormValidatorAction.java,v 1.2 2002/02/04 09:12:47 cziegeler Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/HelloAction.java
  
  Index: HelloAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/HelloAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HelloAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ HelloAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.parameters.Parameters;
  @@ -22,7 +70,7 @@
    * has been created or not.
    *
    * @author <a href="mailto:Giacomo.Pati@pwr.ch">Giacomo Pati</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public class HelloAction extends ComposerAction implements ThreadSafe {
   
  
  
  
  1.2       +69 -21    xml-cocoon2/src/java/org/apache/cocoon/acting/HttpHeaderAction.java
  
  Index: HttpHeaderAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/HttpHeaderAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HttpHeaderAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ HttpHeaderAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configurable;
  @@ -30,35 +78,35 @@
   public class HttpHeaderAction extends AbstractConfigurableAction implements ThreadSafe, Configurable {
   
       private static Object[] defaults = {};
  -    
  +
       public void configure(Configuration conf) throws ConfigurationException {
           if (conf != null) {
  -	    String[] names = {};
  -	    super.configure(conf);
  -	    defaults=(settings.keySet()).toArray();
  -	};
  +        String[] names = {};
  +        super.configure(conf);
  +        defaults=(settings.keySet()).toArray();
  +    };
       }
   
       public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String source, Parameters parameters) throws Exception {
           Map results = new HashMap();
  -	HashMap isDone = new HashMap();
  -	Integer dummy = new Integer(1);
  +    HashMap isDone = new HashMap();
  +    Integer dummy = new Integer(1);
   
           Response response = (Response)objectModel.get(Constants.RESPONSE_OBJECT);
           String[] names = parameters.getNames();
   
  -	// parameters
  +    // parameters
           for (int i=0; i<names.length; i++) {
  -	    isDone.put(names[i], dummy);
  +        isDone.put(names[i], dummy);
               response.setHeader(names[i],parameters.getParameter(names[i]));
               results.put(names[i],parameters.getParameter(names[i]));
           }
  -	// defaults, that are not overridden
  +    // defaults, that are not overridden
           for (int i=0; i<defaults.length; i++) {
  -	    if (! isDone.containsKey(defaults[i])) {
  -		response.setHeader((String) defaults[i], (String) settings.get(defaults[i]));
  -		results.put((String) defaults[i],(String) settings.get(defaults[i]));
  -	    }
  +        if (! isDone.containsKey(defaults[i])) {
  +        response.setHeader((String) defaults[i], (String) settings.get(defaults[i]));
  +        results.put((String) defaults[i],(String) settings.get(defaults[i]));
  +        }
           }
   
           return Collections.unmodifiableMap(results);
  
  
  
  1.2       +55 -7     xml-cocoon2/src/java/org/apache/cocoon/acting/LangSelect.java
  
  Index: LangSelect.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/LangSelect.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LangSelect.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ LangSelect.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configurable;
  
  
  
  1.3       +55 -7     xml-cocoon2/src/java/org/apache/cocoon/acting/LocaleAction.java
  
  Index: LocaleAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/LocaleAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- LocaleAction.java	30 Jan 2002 14:56:12 -0000	1.2
  +++ LocaleAction.java	4 Feb 2002 09:12:47 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import java.util.HashMap;
  
  
  
  1.3       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/OraAddAction.java
  
  Index: OraAddAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/OraAddAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- OraAddAction.java	22 Jan 2002 00:17:11 -0000	1.2
  +++ OraAddAction.java	4 Feb 2002 09:12:47 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import oracle.jdbc.OracleResultSet;
  @@ -35,7 +83,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: 2002/01/22 00:17:11 $
  + * @version CVS $Revision: 1.3 $ $Date: 2002/02/04 09:12:47 $
    */
   public class OraAddAction extends DatabaseAddAction {
       private static final Map selectLOBStatements = new HashMap();
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/OraUpdateAction.java
  
  Index: OraUpdateAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/OraUpdateAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- OraUpdateAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ OraUpdateAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   /**
  @@ -12,7 +60,7 @@
    * only one table at a time to update.
    *
    * @author <a href="mailto:bloritsch@apache.org">Berin Loritsch</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public class OraUpdateAction extends DatabaseUpdateAction {
   
  
  
  
  1.2       +71 -24    xml-cocoon2/src/java/org/apache/cocoon/acting/RequestParamAction.java
  
  Index: RequestParamAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/RequestParamAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- RequestParamAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ RequestParamAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,57 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
   
   /*
    * Package definition
  @@ -78,32 +125,32 @@
    *
    * @author <a href="mailto:Marcus.Crafter@osa.de">Marcus Crafter</a>
    * @author <a href="mailto:tcurdt@dff.st">Torsten Curdt</a>
  - * @version CVS $Revision: 1.1 $
  + * @version CVS $Revision: 1.2 $
    */
   public class RequestParamAction extends ComposerAction implements ThreadSafe {
   
       public final static String MAP_URI         = "requestURI";
       public final static String MAP_QUERY       = "requestQuery";
       public final static String MAP_CONTEXTPATH = "context";
  - 
  +
       public final static String PARAM_PARAMETERS = "parameters";
       public final static String PARAM_DEFAULT_PREFIX = "default.";
   
  - 
  +
       public Map act( Redirector redirector, SourceResolver resolver, Map objectModel, String source, Parameters param )
           throws Exception
       {
  - 
  +
           Request request = (Request) objectModel.get(Constants.REQUEST_OBJECT);
           if (request == null) {
             getLogger().error("RequestInfoAction: no request object!");
             return(null);
           }
  - 
  +
           Map map = new HashMap();
  - 
  +
           map.put(MAP_URI, request.getRequestURI());
  - 
  +
           String query = request.getQueryString();
           if (query != null && query.length() > 0){
             map.put(MAP_QUERY, "?" + query);
  @@ -111,9 +158,9 @@
           else{
             map.put(MAP_QUERY, "");
           }
  - 
  +
           map.put(MAP_CONTEXTPATH, request.getContextPath());
  - 
  +
           if ("true".equalsIgnoreCase(param.getParameter(PARAM_PARAMETERS, null))){
             Enumeration e = request.getParameterNames();
             while(e.hasMoreElements()){
  @@ -124,18 +171,18 @@
                 map.put(name, value);
               }
             }
  -	  
  -	  String[] paramNames = param.getNames();
  +
  +      String[] paramNames = param.getNames();
             for (int i=0; i< paramNames.length; i++) {
  -	      if (paramNames[i].startsWith(PARAM_DEFAULT_PREFIX) &&
  -		  (request.getParameter(paramNames[i].substring(PARAM_DEFAULT_PREFIX.length())) == null)) {
  -		  map.put(paramNames[i].substring(PARAM_DEFAULT_PREFIX.length()), param.getParameter(paramNames[i]));
  -	      }
  -	  }
  +          if (paramNames[i].startsWith(PARAM_DEFAULT_PREFIX) &&
  +          (request.getParameter(paramNames[i].substring(PARAM_DEFAULT_PREFIX.length())) == null)) {
  +          map.put(paramNames[i].substring(PARAM_DEFAULT_PREFIX.length()), param.getParameter(paramNames[i]));
  +          }
  +      }
   
   
           }
  - 
  +
           return(map);
       }
   }
  
  
  
  1.2       +227 -179  xml-cocoon2/src/java/org/apache/cocoon/acting/RequestParameterExistsAction.java
  
  Index: RequestParameterExistsAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/RequestParameterExistsAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- RequestParameterExistsAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ RequestParameterExistsAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import java.util.Collections;
  @@ -41,30 +89,30 @@
    * "name_1" must also exist and vice versa.</p>
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $ */
  -public class RequestParameterExistsAction extends AbstractConfigurableAction 
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $ */
  +public class RequestParameterExistsAction extends AbstractConfigurableAction
   {
   
       protected class StringParts {
  -	String prefix = null;
  -	String pstfix = null;
  -	int count = 0;
  -
  -	public StringParts ( String pre, String post ) {
  -	    prefix = pre;
  -	    pstfix = post;
  -	}
  -    }
  -				 
  -
  -
  -    public Map act( Redirector redirector, 
  -		    SourceResolver resolver, 
  -		    Map objectModel, 
  -		    String source, 
  -		    Parameters parameters
  -		    ) 
  -	throws Exception 
  +    String prefix = null;
  +    String pstfix = null;
  +    int count = 0;
  +
  +    public StringParts ( String pre, String post ) {
  +        prefix = pre;
  +        pstfix = post;
  +    }
  +    }
  +
  +
  +
  +    public Map act( Redirector redirector,
  +            SourceResolver resolver,
  +            Map objectModel,
  +            String source,
  +            Parameters parameters
  +            )
  +    throws Exception
       {
           Request request = (Request) objectModel.get(Constants.REQUEST_OBJECT);
           if (request == null) {
  @@ -72,174 +120,174 @@
             return(null);
           }
           HashMap results = new HashMap();
  -	HashMap items = new HashMap();
  -	int wildcards = 0;
  +    HashMap items = new HashMap();
  +    int wildcards = 0;
  +
  +    // check default parameters for existence
  +    getLogger().debug("checking default parameters");
  +    Iterator reqParams = settings.values().iterator();
  +    while ( reqParams.hasNext() ) {
  +        String paramName = (String) reqParams.next();
  +        StringParts sp = splitParameter( paramName );
  +        if ( sp != null ) {
  +        // wildcard: special care required (deferred until later)
  +        items.put( new Integer( wildcards++ ), sp );
  +        getLogger().debug("(default) deferring "+paramName);
  +        } else {
  +        String paramValue = request.getParameter( paramName );
  +        if ( paramValue == null ) {
  +            return null;
  +        }
  +        results.put( paramName, paramValue );
  +        }
  +    }
  +
  +    // check parameters for existence
  +    getLogger().debug("checking sitemap parameters");
  +    String params = parameters.getParameter( "parameters", null) ;
  +    if ( params != null ) {
  +        StringTokenizer st = new StringTokenizer( params );
  +        while ( st.hasMoreTokens() ) {
  +        String paramName = st.nextToken();
  +        StringParts sp = splitParameter( paramName );
  +        if ( sp != null ) {
  +            // wildcard: special care required (deferred until later)
  +            items.put(new Integer(wildcards++), sp );
  +            getLogger().debug("deferring "+paramName);
  +        } else {
  +
  +            String paramValue = request.getParameter( paramName );
  +            if ( paramValue == null ) {
  +            return null;
  +            }
  +            results.put( paramName, paramValue );
  +        }
  +        }
  +    }
  +
  +    if ( wildcards != 0 ) {
  +        // special care for parameters with wildcard
  +        //
  +        getLogger().debug("deferred checking for parameters: "+wildcards);
  +
  +        // first one
  +        //
  +        getLogger().debug(" checking first");
  +        HashMap values = new HashMap();
  +        StringParts sp1 = (StringParts) items.get( new Integer( 0 ) );
  +        getLogger().debug("  Parameter is ["+sp1.prefix+" * "+sp1.pstfix+"] ");
  +        Enumeration requestParams = request.getParameterNames();
  +        Boolean dummy = new Boolean( true );
  +        while ( requestParams.hasMoreElements() ) {
  +        String paramName = (String) requestParams.nextElement();
  +        String match = getMatch( paramName, sp1 );
  +        if ( match != null ) {
  +            getLogger().debug("  value is >"+match+"< "+ sp1.prefix.length()+" "+ paramName.length()+ " " +sp1.pstfix.length());
  +            values.put( match, dummy );
  +            sp1.count++;
  +            getLogger().debug("   Parameter "+sp1.prefix+"*"+sp1.pstfix+" matches "+paramName+" ("+sp1.count+" so far)");
  +
  +            String paramValue = request.getParameter( paramName );
  +            if ( paramValue == null ) {
  +            return null;
  +            }
  +            results.put( paramName, paramValue );
  +        }
  +        }
  +
  +        if ( sp1.count == 0 ) {
  +        getLogger().debug("   Parameter "+sp1.prefix+"*"+sp1.pstfix+" matches "+sp1.count);
  +        return null;
  +        }
  +
  +
  +        // all other ones
  +        //
  +        getLogger().debug(" checking others");
  +        requestParams = request.getParameterNames();
  +        while ( requestParams.hasMoreElements() ) {
  +        String paramName = (String) requestParams.nextElement();
  +        getLogger().debug("  checking request parameter "+paramName);
  +        for ( int i = wildcards-1; i > 0; i-- ) {
  +            getLogger().debug("   checking against "+i);
  +            StringParts sp = (StringParts) items.get( new Integer( i ) );
  +            String match = getMatch( paramName, sp );
  +            getLogger().debug("   Parameter is ["+sp.prefix+" * "+sp.pstfix+"] ");
  +            if ( match != null ) {
  +            getLogger().debug("   Parameter "+sp.prefix+"*"+sp.pstfix+" matches "+paramName+" ("+sp.count+" so far)");
  +            if ( values.containsKey( match ) ) {
  +                sp.count++;
  +                getLogger().debug("   "+paramName+" (verified)");
  +
  +                String paramValue = request.getParameter( paramName );
  +                if ( paramValue == null ) {
  +                return null;
  +                }
  +                results.put( paramName, paramValue );
  +
  +            } else {
  +                getLogger().debug("Match " + match + "not found for "
  +                          + sp1.prefix + "*" + sp1.pstfix + " but for "
  +                          + sp.prefix + "*" + sp.pstfix);
  +                return null;
  +            }
  +            }
  +        }
  +        }
  +
  +        // since we enforce that only matches are counted, that exist for
  +        // the first parameter as well, check if every parameter has an
  +        // equal number of matches.
  +        //
  +        getLogger().debug("checking number of matches");
  +        for ( int i = wildcards-1; i > 0; i-- ) {
  +        StringParts sp = (StringParts) items.get( new Integer( i ) );
  +        if ( sp.count != sp1.count ) {
  +            getLogger().debug("Found " + sp.count + " matches for "
  +                      + sp.prefix + "*" + sp.pstfix + " but expected "
  +                      + sp1.count);
  +            return null;
  +        } else {
  +            getLogger().debug("Found " + sp.count + " matches for "
  +                      + sp.prefix + "*" + sp.pstfix + " as expected");
  +        }
  +        }
  +
  +    }
   
  -	// check default parameters for existence
  -	getLogger().debug("checking default parameters");
  -	Iterator reqParams = settings.values().iterator();
  -	while ( reqParams.hasNext() ) {
  -	    String paramName = (String) reqParams.next();
  -	    StringParts sp = splitParameter( paramName );
  -	    if ( sp != null ) {
  -		// wildcard: special care required (deferred until later)
  -		items.put( new Integer( wildcards++ ), sp );
  -		getLogger().debug("(default) deferring "+paramName);
  -	    } else {
  -		String paramValue = request.getParameter( paramName );
  -		if ( paramValue == null ) {
  -		    return null;
  -		}
  -		results.put( paramName, paramValue );
  -	    }
  -	}
  -
  -	// check parameters for existence
  -	getLogger().debug("checking sitemap parameters");
  -	String params = parameters.getParameter( "parameters", null) ;
  -	if ( params != null ) {
  -	    StringTokenizer st = new StringTokenizer( params );
  -	    while ( st.hasMoreTokens() ) {
  -		String paramName = st.nextToken();
  -		StringParts sp = splitParameter( paramName );
  -		if ( sp != null ) {
  -		    // wildcard: special care required (deferred until later)
  -		    items.put(new Integer(wildcards++), sp );
  -		    getLogger().debug("deferring "+paramName);
  -		} else {
  -
  -		    String paramValue = request.getParameter( paramName );
  -		    if ( paramValue == null ) {
  -			return null;
  -		    }
  -		    results.put( paramName, paramValue );
  -		}
  -	    }
  -	}
  -	
  -	if ( wildcards != 0 ) {
  -	    // special care for parameters with wildcard
  -	    //
  -	    getLogger().debug("deferred checking for parameters: "+wildcards);
  -
  -	    // first one
  -	    //
  -	    getLogger().debug(" checking first");
  -	    HashMap values = new HashMap();
  -	    StringParts sp1 = (StringParts) items.get( new Integer( 0 ) );
  -	    getLogger().debug("  Parameter is ["+sp1.prefix+" * "+sp1.pstfix+"] ");
  -	    Enumeration requestParams = request.getParameterNames();
  -	    Boolean dummy = new Boolean( true );
  -	    while ( requestParams.hasMoreElements() ) {
  -		String paramName = (String) requestParams.nextElement();
  -		String match = getMatch( paramName, sp1 );
  -		if ( match != null ) {
  -		    getLogger().debug("  value is >"+match+"< "+ sp1.prefix.length()+" "+ paramName.length()+ " " +sp1.pstfix.length());
  -		    values.put( match, dummy );
  -		    sp1.count++;
  -		    getLogger().debug("   Parameter "+sp1.prefix+"*"+sp1.pstfix+" matches "+paramName+" ("+sp1.count+" so far)");
  -
  -		    String paramValue = request.getParameter( paramName );
  -		    if ( paramValue == null ) {
  -			return null;
  -		    }
  -		    results.put( paramName, paramValue );
  -		}
  -	    }
  -
  -	    if ( sp1.count == 0 ) {
  -		getLogger().debug("   Parameter "+sp1.prefix+"*"+sp1.pstfix+" matches "+sp1.count);
  -		return null;
  -	    }
  -
  -	    
  -	    // all other ones
  -	    //
  -	    getLogger().debug(" checking others");
  -	    requestParams = request.getParameterNames();
  -	    while ( requestParams.hasMoreElements() ) {
  -		String paramName = (String) requestParams.nextElement();
  -		getLogger().debug("  checking request parameter "+paramName);
  -		for ( int i = wildcards-1; i > 0; i-- ) {
  -		    getLogger().debug("   checking against "+i);
  -		    StringParts sp = (StringParts) items.get( new Integer( i ) );
  -		    String match = getMatch( paramName, sp );
  -		    getLogger().debug("   Parameter is ["+sp.prefix+" * "+sp.pstfix+"] ");
  -		    if ( match != null ) {
  -			getLogger().debug("   Parameter "+sp.prefix+"*"+sp.pstfix+" matches "+paramName+" ("+sp.count+" so far)");
  -			if ( values.containsKey( match ) ) {
  -			    sp.count++;
  -			    getLogger().debug("   "+paramName+" (verified)");
  -			    
  -			    String paramValue = request.getParameter( paramName );
  -			    if ( paramValue == null ) {
  -				return null;
  -			    }
  -			    results.put( paramName, paramValue );
  -
  -			} else {
  -			    getLogger().debug("Match " + match + "not found for "
  -					      + sp1.prefix + "*" + sp1.pstfix + " but for "
  -					      + sp.prefix + "*" + sp.pstfix);
  -			    return null;
  -			}
  -		    }
  -		}
  -	    }
  -
  -	    // since we enforce that only matches are counted, that exist for
  -	    // the first parameter as well, check if every parameter has an 
  -	    // equal number of matches.
  -	    //
  -	    getLogger().debug("checking number of matches");
  -	    for ( int i = wildcards-1; i > 0; i-- ) {
  -		StringParts sp = (StringParts) items.get( new Integer( i ) );
  -		if ( sp.count != sp1.count ) {
  -		    getLogger().debug("Found " + sp.count + " matches for "
  -				      + sp.prefix + "*" + sp.pstfix + " but expected "
  -				      + sp1.count);
  -		    return null;
  -		} else {
  -		    getLogger().debug("Found " + sp.count + " matches for "
  -				      + sp.prefix + "*" + sp.pstfix + " as expected");
  -		}
  -	    }
  -		
  -	}
  -	
   
           return Collections.unmodifiableMap(results);
       }
   
   
  -    /** 
  +    /**
        * Find first "*" in a String and split it into the substring
        * before and after the "*". Returns null if no "*" is present.
        */
  -    protected StringParts splitParameter( String paramName ) 
  +    protected StringParts splitParameter( String paramName )
       {
  -	int idx = paramName.indexOf("*");
  -	if ( idx != -1 ) {
  -	    return new StringParts(paramName.substring(0,idx), paramName.substring(idx+1));
  -	} else {
  -	    return null;
  -	}
  +    int idx = paramName.indexOf("*");
  +    if ( idx != -1 ) {
  +        return new StringParts(paramName.substring(0,idx), paramName.substring(idx+1));
  +    } else {
  +        return null;
  +    }
       }
   
  -    /** 
  +    /**
        * If a String matches a StringPart spec, return the substring
        * between the specified prefix and postfix. Returns null if it
  -     * doesn't match. 
  +     * doesn't match.
        */
       protected String getMatch( String paramName,
  -			       StringParts sp
  -			       )
  +                   StringParts sp
  +                   )
       {
  -	if ( paramName.startsWith( sp.prefix ) && paramName.endsWith( sp.pstfix ) ) {
  -	    return paramName.substring( sp.prefix.length(), ( paramName.length() - sp.pstfix.length() ) );
  -	} else {
  -	    return null;
  -	}
  +    if ( paramName.startsWith( sp.prefix ) && paramName.endsWith( sp.pstfix ) ) {
  +        return paramName.substring( sp.prefix.length(), ( paramName.length() - sp.pstfix.length() ) );
  +    } else {
  +        return null;
  +    }
       }
   
   }
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/ResourceExistsAction.java
  
  Index: ResourceExistsAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/ResourceExistsAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ResourceExistsAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ ResourceExistsAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.parameters.Parameters;
  @@ -23,7 +71,7 @@
    * null otherwise. It has only been tested with context urls.
    *
    * @author <a href="mailto:balld@apache.org">Donald Ball</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public class ResourceExistsAction extends ComposerAction implements ThreadSafe {
   
  
  
  
  1.4       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/ScriptAction.java
  
  Index: ScriptAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/ScriptAction.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- ScriptAction.java	25 Jan 2002 03:35:52 -0000	1.3
  +++ ScriptAction.java	4 Feb 2002 09:12:47 -0000	1.4
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   // Cocoon imports
  @@ -32,7 +80,7 @@
    * A simple action that executes any script that can be run by the BSF
    *
    * @author <a href="mailto:jafoster@uwaterloo.ca">Jason Foster</a>
  - * @version CVS $Revision: 1.3 $ $Date: 2002/01/25 03:35:52 $
  + * @version CVS $Revision: 1.4 $ $Date: 2002/02/04 09:12:47 $
    */
   
   public class ScriptAction
  
  
  
  1.2       +55 -7     xml-cocoon2/src/java/org/apache/cocoon/acting/SendmailAction.java
  
  Index: SendmailAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/SendmailAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SendmailAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ SendmailAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configurable;
  
  
  
  1.2       +77 -29    xml-cocoon2/src/java/org/apache/cocoon/acting/ServerPagesAction.java
  
  Index: ServerPagesAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/ServerPagesAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ServerPagesAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ ServerPagesAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.excalibur.component.ComponentHandler;
  @@ -61,12 +109,12 @@
    * </pre>
    *
    * @author <a href="mailto:sylvain@apache.org">Sylvain Wallez</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
  -public class ServerPagesAction 
  -        extends ConfigurableComposerAction 
  +public class ServerPagesAction
  +        extends ConfigurableComposerAction
           implements Disposable, ThreadSafe, LogKitManageable {
  -    
  +
       public static final String REDIRECTOR_OBJECT = "xsp-action:redirector";
       public static final String ACTION_RESULT_OBJECT = "xsp-action:result";
       public static final String ACTION_SUCCESS_OBJECT = "xsp-action:success";
  @@ -74,7 +122,7 @@
       private LogKitManager logKitManager;
   
       ComponentHandler generatorHandler;
  -    
  +
       public void configure(Configuration conf)
         throws ConfigurationException {
           try {
  @@ -86,10 +134,10 @@
                   null,  // RoleManager
                   this.logKitManager  // LogKitManager
               );
  -        
  +
               this.generatorHandler.setLogger(getLogger());
               this.generatorHandler.initialize();
  -            
  +
           } catch(Exception e) {
               throw new ConfigurationException("Cannot set up component handler", e);
           }
  @@ -105,28 +153,28 @@
               this.generatorHandler = null;
           }
       }
  -    
  +
       public Map act(Redirector redirector, SourceResolver resolver, Map objectModel,
           String source, Parameters parameters)
         throws Exception {
  -        
  +
           getLogger().debug("serverpage source: " + source);
  -        
  +
           String outputKey = parameters.getParameter("output-attribute", null);
           Map resultMap = new HashMap();
           Object success = null;
   
           // Get a ServerPagesGenerator
           ServerPagesGenerator generator = (ServerPagesGenerator)this.generatorHandler.get();
  -        
  +
           // Generator ouptut, if output-attribute was given
           XMLByteStreamCompiler compiler = null;
  -        
  +
           try {
               generator.setLogger(getLogger());
  -            generator.compose(this.manager);        
  +            generator.compose(this.manager);
               generator.setup(resolver, objectModel, source, parameters);
  -            
  +
               // Setup generator output
               if (outputKey == null) {
                   // discard output to a "black hole"
  @@ -136,42 +184,42 @@
                   compiler = new XMLByteStreamCompiler();
                   generator.setConsumer(compiler);
               }
  -            
  +
               // Augment the object model for the "action" logicsheet
               objectModel.put(REDIRECTOR_OBJECT, redirector);
               objectModel.put(ACTION_RESULT_OBJECT, resultMap);
  -        
  +
               // Let the XSP do it's stuff
               generator.generate();
               success = objectModel.get(ACTION_SUCCESS_OBJECT);
  -            
  +
           } catch (Exception e) {
               getLogger().warn("serverpage error", e);
               throw e;
  -            
  +
           } finally {
               // Release generator
               generatorHandler.put(generator);
  -            
  +
               // Clean up object model
               objectModel.remove(REDIRECTOR_OBJECT);
               objectModel.remove(ACTION_RESULT_OBJECT);
               objectModel.remove(ACTION_SUCCESS_OBJECT);
           }
  -        
  +
           if (outputKey != null) {
               // Success defaults to true when the whole output is captured
               if (success == null) {
                   success = Boolean.TRUE;
               }
  -            
  +
               if (success == Boolean.TRUE) {
                   // Store the XSP output in the request
                   Request req = (Request)objectModel.get(Constants.REQUEST_OBJECT);
                   req.setAttribute(outputKey, new XMLByteStreamFragment(compiler.getSAXFragment()));
               }
           }
  -        
  +
           return (success == Boolean.TRUE) ? resultMap : null;
       }
   }
  
  
  
  1.2       +57 -3     xml-cocoon2/src/java/org/apache/cocoon/acting/SessionInvalidatorAction.java
  
  Index: SessionInvalidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/SessionInvalidatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SessionInvalidatorAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ SessionInvalidatorAction.java	4 Feb 2002 09:12:47 -0000	1.2
  @@ -1,4 +1,58 @@
  -// $Id: SessionInvalidatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.parameters.Parameters;
  @@ -18,7 +72,7 @@
    * empty map if everything is ok, null otherwise.
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:47 $
    */
   public class SessionInvalidatorAction extends AbstractAction implements ThreadSafe
   {
  @@ -49,5 +103,5 @@
       }
   }
   
  -// $Id: SessionInvalidatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +// $Id: SessionInvalidatorAction.java,v 1.2 2002/02/04 09:12:47 cziegeler Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/acting/SessionIsValidAction.java
  
  Index: SessionIsValidAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/SessionIsValidAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SessionIsValidAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ SessionIsValidAction.java	4 Feb 2002 09:12:48 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.parameters.Parameters;
  @@ -24,7 +72,7 @@
    * seesion is still valid.
    *
    * @author <a href="mailto:haul@informatik.tu-darmstadt.de">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:48 $
    */
   
   public class SessionIsValidAction extends AbstractValidatorAction implements ThreadSafe
  
  
  
  1.2       +90 -36    xml-cocoon2/src/java/org/apache/cocoon/acting/SessionPropagatorAction.java
  
  Index: SessionPropagatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/SessionPropagatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SessionPropagatorAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ SessionPropagatorAction.java	4 Feb 2002 09:12:48 -0000	1.2
  @@ -1,4 +1,58 @@
  -// $Id: SessionPropagatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configuration;
  @@ -29,19 +83,19 @@
    * </pre>
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:48 $
    */
   public class SessionPropagatorAction extends AbstractConfigurableAction implements ThreadSafe
   {
   
       private static Object[] defaults = {};
  -    
  +
       public void configure(Configuration conf) throws ConfigurationException {
           if (conf != null) {
  -	    String[] names = {};
  -	    super.configure(conf);
  -	    defaults=(settings.keySet()).toArray();
  -	};
  +        String[] names = {};
  +        super.configure(conf);
  +        defaults=(settings.keySet()).toArray();
  +    };
       }
   
       /**
  @@ -53,8 +107,8 @@
               objectModel.get (Constants.REQUEST_OBJECT);
           HashMap actionMap = new HashMap ();
   
  -	HashMap isDone = new HashMap();
  -	Integer dummy = new Integer(1);
  +    HashMap isDone = new HashMap();
  +    Integer dummy = new Integer(1);
   
           if (req == null) {
               getLogger ().debug ("SESSIONPROPAGATOR: no request object");
  @@ -70,41 +124,41 @@
   
           try {
   
  -	    String[] names = parameters.getNames();
  +        String[] names = parameters.getNames();
   
  -	    // parameters
  -	    for (int i=0; i<names.length; i++) {
  -		String sessionParamName = names[i];
  +        // parameters
  +        for (int i=0; i<names.length; i++) {
  +        String sessionParamName = names[i];
                   if (sessionParamName == null ||
  -		    "".equals (sessionParamName.trim ()))
  +            "".equals (sessionParamName.trim ()))
                       return null;
  -		isDone.put(sessionParamName, dummy);
  -		String value = parameters.getParameter(sessionParamName);
  +        isDone.put(sessionParamName, dummy);
  +        String value = parameters.getParameter(sessionParamName);
                   getLogger().debug ("SESSIONPROPAGATOR: propagating value "
                           + value
                           + " to session attribute "
                           + sessionParamName);
                   session.setAttribute (sessionParamName, value);
                   actionMap.put (sessionParamName, value);
  -	    }
  -        
  -	    // defaults, that are not overridden
  -	    for (int i=0; i<defaults.length; i++) {
  -		if (! isDone.containsKey(defaults[i])) {
  -		    String sessionParamName = (String) defaults[i];
  -		    if (sessionParamName == null ||
  -			"".equals (sessionParamName.trim ()))
  -			return null;
  -		    isDone.put(sessionParamName, dummy);
  -		    String value = parameters.getParameter(sessionParamName);
  -		    getLogger().debug ("SESSIONPROPAGATOR: propagating value "
  -				       + value
  -				       + " to session attribute "
  -				       + sessionParamName);
  -		    session.setAttribute (sessionParamName, value);
  -		    actionMap.put (sessionParamName, value);
  -		}
  -	    }
  +        }
  +
  +        // defaults, that are not overridden
  +        for (int i=0; i<defaults.length; i++) {
  +        if (! isDone.containsKey(defaults[i])) {
  +            String sessionParamName = (String) defaults[i];
  +            if (sessionParamName == null ||
  +            "".equals (sessionParamName.trim ()))
  +            return null;
  +            isDone.put(sessionParamName, dummy);
  +            String value = parameters.getParameter(sessionParamName);
  +            getLogger().debug ("SESSIONPROPAGATOR: propagating value "
  +                       + value
  +                       + " to session attribute "
  +                       + sessionParamName);
  +            session.setAttribute (sessionParamName, value);
  +            actionMap.put (sessionParamName, value);
  +        }
  +        }
               getLogger().debug ("SESSIONPROPAGATOR: all params propagated "
                       + "to session");
               return Collections.unmodifiableMap (actionMap);
  @@ -115,6 +169,6 @@
       }
   }
   
  -// $Id: SessionPropagatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +// $Id: SessionPropagatorAction.java,v 1.2 2002/02/04 09:12:48 cziegeler Exp $
   // vim: set et ts=4 sw=4:
   
  
  
  
  1.2       +114 -66   xml-cocoon2/src/java/org/apache/cocoon/acting/SessionStateAction.java
  
  Index: SessionStateAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/SessionStateAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SessionStateAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ SessionStateAction.java	4 Feb 2002 09:12:48 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configuration;
  @@ -37,9 +85,9 @@
    * several times with different attribute names rather than sub
    * levels. </p>
    *
  - * <p><b>Global and local paramters:</b></p> 
  + * <p><b>Global and local paramters:</b></p>
    *
  - * <table border="1"> 
  + * <table border="1">
    *   <tr>
    *     <td><code>state-key-prefix</code></td>
    *     <td>String that identifies the attribute that stores the session state in the
  @@ -50,7 +98,7 @@
    *     	 "<code>__sessionState3</code>" will be used to store the
    *     	 information.
    *     </td>
  - *   </tr> 
  + *   </tr>
    *   <tr>
    *     <td><code>new-state</code></td>
    *     <td>String that identifies the current state</td>
  @@ -58,18 +106,18 @@
    *   <tr>
    *     <td><code>sub-levels</code></td>
    *     <td>Number of sub levels to  use</td>
  - *   </tr> 
  + *   </tr>
    *   <tr>
    *     <td><code>state-level</code></td>
    *     <td>Sub level to modify, this is <b>one</b> based</td>
  - *   </tr> 
  + *   </tr>
    * </table>
    *
    * @see org.apache.cocoon.matching.WildcardSessionAttributeMatcherFactory
    * @see org.apache.cocoon.selection.SessionAttributeSelectorFactory
    *
    * @author <a href="mailto:haul@informatik.tu-darmstadt.de">Christian Haul</a>
  - * @version CVS $Id: SessionStateAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $ */
  + * @version CVS $Id: SessionStateAction.java,v 1.2 2002/02/04 09:12:48 cziegeler Exp $ */
   public class SessionStateAction extends AbstractConfigurableAction implements ThreadSafe {
   
       protected String statekey = "org.apache.cocoon.SessionState";
  @@ -80,75 +128,75 @@
       /**
        * Configures the Action.
        */
  -    public void configure(Configuration conf) throws ConfigurationException 
  +    public void configure(Configuration conf) throws ConfigurationException
       {
  -	super.configure(conf);
  +    super.configure(conf);
   
  -	if (settings.containsKey("state-key-prefix"))
  -	    statekey = (String) settings.get("state-key-prefix");
  -	if (settings.containsKey("new-state"))
  -	    newstate = (String) settings.get("new-state");
  -	if (settings.containsKey("sub-levels"))
  -	    sublevels = Integer.parseInt((String) settings.get("sub-levels"));
  -	if (settings.containsKey("state-level"))
  -	    mylevel = Integer.parseInt((String) settings.get("state-level"));
  +    if (settings.containsKey("state-key-prefix"))
  +        statekey = (String) settings.get("state-key-prefix");
  +    if (settings.containsKey("new-state"))
  +        newstate = (String) settings.get("new-state");
  +    if (settings.containsKey("sub-levels"))
  +        sublevels = Integer.parseInt((String) settings.get("sub-levels"));
  +    if (settings.containsKey("state-level"))
  +        mylevel = Integer.parseInt((String) settings.get("state-level"));
       }
   
   
  -    public Map 	act (Redirector redirector, 
  -		     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);
   
  -	// read local settings
  -	newstate = par.getParameter("new-state", newstate);
  -	statekey = par.getParameter("state-key", statekey);
  -	sublevels = par.getParameterAsInteger("sublevels", sublevels);
  -	mylevel = par.getParameterAsInteger("state-level", mylevel);
  -
  -	if (newstate == null ) {
  -	    getLogger().error("new-state is null");
  -	    return null;
  -	}
  +    // read local settings
  +    newstate = par.getParameter("new-state", newstate);
  +    statekey = par.getParameter("state-key", statekey);
  +    sublevels = par.getParameterAsInteger("sublevels", sublevels);
  +    mylevel = par.getParameterAsInteger("state-level", mylevel);
  +
  +    if (newstate == null ) {
  +        getLogger().error("new-state is null");
  +        return null;
  +    }
   
   
           if (request != null) {
              Session session = request.getSession (false);
  -	    
  +
               if (session != null && request.isRequestedSessionIdValid()) {
  -		String oldstate = null;
  -		if (sublevels == 0) {
  -		    oldstate = (String) session.getAttribute(statekey);
  -		    session.setAttribute(statekey, newstate);
  -		    getLogger().debug(statekey+"="+newstate);
  -
  -		} else { // sublevels != 0
  -		    oldstate = (String) session.getAttribute( statekey + Integer.toString(mylevel) );
  -		    for (int i=mylevel+1; i<=sublevels; i++) {
  -			session.removeAttribute( statekey+Integer.toString(i) );
  -			getLogger().debug("remove "+statekey+Integer.toString(i));
  -		    }
  -		    session.setAttribute( statekey + Integer.toString(mylevel), newstate);
  -		    getLogger().debug(statekey+Integer.toString(mylevel)+"="+newstate);
  -		}
  -		getLogger().debug("transition " + oldstate + " -> " + newstate);
  -		
  -		HashMap map = new HashMap(1);
  -		map.put("newstate", newstate);
  -		return map;
  -		
  -	    } else {
  +        String oldstate = null;
  +        if (sublevels == 0) {
  +            oldstate = (String) session.getAttribute(statekey);
  +            session.setAttribute(statekey, newstate);
  +            getLogger().debug(statekey+"="+newstate);
  +
  +        } else { // sublevels != 0
  +            oldstate = (String) session.getAttribute( statekey + Integer.toString(mylevel) );
  +            for (int i=mylevel+1; i<=sublevels; i++) {
  +            session.removeAttribute( statekey+Integer.toString(i) );
  +            getLogger().debug("remove "+statekey+Integer.toString(i));
  +            }
  +            session.setAttribute( statekey + Integer.toString(mylevel), newstate);
  +            getLogger().debug(statekey+Integer.toString(mylevel)+"="+newstate);
  +        }
  +        getLogger().debug("transition " + oldstate + " -> " + newstate);
  +
  +        HashMap map = new HashMap(1);
  +        map.put("newstate", newstate);
  +        return map;
  +
  +        } else {
                   getLogger().warn("A session object was not present or no longer valid");
  -		return null;
  +        return null;
               }
           } else {
  -	    getLogger().warn("No request object");
  -	    return null;
  -	}
  -	
  +        getLogger().warn("No request object");
  +        return null;
  +    }
  +
       }
   }
   
  
  
  
  1.2       +57 -3     xml-cocoon2/src/java/org/apache/cocoon/acting/SessionValidatorAction.java
  
  Index: SessionValidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/SessionValidatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SessionValidatorAction.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ SessionValidatorAction.java	4 Feb 2002 09:12:48 -0000	1.2
  @@ -1,4 +1,58 @@
  -// $Id: SessionValidatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configuration;
  @@ -52,7 +106,7 @@
    * all validated parameters to the sitemap via {name} expression.
    *
    * @author Martin Man &lt;Martin.Man@seznam.cz&gt;
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:48 $
    */
   public class SessionValidatorAction extends AbstractValidatorAction implements ThreadSafe
   {
  @@ -197,5 +251,5 @@
       }
   }
   
  -// $Id: SessionValidatorAction.java,v 1.1 2002/01/03 12:31:07 giacomo Exp $
  +// $Id: SessionValidatorAction.java,v 1.2 2002/02/04 09:12:48 cziegeler Exp $
   // vim: set et ts=4 sw=4:
  
  
  
  1.2       +69 -14    xml-cocoon2/src/java/org/apache/cocoon/acting/ValidatorActionHelper.java
  
  Index: ValidatorActionHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/ValidatorActionHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ValidatorActionHelper.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ ValidatorActionHelper.java	4 Feb 2002 09:12:48 -0000	1.2
  @@ -1,3 +1,58 @@
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   
  @@ -7,7 +62,7 @@
    * the validated object itself.
    *
    * @author Christian Haul &lt;haul@informatik.tu-darmstadt.de&gt;
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:48 $
    */
   
   public class ValidatorActionHelper
  @@ -23,8 +78,8 @@
        */
   
       public ValidatorActionHelper ( Object validatedObject ) {
  -	this.object = validatedObject;
  -	this.result = ValidatorActionResult.OK;
  +    this.object = validatedObject;
  +    this.result = ValidatorActionResult.OK;
       }
   
       /**
  @@ -35,8 +90,8 @@
        * @param validationResult result of the validation
        */
       public ValidatorActionHelper ( Object validatedObject, ValidatorActionResult validationResult ) {
  -	this.object = validatedObject;
  -	this.result = validationResult;
  +    this.object = validatedObject;
  +    this.result = validationResult;
       }
   
       /**
  @@ -44,16 +99,16 @@
        *
        */
       public boolean isOK() {
  -	return (result.equals(ValidatorActionResult.OK));
  +    return (result.equals(ValidatorActionResult.OK));
       }
   
       /**
        * Tests if the validation result is <code>ISNULL</code>,
        * e.g. when the value is null but is not supposed to be null.
  -     *  
  +     *
        */
       public boolean isNull() {
  -	return (result.equals(ValidatorActionResult.ISNULL));
  +    return (result.equals(ValidatorActionResult.ISNULL));
       }
   
       /**
  @@ -63,7 +118,7 @@
        *
        */
       public boolean isTooLarge() {
  -	return (result.equals(ValidatorActionResult.TOOLARGE));
  +    return (result.equals(ValidatorActionResult.TOOLARGE));
       }
   
       /**
  @@ -73,16 +128,16 @@
        *
        */
       public boolean isTooSmall() {
  -	return (result.equals(ValidatorActionResult.TOOSMALL));
  +    return (result.equals(ValidatorActionResult.TOOSMALL));
       }
   
       /**
        * Tests if the validation result is <code>NOMATCH</code>, can
  -     * only occur when 
  +     * only occur when
        *
        */
       public boolean doesNotMatch() {
  -	return (result.equals(ValidatorActionResult.NOMATCH));
  +    return (result.equals(ValidatorActionResult.NOMATCH));
       }
   
       /**
  @@ -90,7 +145,7 @@
        *
        */
       public Object getObject() {
  -	return object;
  +    return object;
       }
   
       /**
  @@ -98,7 +153,7 @@
        *
        */
       public ValidatorActionResult getResult() {
  -	return result;
  +    return result;
       }
   
   }
  
  
  
  1.2       +93 -45    xml-cocoon2/src/java/org/apache/cocoon/acting/ValidatorActionResult.java
  
  Index: ValidatorActionResult.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/acting/ValidatorActionResult.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ValidatorActionResult.java	3 Jan 2002 12:31:07 -0000	1.1
  +++ ValidatorActionResult.java	4 Feb 2002 09:12:48 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   import org.apache.cocoon.util.EnumerationFactory;
   
  @@ -13,66 +61,66 @@
    * validation.
    *
    * @author Christian Haul &lt;haul@informatik.tu-darmstadt.de&gt;
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:07 $ 
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:48 $
    */
   
   public class ValidatorActionResult extends EnumerationFactory {
   
  -	/**
  -	 * no error occurred, parameter successfully checked.
  -	 */
  +    /**
  +     * no error occurred, parameter successfully checked.
  +     */
       public static final ValidatorActionResult
  -	OK         = new ValidatorActionResult ("OK");          // 0
  -    
  -	/**
  -	 * some error occurred, this is a result that is never set but
  -	 * serves as a comparison target. 
  -	 */
  +    OK         = new ValidatorActionResult ("OK");          // 0
  +
  +    /**
  +     * some error occurred, this is a result that is never set but
  +     * serves as a comparison target.
  +     */
       public static final ValidatorActionResult
  -	ERROR      = new ValidatorActionResult ("ERROR");       // 1
  +    ERROR      = new ValidatorActionResult ("ERROR");       // 1
   
  -	/**
  -	 * the parameter is null but isn't allowed to.
  -	 */
  +    /**
  +     * the parameter is null but isn't allowed to.
  +     */
       public static final ValidatorActionResult
  -	ISNULL     = new ValidatorActionResult ("ISNULL");      // 2
  +    ISNULL     = new ValidatorActionResult ("ISNULL");      // 2
   
  -	/**
  -	 * either value or length in case of a string is less than the
  -	 * specified minimum.
  -	 */
  +    /**
  +     * either value or length in case of a string is less than the
  +     * specified minimum.
  +     */
       public static final ValidatorActionResult
  -	TOOSMALL   = new ValidatorActionResult ("TOOSMALL");    // 3
  +    TOOSMALL   = new ValidatorActionResult ("TOOSMALL");    // 3
   
  -	/**
  -	 * either value or length in case of a string is greater than
  -	 * the specified maximum.
  -	 */
  +    /**
  +     * either value or length in case of a string is greater than
  +     * the specified maximum.
  +     */
       public static final ValidatorActionResult
  -	TOOLARGE   = new ValidatorActionResult ("TOOLARGE");    // 4
  +    TOOLARGE   = new ValidatorActionResult ("TOOLARGE");    // 4
   
  -	/**
  -	 * a string parameter's value is not matched by the specified
  -	 * regular expression.
  -	 */
  +    /**
  +     * a string parameter's value is not matched by the specified
  +     * regular expression.
  +     */
       public static final ValidatorActionResult
  -	NOMATCH    = new ValidatorActionResult ("NOMATCH");     // 5
  +    NOMATCH    = new ValidatorActionResult ("NOMATCH");     // 5
   
  -	/**
  -	 * this is returned when the result of a validation is
  -	 * requested but no such result is found in the request
  -	 * attribute.
  -	 */
  +    /**
  +     * this is returned when the result of a validation is
  +     * requested but no such result is found in the request
  +     * attribute.
  +     */
       public static final ValidatorActionResult
  -	NOTPRESENT = new ValidatorActionResult ("NOTPRESENT");  // 6
  +    NOTPRESENT = new ValidatorActionResult ("NOTPRESENT");  // 6
   
       /**
        * Make constructor private to inhibit creation outside.
        */
       private ValidatorActionResult (String image) {
  -	super (image);
  +    super (image);
       }
       private ValidatorActionResult () {
  -	super ();
  +    super ();
       }
   }
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/AggregatedCacheValidity.java
  
  Index: AggregatedCacheValidity.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/AggregatedCacheValidity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AggregatedCacheValidity.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ AggregatedCacheValidity.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   import java.util.ArrayList;
  @@ -15,7 +63,7 @@
    * A validation object using a List.
    *
    * @author <a href="mailto:dims@yahoo.com">Davanum Srinivas</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class AggregatedCacheValidity
   implements CacheValidity {
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/CacheValidity.java
  
  Index: CacheValidity.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/CacheValidity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CacheValidity.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ CacheValidity.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   /**
  @@ -14,7 +62,7 @@
    * xml file in this container.
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public interface CacheValidity extends java.io.Serializable {
   
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/Cacheable.java
  
  Index: Cacheable.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/Cacheable.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- Cacheable.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ Cacheable.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   /**
  @@ -12,7 +60,7 @@
    *
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public interface Cacheable {
   
  
  
  
  1.3       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/CachedEventObject.java
  
  Index: CachedEventObject.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/CachedEventObject.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- CachedEventObject.java	22 Jan 2002 00:17:11 -0000	1.2
  +++ CachedEventObject.java	4 Feb 2002 09:12:49 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   import java.util.Map;
  @@ -13,7 +61,7 @@
    * This is an cached object as it is stored in the <code>EventCache</code>
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2002/01/22 00:17:11 $
  + * @version CVS $Revision: 1.3 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class CachedEventObject implements java.io.Serializable {
   
  
  
  
  1.3       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/CachedStreamObject.java
  
  Index: CachedStreamObject.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/CachedStreamObject.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- CachedStreamObject.java	22 Jan 2002 00:17:11 -0000	1.2
  +++ CachedStreamObject.java	4 Feb 2002 09:12:49 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   import java.util.Map;
  @@ -13,7 +61,7 @@
    * This is an cached object as it is stored in the <code>StreamCache</code>
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2002/01/22 00:17:11 $
  + * @version CVS $Revision: 1.3 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class CachedStreamObject implements java.io.Serializable {
   
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/CachingOutputStream.java
  
  Index: CachingOutputStream.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/CachingOutputStream.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CachingOutputStream.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ CachingOutputStream.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   import java.io.IOException;
  @@ -16,7 +64,7 @@
    * TeeOutputStream.
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   
   public final class CachingOutputStream
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/ComponentCacheKey.java
  
  Index: ComponentCacheKey.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/ComponentCacheKey.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ComponentCacheKey.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ ComponentCacheKey.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   /**
  @@ -16,7 +64,7 @@
    *      is unique inside the component space.
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class ComponentCacheKey implements java.io.Serializable {
   
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/CompositeCacheValidity.java
  
  Index: CompositeCacheValidity.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/CompositeCacheValidity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CompositeCacheValidity.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ CompositeCacheValidity.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   
  @@ -13,7 +61,7 @@
    * A validation object using a Hashmap.
    *
    * @author <a href="mailto:dims@yahoo.com">Davanum Srinivas</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class CompositeCacheValidity
   implements CacheValidity {
  
  
  
  1.3       +55 -7     xml-cocoon2/src/java/org/apache/cocoon/caching/DeltaTimeCacheValidity.java
  
  Index: DeltaTimeCacheValidity.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/DeltaTimeCacheValidity.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DeltaTimeCacheValidity.java	2 Feb 2002 04:00:26 -0000	1.2
  +++ DeltaTimeCacheValidity.java	4 Feb 2002 09:12:49 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   import java.util.Date;
  
  
  
  1.3       +55 -7     xml-cocoon2/src/java/org/apache/cocoon/caching/IncludeCacheValidity.java
  
  Index: IncludeCacheValidity.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/IncludeCacheValidity.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- IncludeCacheValidity.java	25 Jan 2002 03:35:53 -0000	1.2
  +++ IncludeCacheValidity.java	4 Feb 2002 09:12:49 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   import org.apache.cocoon.environment.Source;
  
  
  
  1.3       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/NOPCacheValidity.java
  
  Index: NOPCacheValidity.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/NOPCacheValidity.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- NOPCacheValidity.java	8 Jan 2002 10:47:45 -0000	1.2
  +++ NOPCacheValidity.java	4 Feb 2002 09:12:49 -0000	1.3
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   /**
  @@ -12,7 +60,7 @@
    * This might be the most used CacheValidity object for serializers.
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.2 $ $Date: 2002/01/08 10:47:45 $
  + * @version CVS $Revision: 1.3 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class NOPCacheValidity
   implements CacheValidity {
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/ParametersCacheValidity.java
  
  Index: ParametersCacheValidity.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/ParametersCacheValidity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ParametersCacheValidity.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ ParametersCacheValidity.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   import java.util.HashMap;
  @@ -13,7 +61,7 @@
    * A validation object using a Hashmap.
    *
    * @author <a href="mailto:dims@yahoo.com">Davanum Srinivas</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class ParametersCacheValidity
   implements CacheValidity {
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/PipelineCacheKey.java
  
  Index: PipelineCacheKey.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/PipelineCacheKey.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- PipelineCacheKey.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ PipelineCacheKey.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   import java.util.ArrayList;
  @@ -15,7 +63,7 @@
    * or more <code>ComponentCacheKey</code> objects.
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class PipelineCacheKey {
   
  
  
  
  1.2       +56 -8     xml-cocoon2/src/java/org/apache/cocoon/caching/TimeStampCacheValidity.java
  
  Index: TimeStampCacheValidity.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/caching/TimeStampCacheValidity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- TimeStampCacheValidity.java	3 Jan 2002 12:31:08 -0000	1.1
  +++ TimeStampCacheValidity.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.caching;
   
   /**
  @@ -12,7 +60,7 @@
    * This is might be the most used CacheValidity object.
    *
    * @author <a href="mailto:cziegeler@apache.org">Carsten Ziegeler</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:08 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public final class TimeStampCacheValidity
   implements CacheValidity {
  
  
  
  1.2       +55 -7     xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/CookieCreatorAction.java
  
  Index: CookieCreatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/CookieCreatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CookieCreatorAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ CookieCreatorAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   
  
  
  
  1.2       +55 -7     xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/CookieValidatorAction.java
  
  Index: CookieValidatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/CookieValidatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CookieValidatorAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ CookieValidatorAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.framework.configuration.Configuration;
  
  
  
  1.2       +56 -8     xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/DatabaseCookieAuthenticatorAction.java
  
  Index: DatabaseCookieAuthenticatorAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/DatabaseCookieAuthenticatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DatabaseCookieAuthenticatorAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ DatabaseCookieAuthenticatorAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import org.apache.avalon.excalibur.datasource.DataSourceComponent;
  @@ -61,7 +109,7 @@
    * @version
    */
   public class DatabaseCookieAuthenticatorAction extends AbstractDatabaseAction implements ThreadSafe {
  -    
  +
       /**
        *  Main invocation routine.
        *
  
  
  
  1.2       +126 -78   xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAction.java
  
  Index: ModularDatabaseAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ModularDatabaseAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ ModularDatabaseAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import java.io.IOException;
  @@ -68,7 +116,7 @@
   /**
    * Adds record in a database. The action can update one or more tables,
    * and can add more than one row to a table at a time. The form descriptor
  - * semantics for this are still in a bit of a state of flux. 
  + * semantics for this are still in a bit of a state of flux.
    *
    * The difference to the other Database*Actions is, that it uses
    * additional components for reading and writing parameters. In
  @@ -86,9 +134,9 @@
    * components can utilize the helper components.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:35 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
  -public abstract class ModularDatabaseAction extends AbstractDatabaseAction 
  +public abstract class ModularDatabaseAction extends AbstractDatabaseAction
       implements Disposable, ThreadSafe, Contextualizable {
   
       // ========================================================================
  @@ -109,7 +157,7 @@
   
       /**
        * Structure that takes all processed data for a table depending
  -     * on current default modes 
  +     * on current default modes
        */
       protected class CacheHelper {
           /**
  @@ -118,17 +166,17 @@
           public String queryString = null;
           /**
            * if a set is used, column number which is used to determine
  -         * the number of rows to insert. 
  +         * the number of rows to insert.
            */
           public int setMaster = -1;
           public boolean isSet = false;
           public int noOfKeys = 0;
           public Column[] columns = null;
  -        
  +
           public CacheHelper( int cols ) {
               this(0,cols);
           }
  -        
  +
           public CacheHelper( int keys, int cols ) {
               noOfKeys = keys;
               columns = new Column[cols];
  @@ -147,7 +195,7 @@
       protected class LookUpKey {
           public Configuration tableConf = null;
           public Map modeTypes = null;
  -        
  +
           public LookUpKey( Configuration tableConf, Map modeTypes ) {
               this.tableConf = tableConf;
               this.modeTypes = modeTypes;
  @@ -221,7 +269,7 @@
       public void compose( ComponentManager manager ) throws ComponentException {
   
           super.compose( manager );
  -        if (getLogger().isDebugEnabled()) 
  +        if (getLogger().isDebugEnabled())
               getLogger().debug("compose");
           this.manager2 = new ExcaliburComponentManager(manager);
           this.manager2.setLogger(getLogger());
  @@ -336,32 +384,32 @@
                       }
                   }
               }
  -            
  +
               this.modeMapping.initialize();
               this.outputMapping.initialize();
               this.manager2.initialize();
  -            
  +
               ListIterator li = hints.listIterator();
               while ( li.hasNext() ) {
                   String modeName = (String) li.next();
                   Component helper = modeMapping.select( modeName );
  -                if ( !defaultModeNames.containsKey( MODE_OTHERS ) && helper instanceof AttributeHelper ) { 
  +                if ( !defaultModeNames.containsKey( MODE_OTHERS ) && helper instanceof AttributeHelper ) {
                       defaultModeNames.put( MODE_OTHERS, modeName );
                       if (getLogger().isDebugEnabled())
                           getLogger().debug(modeName + " default mode for normal columns");
                   }
  -                
  -                if ( !defaultModeNames.containsKey( MODE_AUTOINCR ) && helper instanceof AutoIncrementHelper ) { 
  +
  +                if ( !defaultModeNames.containsKey( MODE_AUTOINCR ) && helper instanceof AutoIncrementHelper ) {
                       defaultModeNames.put( MODE_AUTOINCR, modeName );
                       if (getLogger().isDebugEnabled())
                           getLogger().debug(modeName + " default mode for autoincrement columns");
                   }
                   modeMapping.release(helper);
               }
  -            
  -            if ( !defaultModeNames.containsKey( MODE_OTHERS ) || 
  -                 !defaultModeNames.containsKey( MODE_AUTOINCR ) || 
  -                 !defaultModeNames.containsKey( MODE_OUTPUT ) 
  +
  +            if ( !defaultModeNames.containsKey( MODE_OTHERS ) ||
  +                 !defaultModeNames.containsKey( MODE_AUTOINCR ) ||
  +                 !defaultModeNames.containsKey( MODE_OUTPUT )
                    ) {
                   throw new ConfigurationException("Not all default modes are configured:"
                                                    + ( defaultModeNames.containsKey( MODE_AUTOINCR ) ? " insert mode" : "" )
  @@ -369,13 +417,13 @@
                                                    + ( defaultModeNames.containsKey( MODE_OUTPUT ) ? " output" : "" )
                                                    );
               }
  -            
  +
           } catch (Exception e) {
               throw new ConfigurationException(e.toString());
           }
       }
  -    
  -    
  +
  +
       /**
        * Load a component.
        *
  @@ -383,7 +431,7 @@
        * @param classURL component's class name / URL
        * @param config configuration for this component
        */
  -    private void load_component( ExcaliburComponentSelector selector, Object hint, 
  +    private void load_component( ExcaliburComponentSelector selector, Object hint,
                                    String classURL, Configuration config ) throws Exception {
   
           Class clazz = null;
  @@ -402,7 +450,7 @@
       }
   
   
  -    
  +
       /**
        * Helper to read in a class
        */
  @@ -441,7 +489,7 @@
   
       /**
        * override super's method since we prefer to get the datasource
  -     * from defaults first or from sitemap parameters rather than from 
  +     * from defaults first or from sitemap parameters rather than from
        * descriptor file.
        */
       protected DataSourceComponent getDataSource( Configuration conf, Parameters parameters )
  @@ -461,7 +509,7 @@
       /**
        * Store a key/value pair in the request attributes. We prefix the key
        * with the name of this class to prevent potential name collisions.
  -     * This method overrides super class' method to allow an OutputHelper 
  +     * This method overrides super class' method to allow an OutputHelper
        * to take care of what to do with the values.
        */
       void setRequestAttribute(Request request, String key, Object value) {
  @@ -473,8 +521,8 @@
           } catch (Exception e) {
                   if (getLogger().isWarnEnabled())
                       getLogger()
  -                        .warn( "Could not select output mode " 
  -                               + (String) defaultModeNames.get( MODE_OUTPUT ) 
  +                        .warn( "Could not select output mode "
  +                               + (String) defaultModeNames.get( MODE_OUTPUT )
                                  + ":" + e.getMessage() );
           }
       }
  @@ -482,7 +530,7 @@
   
       /**
        * Retrieve a value from the request attributes.
  -     * This method overrides super class' method to allow an OutputHelper 
  +     * This method overrides super class' method to allow an OutputHelper
        * to take care of where to get the values.
        */
       Object getRequestAttribute(Request request, String key) {
  @@ -501,7 +549,7 @@
           }
           return value;
       }
  -    
  +
   
       // ========================================================================
       // main method
  @@ -513,7 +561,7 @@
        * the file referenced by the "descriptor" parameter conforms
        * to the AbstractDatabaseAction specifications.
        */
  -    public Map act( Redirector redirector, SourceResolver resolver, Map objectModel, 
  +    public Map act( Redirector redirector, SourceResolver resolver, Map objectModel,
                       String source, Parameters param ) throws Exception {
   
           DataSourceComponent datasource = null;
  @@ -523,16 +571,16 @@
           // read global parameter settings
           boolean reloadable = Constants.DESCRIPTOR_RELOADABLE_DEFAULT;
           Request request = (Request) objectModel.get(Constants.REQUEST_OBJECT);
  -        
  +
           if (this.settings.containsKey("reloadable"))
               reloadable = Boolean.getBoolean((String) this.settings.get("reloadable"));
           // read local parameter settings
           try {
  -            Configuration conf = 
  -                this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")), 
  +            Configuration conf =
  +                this.getConfiguration(param.getParameter("descriptor", (String) this.settings.get("descriptor")),
                                         resolver,
                                         param.getParameterAsBoolean("reloadable",reloadable));
  -            
  +
               datasource = this.getDataSource(conf, param);
               conn = datasource.getConnection();
               if (conn.getAutoCommit() == true) {
  @@ -541,7 +589,7 @@
                   } catch (Exception ex) {
                       String tmp = param.getParameter("use-transactions",(String) this.settings.get("use-transactions",null));
                       if (tmp != null &&  (tmp.equalsIgnoreCase("no") || tmp.equalsIgnoreCase("false") || tmp.equalsIgnoreCase("0"))) {
  -                        if (getLogger().isErrorEnabled()) 
  +                        if (getLogger().isErrorEnabled())
                               getLogger().error("This DB connection does not support transactions. If you want to risk your data's integrity by continuing nonetheless set parameter \"use-transactions\" to \"no\".");
                           throw ex;
                       }
  @@ -551,7 +599,7 @@
               Configuration[] tables = conf.getChildren("table");
               String tablesetname = param.getParameter("table-set", (String) this.settings.get("table-set"));
               Map set_tables = null; // default to old behaviour
  -            
  +
               HashMap modeTypes = null;
   
               if (tablesetname != null) {
  @@ -559,7 +607,7 @@
                   Configuration[] tablesets = conf.getChildren("table-set");
                   String setname = null;
                   boolean found = false;
  -                
  +
                   // find tables contained in tableset
                   int j = 0;
                   for (j=0; j<tablesets.length; j++) {
  @@ -572,9 +620,9 @@
                   if (!found) {
                       throw new IOException(" given set " + tablesetname + " does not exists in a description file.");
                   }
  -                
  +
                   Configuration[] set = tablesets[j].getChildren("table");
  -        
  +
                   // construct a Map that contains the names of the tables
                   // contained in the requested tableset
                   set_tables = new HashMap(set.length);
  @@ -591,7 +639,7 @@
                   modeTypes.put( MODE_OTHERS, "others" );
               };
               for (int i=0; i<tables.length; i++) {
  -                if ( set_tables == null || 
  +                if ( set_tables == null ||
                        set_tables.containsKey( tables[i].getAttribute( "name" ) ) ||
                        ( tables[i].getAttribute( "alias", null ) != null && set_tables.containsKey( tables[i].getAttribute( "alias" ) ) )
                        ) {
  @@ -601,7 +649,7 @@
                       processTable( tables[i], conn, request, results, modeTypes );
                   }
               }
  -            
  +
               if (conn.getAutoCommit()==false)
                   conn.commit();
               OutputHelper oh = (OutputHelper) outputMapping.select( (String) defaultModeNames.get( MODE_OUTPUT ) );
  @@ -625,10 +673,10 @@
               //throw new ProcessingException("Could not add record :position = " + currentIndex, e);
   
               // don't throw an exception, an error has been signalled, that should suffice
  -        
  -            String throwException = (String) this.settings.get( "throw-exception", 
  +
  +            String throwException = (String) this.settings.get( "throw-exception",
                                                                   param.getParameter( "throw-exception", null ) );
  -            if ( throwException != null && 
  +            if ( throwException != null &&
                    ( throwException.equalsIgnoreCase( "true" ) || throwException.equalsIgnoreCase( "yes" ) ) ) {
                   throw new ProcessingException("Could not add record",e);
               }
  @@ -640,11 +688,11 @@
                       getLogger().warn("There was an error closing the datasource", sqe);
                   }
               }
  -            
  -            if (datasource != null) 
  +
  +            if (datasource != null)
                   this.dbselector.release(datasource);
           }
  -        
  +
           return Collections.unmodifiableMap(results);
       }
   
  @@ -658,8 +706,8 @@
        * @param conn the database connection
        * @param request the request
        */
  -    protected void processTable( Configuration table, Connection conn, Request request, 
  -                                 Map results, HashMap modeTypes ) 
  +    protected void processTable( Configuration table, Connection conn, Request request,
  +                                 Map results, HashMap modeTypes )
           throws SQLException, ConfigurationException, Exception {
   
           PreparedStatement statement = null;
  @@ -668,9 +716,9 @@
               if (getLogger().isDebugEnabled())
                   getLogger().debug("query: "+queryData.queryString);
               statement = conn.prepareStatement(queryData.queryString);
  -            
  +
               Object[][] columnValues = this.getColumnValues( table, queryData, request );
  -            
  +
               int setLength = 1;
               if ( queryData.isSet ) {
                   if ( columnValues[ queryData.setMaster ] != null ) {
  @@ -679,13 +727,13 @@
                       setLength = 0;
                   }
               }
  -            
  +
               for ( int rowIndex = 0; rowIndex < setLength; rowIndex++ ) {
                   if (getLogger().isDebugEnabled())
                       getLogger().debug( "====> row no. " + rowIndex );
                   processRow( request, conn, statement, table, queryData, columnValues, rowIndex, results );
               }
  -            
  +
           } finally {
               try {
                   if (statement != null) {
  @@ -695,7 +743,7 @@
           }
       }
   
  -    
  +
       /**
        * Choose a mode configuration based on its name.
        * @param conf Configuration (i.e. a column's configuration) that might have
  @@ -705,13 +753,13 @@
        * Special mode "all" matches all queried types.
        * @return configuration that has desired type or type "all" or null.
        */
  -    protected Configuration getMode( Configuration conf, String type ) 
  +    protected Configuration getMode( Configuration conf, String type )
           throws ConfigurationException {
   
           String modeAll = "all";
           Configuration[] modes = conf.getChildren("mode");
           Configuration modeConfig = null;;
  -        
  +
           for ( int i=0; i<modes.length; i++ ) {
               String modeType = modes[i].getAttribute("type", "others");
               if ( modeType.equals(type) || modeType.equals(modeAll)) {
  @@ -721,7 +769,7 @@
                   break;
               };
           }
  -        
  +
           return modeConfig;
       }
   
  @@ -743,11 +791,11 @@
       protected String getOutputName ( Configuration tableConf, Configuration columnConf, int rowIndex )
           throws ConfigurationException {
   
  -        return ( tableConf.getAttribute("alias", tableConf.getAttribute("name") ) 
  -                 + "." + columnConf.getAttribute("name") 
  +        return ( tableConf.getAttribute("alias", tableConf.getAttribute("name") )
  +                 + "." + columnConf.getAttribute("name")
                    + ( rowIndex == -1 ? "" : "[" + rowIndex + "]" ) );
       }
  -    
  +
   
       /*
        * Read all values for a column from an AttributeHelper
  @@ -801,7 +849,7 @@
           String setMastersMode = null;
           boolean manyrows = false;
           int offset = ( isKey ? 0: set.noOfKeys);
  -        
  +
           for ( int i = offset; i < conf.length + offset; i++ ) {
               if (getLogger().isDebugEnabled())
                   getLogger().debug("i="+i);
  @@ -815,10 +863,10 @@
                       set.columns[i].isAutoIncrement = true;
                   }
               }
  -            set.columns[i].modeConf = getMode( set.columns[i].columnConf, 
  +            set.columns[i].modeConf = getMode( set.columns[i].columnConf,
                                                  selectMode( set.columns[i].isAutoIncrement, modeTypes ) );
  -            set.columns[i].mode = ( set.columns[i].modeConf != null ? 
  -                                    set.columns[i].modeConf.getAttribute( "name", selectMode( isKey, defaultModeNames ) ) :  
  +            set.columns[i].mode = ( set.columns[i].modeConf != null ?
  +                                    set.columns[i].modeConf.getAttribute( "name", selectMode( isKey, defaultModeNames ) ) :
                                       selectMode( isKey, defaultModeNames ) );
               // Determine set mode for a whole column ...
               setMode = set.columns[i].columnConf.getAttribute("set", null);  // master vs slave vs null
  @@ -833,7 +881,7 @@
                   if ( setMode.equals("master") ) {
                       set.setMaster = i;
                   }
  -            } 
  +            }
           }
       }
   
  @@ -842,8 +890,8 @@
       /**
        * Put key values into request attributes.
        */
  -    protected void storeKeyValue( Configuration tableConf, Column key, int rowIndex, Connection conn, 
  -                                  Statement statement, Request request, Map results ) 
  +    protected void storeKeyValue( Configuration tableConf, Column key, int rowIndex, Connection conn,
  +                                  Statement statement, Request request, Map results )
           throws SQLException, ConfigurationException, ComponentException {
   
           AutoIncrementHelper dah = (AutoIncrementHelper) modeMapping.select( key.mode );
  @@ -873,7 +921,7 @@
        * @return the number of columns by which to increment the currentIndex
        */
       protected int setKeyAuto ( Configuration table, Column column, int currentIndex, int rowIndex,
  -                               Connection conn, PreparedStatement statement, Request request, Map results ) 
  +                               Connection conn, PreparedStatement statement, Request request, Map results )
           throws ConfigurationException, SQLException, ComponentException, Exception {
   
           int columnCount = 0;
  @@ -893,7 +941,7 @@
           } else {
               if (getLogger().isDebugEnabled())
                   getLogger().debug( "Automatically setting key" );
  -        }  
  +        }
           modeMapping.release( dah );
           return columnCount;
       }
  @@ -913,7 +961,7 @@
                                           Configuration table, CacheHelper queryData, Object[][] columnValues,
                                           int rowIndex, Map results )
           throws SQLException, ConfigurationException, Exception;
  -    
  +
       /**
        * determine which mode to use as default mode
        *
  @@ -954,7 +1002,7 @@
        * @param table the table's configuration object
        * @return the insert query as a string
        */
  -    protected abstract CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames ) 
  +    protected abstract CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames )
           throws ConfigurationException, ComponentException;
   
   }
  
  
  
  1.2       +76 -28    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAddAction.java
  
  Index: ModularDatabaseAddAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAddAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ModularDatabaseAddAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ ModularDatabaseAddAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import java.util.Map;
  @@ -24,7 +72,7 @@
   /**
    * Adds record in a database. The action can update one or more tables,
    * and can add more than one row to a table at a time. The form descriptor
  - * semantics for this are still in a bit of a state of flux. 
  + * semantics for this are still in a bit of a state of flux.
    *
    * The difference to the other Database*Actions is, that it uses
    * additional components for reading and writing parameters. In
  @@ -38,7 +86,7 @@
    * components can utilize the helper components.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:35 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public class ModularDatabaseAddAction extends ModularDatabaseAction {
   
  @@ -48,19 +96,19 @@
        */
       protected void processRow ( Request request, Connection conn, PreparedStatement statement,
                                   Configuration table, CacheHelper queryData, Object[][] columnValues,
  -                                int rowIndex, Map results ) 
  +                                int rowIndex, Map results )
           throws SQLException, ConfigurationException, Exception {
  -    
  +
           int currentIndex = 1;
           for (int i = 0; i < queryData.columns.length; i++) {
               Column col = queryData.columns[i];
               if ( col.isAutoIncrement && col.isKey ) {
  -                currentIndex += setKeyAuto( table, col, currentIndex, rowIndex, 
  +                currentIndex += setKeyAuto( table, col, currentIndex, rowIndex,
                                               conn, statement, request, results );
               } else {
  -                this.setColumn( statement, currentIndex, request, col.columnConf, 
  +                this.setColumn( statement, currentIndex, request, col.columnConf,
                                   getOutputName( table, col.columnConf, rowIndex ),
  -                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ], 
  +                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ],
                                   rowIndex);
                   currentIndex++;
               }
  @@ -69,7 +117,7 @@
           // get resulting ids for autoincrement columns
           for (int i = 0; i < queryData.columns.length; i++) {
               if ( queryData.columns[i].isAutoIncrement && queryData.columns[i].isKey ) {
  -                storeKeyValue( table, queryData.columns[i], rowIndex, 
  +                storeKeyValue( table, queryData.columns[i], rowIndex,
                                  conn, statement, request, results );
               }
           }
  @@ -85,7 +133,7 @@
   
           if ( isAutoIncrement )
               return (String) modes.get( MODE_AUTOINCR );
  -        else 
  +        else
               return (String) modes.get( MODE_OTHERS );
       }
   
  @@ -102,7 +150,7 @@
        * database operation.
        */
       protected Object[][] getColumnValues( Configuration tableConf, CacheHelper queryData,
  -                                          Request request ) 
  +                                          Request request )
           throws ConfigurationException, ComponentException {
   
           Object[][] columnValues = new Object[ queryData.columns.length ][];
  @@ -112,7 +160,7 @@
           return columnValues;
       }
   
  -    
  +
       /**
        * Get the String representation of the PreparedStatement.  This is
        * mapped to the Configuration object itself, so if it doesn't exist,
  @@ -120,7 +168,7 @@
        * @param table the table's configuration object
        * @return the insert query as a string
        */
  -    protected CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames ) 
  +    protected CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames )
           throws ConfigurationException, ComponentException {
   
           LookUpKey lookUpKey = new LookUpKey( table, modeTypes );
  @@ -135,11 +183,11 @@
                   queryData = new CacheHelper( keys.length, keys.length + values.length );
                   fillModes( keys,   true,  defaultModeNames, modeTypes, queryData );
                   fillModes( values, false, defaultModeNames, modeTypes, queryData );
  -                
  +
                   StringBuffer queryBuffer = new StringBuffer("INSERT INTO ");
                   StringBuffer valueBuffer = new StringBuffer(") VALUES (");
                   AutoIncrementHelper dah;
  -                
  +
                   queryBuffer.append(table.getAttribute("name"));
                   queryBuffer.append(" (");
                   int actualColumns = 0;
  @@ -157,8 +205,8 @@
                               if ( dah.includeAsValue() ) {
                                   valueBuffer.append( "?" );
                               } else {
  -                                valueBuffer.append( 
  -                                                   dah.getSubquery( table, queryData.columns[i].columnConf, 
  +                                valueBuffer.append(
  +                                                   dah.getSubquery( table, queryData.columns[i].columnConf,
                                                                       queryData.columns[i].modeConf ) );
                               }
                           }
  @@ -169,18 +217,18 @@
                           valueBuffer.append( "?" );
                       }
                   }
  -                
  +
                   valueBuffer.append(")");
                   queryBuffer.append(valueBuffer);
  -                
  +
                   queryData.queryString = queryBuffer.toString();
  -                
  +
                   this.cachedQueryData.put( lookUpKey, queryData );
               }
           }
  -        
  +
           return queryData;
       }
  -    
  +
   
   }
  
  
  
  1.2       +70 -22    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseDeleteAction.java
  
  Index: ModularDatabaseDeleteAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseDeleteAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ModularDatabaseDeleteAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ ModularDatabaseDeleteAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import java.util.Map;
  @@ -23,13 +71,13 @@
    * Updates a record in a database. The action can update one or more
    * tables, and can update more than one row to a table at a time. The
    * form descriptor semantics for this are still in a bit of a state of
  - * flux. 
  + * flux.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:35 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public class ModularDatabaseDeleteAction extends ModularDatabaseAction {
  -    
  +
       /**
        * determine which mode to use as default mode
        * here: DELETE
  @@ -76,7 +124,7 @@
        * @param table the table's configuration object
        * @return the insert query as a string
        */
  -    protected CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames ) 
  +    protected CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames )
           throws ConfigurationException, ComponentException {
   
           LookUpKey lookUpKey = new LookUpKey( table, modeTypes );
  @@ -85,10 +133,10 @@
               queryData = (CacheHelper) this.cachedQueryData.get( lookUpKey );
               if (queryData == null) {
                   Configuration[] keys = table.getChild("keys").getChildren("key");
  -                
  +
                   queryData = new CacheHelper( keys.length, keys.length );
                   fillModes( keys, true, defaultModeNames, modeTypes, queryData );
  -                
  +
                   StringBuffer queryBuffer = new StringBuffer("DELETE FROM ");
                   queryBuffer.append(table.getAttribute("name")).append(" WHERE ");
                   for (int i = 0; i < queryData.columns.length; i++) {
  @@ -99,16 +147,16 @@
                           .append( queryData.columns[i].columnConf.getAttribute( "name" ) )
                           .append( "= ?" );
                   }
  -                
  +
                   queryData.queryString = queryBuffer.toString();
  -                
  +
                   this.cachedQueryData.put( lookUpKey, queryData );
               }
           }
  -        
  +
           return queryData;
       }
  -    
  +
   
   
       /**
  @@ -118,21 +166,21 @@
                                   Configuration table, CacheHelper queryData, Object[][] columnValues,
                                   int rowIndex, Map results )
           throws SQLException, ConfigurationException, Exception {
  -    
  +
           int currentIndex = 1;
  -        
  +
           // ordering is different for DELETE just needs keys
           for (int i = 0; i < queryData.columns.length; i++) {
               Column col = queryData.columns[i];
               if ( col.isKey ) {
  -                this.setColumn( statement, currentIndex, request, col.columnConf, 
  +                this.setColumn( statement, currentIndex, request, col.columnConf,
                                   getOutputName( table, col.columnConf, rowIndex ),
  -                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ], 
  +                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ],
                                   rowIndex);
                   currentIndex++;
               }
           }
           statement.execute();
       }
  -    
  +
   }
  
  
  
  1.2       +74 -26    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseSelectAction.java
  
  Index: ModularDatabaseSelectAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseSelectAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ModularDatabaseSelectAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ ModularDatabaseSelectAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import java.util.Map;
  @@ -34,7 +82,7 @@
    * a state of flux.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:35 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public class ModularDatabaseSelectAction extends ModularDatabaseAction {
   
  @@ -64,7 +112,7 @@
        * @param table the table's configuration object
        * @return the insert query as a string
        */
  -    protected CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames ) 
  +    protected CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames )
           throws ConfigurationException, ComponentException {
   
           LookUpKey lookUpKey = new LookUpKey( table, modeTypes );
  @@ -78,9 +126,9 @@
                   queryData = new CacheHelper( keys.length, keys.length );
                   fillModes( keys, true, defaultModeNames, modeTypes, queryData );
                   fillModes( values, false, defaultModeNames, modeTypes, queryData );
  -                
  +
                   StringBuffer queryBuffer = new StringBuffer("SELECT ");
  -                
  +
                   queryBuffer.append(table.getAttribute("name")).append(" WHERE ");
                   for (int i = 0; i < queryData.columns.length; i++) {
                       if ( !queryData.columns[i].isKey ) {
  @@ -91,7 +139,7 @@
                               .append( queryData.columns[i].columnConf.getAttribute( "name" ) );
                       }
                   }
  -                
  +
                   queryBuffer.append(" FROM ").append(table.getAttribute("name")).append(" WHERE ");
                   for (int i = 0; i < queryData.columns.length; i++) {
                       if ( queryData.columns[i].isKey ) {
  @@ -103,17 +151,17 @@
                               .append( "= ?");
                       }
                   }
  -                
  +
                   queryData.queryString = queryBuffer.toString();
  -                
  +
                   this.cachedQueryData.put( lookUpKey, queryData );
               }
           }
  -        
  +
           return queryData;
       }
  -    
  -    
  +
  +
       /**
        * Fetch all values for all key columns that are needed to do the
        * database operation.
  @@ -139,16 +187,16 @@
       protected void processRow ( Request request, Connection conn, PreparedStatement statement, Configuration table,
                                   CacheHelper queryData, Object[][] columnValues, int rowIndex, Map results )
           throws SQLException, ConfigurationException, Exception {
  -    
  +
           int currentIndex = 1;
   
           // ordering is different for SELECT just needs keys
           for (int i = 0; i < queryData.columns.length; i++) {
               Column col = queryData.columns[i];
               if ( col.isKey ) {
  -                this.setColumn( statement, currentIndex, request, col.columnConf, 
  +                this.setColumn( statement, currentIndex, request, col.columnConf,
                                   getOutputName( table, col.columnConf, rowIndex ),
  -                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ], 
  +                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ],
                                   rowIndex);
                   currentIndex++;
               }
  @@ -170,18 +218,18 @@
               }
           }
       }
  -    
  -    
  +
  +
       /**
        * Get the Statement column so that the results are mapped correctly.
        * (this has been copied from AbstractDatabaseAction and modified slightly)
        */
       protected Object getColumn(ResultSet set, Configuration column ) throws Exception {
  -        
  +
           Integer type = (Integer) AbstractDatabaseAction.typeConstants.get(column.getAttribute("type"));
           String dbcol = column.getAttribute("name");
           Object value = null;
  -        
  +
           switch (type.intValue()) {
           case Types.CLOB:
               Clob dbClob = set.getClob(dbcol);
  @@ -241,13 +289,13 @@
           case Types.OTHER:
               value = set.getObject(dbcol);
               break;
  -            
  +
           default:
               // The blob types have to be requested separately, via a Reader.
               value = "";
               break;
           }
  -        
  +
           return value;
       }
   
  
  
  
  1.2       +73 -25    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseUpdateAction.java
  
  Index: ModularDatabaseUpdateAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseUpdateAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ModularDatabaseUpdateAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ ModularDatabaseUpdateAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting;
   
   import java.util.Map;
  @@ -23,10 +71,10 @@
    * Updates a record in a database. The action can update one or more
    * tables, and can update more than one row to a table at a time. The
    * form descriptor semantics for this are still in a bit of a state of
  - * flux. 
  + * flux.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:35 $
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
    */
   public class ModularDatabaseUpdateAction extends ModularDatabaseAction {
   
  @@ -71,7 +119,7 @@
        * @param table the table's configuration object
        * @return the insert query as a string
        */
  -    protected CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames ) 
  +    protected CacheHelper getQuery( Configuration table, HashMap modeTypes, HashMap defaultModeNames )
           throws ConfigurationException, ComponentException {
   
           LookUpKey lookUpKey = new LookUpKey( table, modeTypes );
  @@ -81,15 +129,15 @@
               if (queryData == null) {
                   Configuration[] keys = table.getChild("keys").getChildren("key");
                   Configuration[] values = table.getChild("values").getChildren("value");
  -                
  +
                   queryData = new CacheHelper( keys.length, keys.length + values.length );
                   fillModes( keys,   true,  defaultModeNames, modeTypes, queryData );
                   fillModes( values, false, defaultModeNames, modeTypes, queryData );
  -                
  +
                   StringBuffer queryBuffer = new StringBuffer("UPDATE ");
                   queryBuffer.append(table.getAttribute("name")).append(" SET ");
  -                
  -                
  +
  +
                   int cols = 0;
                   for (int i = 0; i < queryData.columns.length; i++) {
                       if ( !queryData.columns[i].isKey ) {
  @@ -113,17 +161,17 @@
                               .append( "= ?" );
                       }
                   }
  -                
  +
                   queryData.queryString = queryBuffer.toString();
  -                
  +
                   this.cachedQueryData.put( lookUpKey, queryData );
               }
           }
  -        
  +
           return queryData;
       }
  -    
  -    
  +
  +
       /**
        * set all necessary ?s and execute the query
        */
  @@ -131,16 +179,16 @@
                                   CacheHelper queryData, Object[][] columnValues, int rowIndex, Map results )
           throws SQLException, ConfigurationException, Exception {
   
  -    
  +
           int currentIndex = 1;
   
           // ordering is different for UPDATE than for INSERT: values, keys
           for (int i = 0; i < queryData.columns.length; i++) {
               Column col = queryData.columns[i];
               if ( !col.isKey ) {
  -                this.setColumn( statement, currentIndex, request, col.columnConf, 
  +                this.setColumn( statement, currentIndex, request, col.columnConf,
                                   getOutputName( table, col.columnConf, rowIndex ),
  -                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ], 
  +                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ],
                                   rowIndex);
                   currentIndex++;
               }
  @@ -148,14 +196,14 @@
           for (int i = 0; i < queryData.columns.length; i++) {
               Column col = queryData.columns[i];
               if ( col.isKey ) {
  -                this.setColumn( statement, currentIndex, request, col.columnConf, 
  +                this.setColumn( statement, currentIndex, request, col.columnConf,
                                   getOutputName( table, col.columnConf, rowIndex ),
  -                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ], 
  +                                columnValues[ i ][ ( col.isSet ? rowIndex : 0 ) ],
                                   rowIndex);
                   currentIndex++;
               }
           }
           statement.execute();
       }
  -    
  +
   }
  
  
  
  1.2       +222 -176  xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/SectionCutterAction.java
  
  Index: SectionCutterAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/SectionCutterAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- SectionCutterAction.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ SectionCutterAction.java	4 Feb 2002 09:12:49 -0000	1.2
  @@ -1,176 +1,222 @@
  -/*****************************************************************************
  - * 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.acting;
  -
  -import org.apache.avalon.framework.configuration.Configuration;
  -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.Constants;
  -import org.apache.cocoon.acting.ConfigurableComposerAction;
  -import org.apache.cocoon.environment.Redirector;
  -import org.apache.cocoon.environment.Request;
  -import org.apache.cocoon.environment.Session;
  -import org.apache.cocoon.environment.SourceResolver;
  -
  -import java.util.Collections;
  -import java.util.Dictionary;
  -import java.util.Enumeration;
  -import java.util.HashMap;
  -import java.util.Hashtable;
  -import java.util.Map;
  -import java.util.Vector;
  -
  -/**
  - *  An action designed to set any number of variables, based on the current site
  - *  section. The action matches the request uri against a configurable set of
  - *  regular expressions (note: currently not implemented. Checking the beggining
  - *  of the URI). When an expression matches, the action will set the configured
  - *  variable in the Map.
  - *
  - * @author     <a href="mailto:sergio.carvalho@acm.org?Subject=SectionCutterAction">
  - *      Sergio Carvalho</a>
  - * @version    CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:35 $
  - */
  -public class SectionCutterAction extends ConfigurableComposerAction implements ThreadSafe {
  -
  -    Vector sections = new Vector();
  -
  -    /**
  -     *  Description of the Method
  -     *
  -     * @param  conf                        Description of Parameter
  -     * @exception  ConfigurationException  Description of Exception
  -     */
  -    public void configure(Configuration conf)
  -        throws ConfigurationException {
  -        try {
  -            Configuration[] sectionConfigurations;
  -            sectionConfigurations = conf.getChildren("section");
  -
  -            for (int i = 0; i < sectionConfigurations.length; i++) {
  -                try {
  -                    if (getLogger().isDebugEnabled()) {
  -                        getLogger().debug("Creating one section");
  -                    }
  -                    sections.add(new Section(sectionConfigurations[i]));
  -                } catch (Exception e) {
  -                    getLogger().error("Failed configuring section", e);
  -                    if (getLogger().isDebugEnabled()) {
  -                        // In production, try to continue. Assume that one rotten section config can't stop the whole app.
  -                        // When debug is enabled, scream, screech and grind to a halt.
  -                        throw (e);
  -                    }
  -                }
  -            }
  -        } catch (Exception e) {
  -            throw new ConfigurationException("Cannot configure action", e);
  -        }
  -    }
  -
  -
  -    /**
  -     *  A simple Action that logs if the <code>Session</code> object has been
  -     *  created
  -     *
  -     * @param  redirector     Description of Parameter
  -     * @param  resolver       Description of Parameter
  -     * @param  objectModel    Description of Parameter
  -     * @param  src            Description of Parameter
  -     * @param  par            Description of Parameter
  -     * @return                Description of the Returned Value
  -     * @exception  Exception  Description of Exception
  -     */
  -    public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String src, Parameters par)
  -        throws Exception {
  -        Request request = (Request) objectModel.get(Constants.REQUEST_OBJECT);
  -        Map results = new HashMap();
  -        if (request != null) {
  -            boolean hasMatched = false;
  -
  -            if (getLogger().isDebugEnabled()) {
  -                getLogger().debug("Matching against '" + request.getSitemapURI() + "'");
  -            }
  -            for (Enumeration sectionsEnum = sections.elements(); sectionsEnum.hasMoreElements() && !hasMatched; ) {
  -                Section section = (Section) sectionsEnum.nextElement();
  -                if (section.matches(request.getSitemapURI())) {
  -                    if (getLogger().isDebugEnabled()) {
  -                        getLogger().debug("Matched '" + section.matchExpression + "'");
  -                    }
  -
  -                    section.fillMap(results);
  -                    hasMatched = true;
  -                }
  -            }
  -        } else {
  -            getLogger().warn("Request was null");
  -        }
  -
  -        return Collections.unmodifiableMap(results);
  -    }
  -
  -
  -    /**
  -     *  Description of the Class
  -     *
  -     * @author     subzero
  -     * @version
  -     */
  -    class Section extends Object {
  -        String matchExpression;
  -        Dictionary mapVars = new Hashtable();
  -
  -
  -        /**
  -         *  Constructor for the Section object
  -         *
  -         * @param  conf           Description of Parameter
  -         * @exception  Exception  Description of Exception
  -         */
  -        public Section(Configuration conf)
  -            throws Exception {
  -            matchExpression = conf.getAttribute("pattern");
  -
  -            Configuration[] variables;
  -            variables = conf.getChildren("set-var");
  -
  -            for (int i = 0; i < variables.length; i++) {
  -                mapVars.put(variables[i].getAttribute("name"), variables[i].getAttribute("value"));
  -            }
  -        }
  -
  -
  -        /**
  -         *  Description of the Method
  -         *
  -         * @param  expression  Description of Parameter
  -         * @return             Description of the Returned Value
  -         */
  -        public boolean matches(String expression) {
  -            return expression.startsWith(matchExpression);
  -        }
  -
  -
  -        /**
  -         *  Description of the Method
  -         *
  -         * @param  map  Description of Parameter
  -         */
  -        public void fillMap(Map map) {
  -            for (Enumeration keys = mapVars.keys(); keys.hasMoreElements(); ) {
  -                Object key = keys.nextElement();
  -                Object value = mapVars.get(key);
  -
  -                map.put(key, value);
  -            }
  -        }
  -    }
  -}
  -
  -
  -
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
  +package org.apache.cocoon.acting;
  +
  +import org.apache.avalon.framework.configuration.Configuration;
  +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.Constants;
  +import org.apache.cocoon.acting.ConfigurableComposerAction;
  +import org.apache.cocoon.environment.Redirector;
  +import org.apache.cocoon.environment.Request;
  +import org.apache.cocoon.environment.Session;
  +import org.apache.cocoon.environment.SourceResolver;
  +import java.util.Collections;
  +import java.util.Dictionary;
  +import java.util.Enumeration;
  +import java.util.HashMap;
  +import java.util.Hashtable;
  +import java.util.Map;
  +import java.util.Vector;
  +
  +/**
  + *  An action designed to set any number of variables, based on the current site
  + *  section. The action matches the request uri against a configurable set of
  + *  regular expressions (note: currently not implemented. Checking the beggining
  + *  of the URI). When an expression matches, the action will set the configured
  + *  variable in the Map.
  + *
  + * @author     <a href="mailto:sergio.carvalho@acm.org?Subject=SectionCutterAction">
  + *      Sergio Carvalho</a>
  + * @version    CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:49 $
  + */
  +
  +public class SectionCutterAction extends ConfigurableComposerAction implements ThreadSafe {
  +
  +    Vector sections = new Vector();
  +
  +    /**
  +     *  Description of the Method
  +     *
  +     * @param  conf                        Description of Parameter
  +     * @exception  ConfigurationException  Description of Exception
  +     */
  +    public void configure(Configuration conf)
  +        throws ConfigurationException {
  +        try {
  +            Configuration[] sectionConfigurations;
  +            sectionConfigurations = conf.getChildren("section");
  +
  +            for (int i = 0; i < sectionConfigurations.length; i++) {
  +                try {
  +                    if (getLogger().isDebugEnabled()) {
  +                        getLogger().debug("Creating one section");
  +                    }
  +                    sections.add(new Section(sectionConfigurations[i]));
  +                } catch (Exception e) {
  +                    getLogger().error("Failed configuring section", e);
  +                    if (getLogger().isDebugEnabled()) {
  +                        // In production, try to continue. Assume that one rotten section config can't stop the whole app.
  +                        // When debug is enabled, scream, screech and grind to a halt.
  +                        throw (e);
  +                    }
  +                }
  +            }
  +        } catch (Exception e) {
  +            throw new ConfigurationException("Cannot configure action", e);
  +        }
  +    }
  +
  +    /**
  +     *  A simple Action that logs if the <code>Session</code> object has been
  +     *  created
  +     *
  +     * @param  redirector     Description of Parameter
  +     * @param  resolver       Description of Parameter
  +     * @param  objectModel    Description of Parameter
  +     * @param  src            Description of Parameter
  +     * @param  par            Description of Parameter
  +     * @return                Description of the Returned Value
  +     * @exception  Exception  Description of Exception
  +     */
  +    public Map act(Redirector redirector, SourceResolver resolver, Map objectModel, String src, Parameters par)
  +        throws Exception {
  +        Request request = (Request) objectModel.get(Constants.REQUEST_OBJECT);
  +        Map results = new HashMap();
  +        if (request != null) {
  +            boolean hasMatched = false;
  +
  +            if (getLogger().isDebugEnabled()) {
  +                getLogger().debug("Matching against '" + request.getSitemapURI() + "'");
  +            }
  +            for (Enumeration sectionsEnum = sections.elements(); sectionsEnum.hasMoreElements() && !hasMatched; ) {
  +                Section section = (Section) sectionsEnum.nextElement();
  +                if (section.matches(request.getSitemapURI())) {
  +                    if (getLogger().isDebugEnabled()) {
  +                        getLogger().debug("Matched '" + section.matchExpression + "'");
  +                    }
  +
  +                    section.fillMap(results);
  +                    hasMatched = true;
  +                }
  +            }
  +        } else {
  +            getLogger().warn("Request was null");
  +        }
  +
  +        return Collections.unmodifiableMap(results);
  +    }
  +
  +    /**
  +     *  Description of the Class
  +     *
  +     * @author     subzero
  +     * @version
  +     */
  +    class Section extends Object {
  +        String matchExpression;
  +        Dictionary mapVars = new Hashtable();
  +
  +        /**
  +         *  Constructor for the Section object
  +         *
  +         * @param  conf           Description of Parameter
  +         * @exception  Exception  Description of Exception
  +         */
  +        public Section(Configuration conf)
  +            throws Exception {
  +            matchExpression = conf.getAttribute("pattern");
  +            Configuration[] variables;
  +            variables = conf.getChildren("set-var");
  +
  +            for (int i = 0; i < variables.length; i++) {
  +                mapVars.put(variables[i].getAttribute("name"), variables[i].getAttribute("value"));
  +            }
  +        }
  +
  +        /**
  +         *  Description of the Method
  +         *
  +         * @param  expression  Description of Parameter
  +         * @return             Description of the Returned Value
  +         */
  +        public boolean matches(String expression) {
  +            return expression.startsWith(matchExpression);
  +        }
  +
  +        /**
  +         *  Description of the Method
  +         *
  +         * @param  map  Description of Parameter
  +         */
  +        public void fillMap(Map map) {
  +            for (Enumeration keys = mapVars.keys(); keys.hasMoreElements(); ) {
  +                Object key = keys.nextElement();
  +                Object value = mapVars.get(key);
  +
  +                map.put(key, value);
  +            }
  +        }
  +    }
  +}
  +
  +
  +
  +
  +
  +
  +
  
  
  
  1.2       +59 -11    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AbstractAttributeHelper.java
  
  Index: AbstractAttributeHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AbstractAttributeHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractAttributeHelper.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ AbstractAttributeHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import org.apache.avalon.framework.activity.Disposable;
  @@ -21,9 +69,9 @@
    * Logger, use getLogger().
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:35 $ */
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:50 $ */
   public abstract class AbstractAttributeHelper extends AbstractLoggable
  -    implements AttributeHelper, Configurable, Disposable { 
  +    implements AttributeHelper, Configurable, Disposable {
   
       /**
        * Stores (global) configuration parameters as <code>key</code> /
  @@ -39,10 +87,10 @@
        * configuration option are not catered for. This way global
        * configuration options can be used.
        *
  -     * For nested configurations override this function.  
  +     * For nested configurations override this function.
        * */
       public void configure(Configuration conf) throws ConfigurationException {
  -        
  +
           if (conf != null) {
               String key = null;
               String val = null;
  
  
  
  1.2       +57 -9     xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AbstractAutoIncrementHelper.java
  
  Index: AbstractAutoIncrementHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AbstractAutoIncrementHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractAutoIncrementHelper.java	3 Jan 2002 12:31:35 -0000	1.1
  +++ AbstractAutoIncrementHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import org.apache.avalon.framework.activity.Disposable;
  @@ -21,7 +69,7 @@
    * getLogger().
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:35 $ */
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:50 $ */
   public abstract class AbstractAutoIncrementHelper extends AbstractLoggable
       implements AutoIncrementHelper, Configurable, Disposable {
   
  @@ -39,7 +87,7 @@
        * configuration option are not catered for. This way global
        * configuration options can be used.
        *
  -     * For nested configurations override this function. 
  +     * For nested configurations override this function.
        * */
       public void configure(Configuration conf) throws ConfigurationException {
   
  
  
  
  1.2       +58 -10    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AbstractOutputHelper.java
  
  Index: AbstractOutputHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AbstractOutputHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractOutputHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ AbstractOutputHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import org.apache.avalon.framework.activity.Disposable;
  @@ -21,9 +69,9 @@
    * Logger, use getLogger().
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Revision: 1.1 $ $Date: 2002/01/03 12:31:36 $ */
  + * @version CVS $Revision: 1.2 $ $Date: 2002/02/04 09:12:50 $ */
   public abstract class AbstractOutputHelper extends AbstractLoggable
  -    implements OutputHelper, Configurable, Disposable { 
  +    implements OutputHelper, Configurable, Disposable {
   
       /**
        * Stores (global) configuration parameters as <code>key</code> /
  @@ -39,7 +87,7 @@
        * configuration option are not catered for. This way global
        * configuration options can be used.
        *
  -     * For nested configurations override this function.  
  +     * For nested configurations override this function.
        * */
       public void configure(Configuration conf) throws ConfigurationException {
   
  
  
  
  1.2       +57 -9     xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AttributeHelper.java
  
  Index: AttributeHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AttributeHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AttributeHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ AttributeHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.util.SortedSet;
  @@ -21,14 +69,14 @@
    * attributes, session attributes &c.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: AttributeHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $
  + * @version CVS $Id: AttributeHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $
    * */
   public interface AttributeHelper extends Component {
   
       String ROLE = "org.apache.cocoon.acting.ModularDatabaseAccess.AttributeHelper";
   
   
  -    /** 
  +    /**
        * Standard access to an attribute's value. If more than one value
        * exists, the first is returned. If the value does not exist,
        * null is returned. To get all values, use {@link
  
  
  
  1.2       +62 -14    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AutoIncrementHelper.java
  
  Index: AutoIncrementHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/AutoIncrementHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AutoIncrementHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ AutoIncrementHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.sql.Connection;
  @@ -20,13 +68,13 @@
    * attribute columns.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: AutoIncrementHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $ 
  + * @version CVS $Id: AutoIncrementHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $
    * */
   public interface AutoIncrementHelper extends Component {
   
       String ROLE = "org.apache.cocoon.acting.ModularDatabaseAccess.AutoIncrementHelper";
   
  -    
  +
       /**
        * Return key attribute value of last inserted row.
        *
  @@ -42,16 +90,16 @@
        * @param request The request object
        * @return value representing the last key value value.
        * */
  -    Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modeConf, 
  +    Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
                            Connection conn, Statement stmt, Request request ) throws SQLException, ConfigurationException;
   
  -    
  +
       /**
        * Boolean whether the key attribute column needs to be included
        * in the insert query.
        *
        * @return true if the column is needed, false if the column
  -     * should be skipped.  
  +     * should be skipped.
        * */
       boolean includeInQuery( );
   
  @@ -78,9 +126,9 @@
        * @param conn Connection
        * @param request The request object
        * @param idx In case of multiple rows to be inserted, index to the desired row
  -     * @return exact value for key attribute column 
  +     * @return exact value for key attribute column
        * */
  -    Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf, 
  +    Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
                           Connection conn, Request request ) throws SQLException, ConfigurationException;
   
   
  
  
  
  1.2       +63 -15    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/HsqlIdentityAutoIncrementHelper.java
  
  Index: HsqlIdentityAutoIncrementHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/HsqlIdentityAutoIncrementHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- HsqlIdentityAutoIncrementHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ HsqlIdentityAutoIncrementHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.lang.Integer;
  @@ -28,11 +76,11 @@
    * {@link http://hsqldb.sourceforge.net}
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: HsqlIdentityAutoIncrementHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $
  + * @version CVS $Id: HsqlIdentityAutoIncrementHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $
    */
   public class HsqlIdentityAutoIncrementHelper implements AutoIncrementHelper, ThreadSafe {
  -    
  -    public Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modeConf, 
  +
  +    public Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
                                   Connection conn, Statement stmt, Request request )  throws SQLException, ConfigurationException {
   
           Integer id = null;
  @@ -43,17 +91,17 @@
             callStmt.registerOutParameter(1, Types.INTEGER);
             ResultSet resultSet = callStmt.executeQuery();
           */
  -        
  +
           PreparedStatement pstmt = conn.prepareStatement("CALL IDENTITY()");
           ResultSet resultSet = pstmt.executeQuery();
           while ( resultSet.next() ) {
               id = new Integer(resultSet.getInt(1));
           }
           resultSet.close();
  -        
  +
           return id;
       }
  -    
  +
   
       public boolean includeInQuery() { return false; }
   
  @@ -61,14 +109,14 @@
       public boolean includeAsValue() { return false; }
   
   
  -    public Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf, 
  +    public Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
                                  Connection conn, Request request ) throws SQLException, ConfigurationException {
   
           return null;
       }
   
   
  -    public String getSubquery( Configuration tableConf, Configuration columnConf, Configuration modeConf ) 
  +    public String getSubquery( Configuration tableConf, Configuration columnConf, Configuration modeConf )
           throws ConfigurationException {
   
           return null;
  
  
  
  1.2       +62 -14    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/IfxSerialAutoIncrementHelper.java
  
  Index: IfxSerialAutoIncrementHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/IfxSerialAutoIncrementHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- IfxSerialAutoIncrementHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ IfxSerialAutoIncrementHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.lang.Integer;
  @@ -25,17 +73,17 @@
    * (need another one for SERIAL8 ones!)
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: IfxSerialAutoIncrementHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $
  + * @version CVS $Id: IfxSerialAutoIncrementHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $
    */
   public class IfxSerialAutoIncrementHelper implements AutoIncrementHelper, ThreadSafe {
  -    
  -    public Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modeConf, 
  -                                Connection conn, Statement stmt, Request request ) 
  +
  +    public Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
  +                                Connection conn, Statement stmt, Request request )
           throws SQLException, ConfigurationException {
   
           return new Integer(((com.informix.jdbc.IfxStatement) stmt).getSerial());
       };
  -    
  +
   
       public boolean includeInQuery() { return false; };
   
  @@ -43,13 +91,13 @@
       public boolean includeAsValue() { return false; };
   
   
  -    public Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf, 
  +    public Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
                                  Connection conn, Request request ) throws SQLException, ConfigurationException {
   
           return null;
       };
   
  -    public String getSubquery( Configuration tableConf, Configuration columnConf, Configuration modeConf ) 
  +    public String getSubquery( Configuration tableConf, Configuration columnConf, Configuration modeConf )
           throws ConfigurationException {
   
           return null;
  
  
  
  1.2       +65 -17    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/ManualAutoIncrementHelper.java
  
  Index: ManualAutoIncrementHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/ManualAutoIncrementHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ManualAutoIncrementHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ ManualAutoIncrementHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.sql.Connection;
  @@ -34,28 +82,28 @@
    * requires only shared locks. C.f. "Phantom Problem"
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: ManualAutoIncrementHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $
  + * @version CVS $Id: ManualAutoIncrementHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $
    */
   public class ManualAutoIncrementHelper extends AbstractAutoIncrementHelper implements ThreadSafe {
   
       private Map selectStatements = new HashMap();
  -    
  +
   
       public Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modenConf,
  -                                Connection conn, Statement stmt, Request request ) 
  +                                Connection conn, Statement stmt, Request request )
           throws SQLException, ConfigurationException {
   
           return null;
       }
  -    
  +
       public boolean includeInQuery( ) { return true; }
   
  -   
  +
       public boolean includeAsValue( ) { return true; }
   
   
       public Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
  -                               Connection conn, Request request ) 
  +                               Connection conn, Request request )
           throws SQLException, ConfigurationException {
   
           /** Set the key value using SELECT MAX(keyname)+1 **/
  @@ -73,9 +121,9 @@
       }
   
   
  -    public String getSubquery( Configuration tableConf, Configuration columnConf, Configuration modeConf ) 
  +    public String getSubquery( Configuration tableConf, Configuration columnConf, Configuration modeConf )
           throws ConfigurationException {
  -        
  +
           return null;
       }
   
  @@ -91,10 +139,10 @@
           queryBuffer.append(entry.getAttribute("name"));
           queryBuffer.append(") AS maxid FROM ");
           queryBuffer.append(tableName);
  -        
  +
           this.selectStatements.put(entry, queryBuffer.toString());
       }
  -    
  +
   
       protected final synchronized String getSelectQuery( String tableName, Configuration entry ) throws ConfigurationException {
   
  
  
  
  1.2       +63 -15    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/MysqlAutoIncrementHelper.java
  
  Index: MysqlAutoIncrementHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/MysqlAutoIncrementHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- MysqlAutoIncrementHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ MysqlAutoIncrementHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.lang.Integer;
  @@ -25,11 +73,11 @@
    * {@link http://www.mysql.com}
    *
    * @author <a href="mailto:phantom@stserv.hcf.jhu.edu">Tim Myers</a>
  - * @version CVS $Id: MysqlAutoIncrementHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $
  + * @version CVS $Id: MysqlAutoIncrementHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $
    */
   public class MysqlAutoIncrementHelper implements AutoIncrementHelper, ThreadSafe {
  -    
  -    public Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modeConf, 
  +
  +    public Object getPostValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
                                   Connection conn, Statement stmt, Request request )  throws SQLException, ConfigurationException {
   
           Integer id = null;
  @@ -40,17 +88,17 @@
             callStmt.registerOutParameter(1, Types.INTEGER);
             ResultSet resultSet = callStmt.executeQuery();
           */
  -        
  +
           PreparedStatement pstmt = conn.prepareStatement("SELECT LAST_INSERT_ID()");
           ResultSet resultSet = pstmt.executeQuery();
           while ( resultSet.next() ) {
               id = new Integer(resultSet.getInt(1));
           }
           resultSet.close();
  -        
  +
           return id;
       }
  -    
  +
   
       public boolean includeInQuery() { return false; }
   
  @@ -58,14 +106,14 @@
       public boolean includeAsValue() { return false; }
   
   
  -    public Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf, 
  +    public Object getPreValue( Configuration tableConf, Configuration columnConf, Configuration modeConf,
                                  Connection conn, Request request ) throws SQLException, ConfigurationException {
   
           return null;
       }
   
   
  -    public String getSubquery( Configuration tableConf, Configuration columnConf, Configuration modeConf ) 
  +    public String getSubquery( Configuration tableConf, Configuration columnConf, Configuration modeConf )
           throws ConfigurationException {
   
           return null;
  
  
  
  1.2       +59 -11    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/OutputHelper.java
  
  Index: OutputHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/OutputHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- OutputHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ OutputHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import org.apache.cocoon.environment.Request;
  @@ -19,15 +67,15 @@
    * the transaction completes successfully.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: OutputHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $
  + * @version CVS $Id: OutputHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $
    * */
   public interface OutputHelper extends Component {
   
       String ROLE = "org.apache.cocoon.acting.ModularDatabaseAccess.OutputHelper";
  -    
  -    
  +
  +
       /**
  -     * communicate an attribute value to further processing logic. 
  +     * communicate an attribute value to further processing logic.
        * @param modeConf column's mode configuration from resource
        * description. This argument is optional.
        * @param request The request object
  
  
  
  1.2       +64 -16    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/RequestAttributeHelper.java
  
  Index: RequestAttributeHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/RequestAttributeHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- RequestAttributeHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ RequestAttributeHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.util.Enumeration;
  @@ -24,9 +72,9 @@
    * getAttributeValues. Only one "*" is allowed.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: RequestAttributeHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $ */
  + * @version CVS $Id: RequestAttributeHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $ */
   public class RequestAttributeHelper extends AbstractAttributeHelper implements ThreadSafe {
  -    
  +
       public Object getAttribute( String name, Configuration modeConf, Request request )
           throws ConfigurationException {
   
  @@ -56,7 +104,7 @@
           if ( wildcardIndex != -1 ) {
               // "*" contained in attribute name => combine all
               // attributes' values that match prefix, suffix
  -            
  +
               // split the attribute's name so that the "*" could be
               // determined by looking at the attributes' names that
               // start with the prefix and end with the suffix
  @@ -70,20 +118,20 @@
               }
               List values = new LinkedList();
               Enumeration names = request.getAttributeNames();
  -            
  +
               while (names.hasMoreElements()) {
                   String pname = (String) names.nextElement();
                   if ( pname.startsWith( prefix ) && pname.endsWith( suffix ) ) {
                       values.add( request.getAttribute( pname ) );
                   }
               }
  -            
  +
               return values.toArray();
   
           } else {
               // no "*" in attribute name => just return all values of
               // this one attribute. Make sure, it's an array.
  -            
  +
               Object value = request.getAttribute( wildcard );
               if ( value != null && !value.getClass().isArray() ) {
                   Object[] values = new Object[1];
  @@ -92,11 +140,11 @@
               } else {
                   return (Object[]) value;
               }
  -            
  +
           }
  -    
  +
       }
  -    
  +
   
   
   }
  
  
  
  1.2       +58 -10    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/RequestAttributeOutputHelper.java
  
  Index: RequestAttributeOutputHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/RequestAttributeOutputHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- RequestAttributeOutputHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ RequestAttributeOutputHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.util.Enumeration;
  @@ -18,12 +66,12 @@
    * "org.apache.cocoon.acting.ModularDatabaseAccess.OutputHelper"+":"
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: RequestAttributeOutputHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $
  + * @version CVS $Id: RequestAttributeOutputHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $
    * */
   public class RequestAttributeOutputHelper extends AbstractOutputHelper implements OutputHelper {
  -    
  +
       /**
  -     * communicate an attribute value to further processing logic. 
  +     * communicate an attribute value to further processing logic.
        * @param modeConf column's mode configuration from resource
        * description. This argument is optional.
        * @param request The request object
  
  
  
  1.2       +66 -18    xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/RequestParameterHelper.java
  
  Index: RequestParameterHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/scratchpad/src/org/apache/cocoon/acting/ModularDatabaseAccess/RequestParameterHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- RequestParameterHelper.java	3 Jan 2002 12:31:36 -0000	1.1
  +++ RequestParameterHelper.java	4 Feb 2002 09:12:50 -0000	1.2
  @@ -1,10 +1,58 @@
  -/*****************************************************************************
  - * 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.                                                         *
  - *****************************************************************************/
  +/*
  + * The Apache Software License, Version 1.1
  + *
  + *
  + * Copyright (c) 2001 The Apache Software Foundation.  All rights
  + * reserved.
  + *
  + * Redistribution and use in source and binary forms, with or without
  + * modification, are permitted provided that the following conditions
  + * are met:
  + *
  + * 1. Redistributions of source code must retain the above copyright
  + *    notice, this list of conditions and the following disclaimer.
  + *
  + * 2. Redistributions in binary form must reproduce the above copyright
  + *    notice, this list of conditions and the following disclaimer in
  + *    the documentation and/or other materials provided with the
  + *    distribution.
  + *
  + * 3. The end-user documentation included with the redistribution,
  + *    if any, must include the following acknowledgment:
  + *       "This product includes software developed by the
  + *        Apache Software Foundation (http://www.apache.org/)."
  + *    Alternately, this acknowledgment may appear in the software itself,
  + *    if and wherever such third-party acknowledgments normally appear.
  + *
  + * 4. The names "Axis" and "Apache Software Foundation" must
  + *    not be used to endorse or promote products derived from this
  + *    software without prior written permission. For written
  + *    permission, please contact apache@apache.org.
  + *
  + * 5. Products derived from this software may not be called "Apache",
  + *    nor may "Apache" appear in their name, without prior written
  + *    permission of the Apache Software Foundation.
  + *
  + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  + * DISCLAIMED.  IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
  + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  + * SUCH DAMAGE.
  + * ====================================================================
  + *
  + * This software consists of voluntary contributions made by many
  + * individuals on behalf of the Apache Software Foundation.  For more
  + * information on the Apache Software Foundation, please see
  + * <http://www.apache.org/>.
  + */
  +
   package org.apache.cocoon.acting.ModularDatabaseAccess;
   
   import java.util.Enumeration;
  @@ -26,7 +74,7 @@
    * such array is returned.
    *
    * @author <a href="mailto:haul@apache.org">Christian Haul</a>
  - * @version CVS $Id: RequestParameterHelper.java,v 1.1 2002/01/03 12:31:36 giacomo Exp $ */
  + * @version CVS $Id: RequestParameterHelper.java,v 1.2 2002/02/04 09:12:50 cziegeler Exp $ */
   public class RequestParameterHelper extends AbstractAttributeHelper implements ThreadSafe {
   
       public Object getAttribute( String name, Configuration modeConf, Request request ) throws ConfigurationException {
  @@ -45,9 +93,9 @@
       }
   
   
  -    public Object[] getAttributeValues( String name, Configuration modeConf, Request request ) 
  +    public Object[] getAttributeValues( String name, Configuration modeConf, Request request )
           throws ConfigurationException {
  -        
  +
           String wildcard = name;
           if ( modeConf != null ) {
               wildcard = modeConf.getAttribute( "parameter", wildcard );
  @@ -56,7 +104,7 @@
           if ( wildcardIndex != -1 ) {
               // "*" contained in parameter name => combine all
               // parameters' values that match prefix, suffix
  -            
  +
               // split the parameter's name so that the "*" could be
               // determined by looking at the parameters' names that
               // start with the prefix and end with the suffix
  @@ -70,24 +118,24 @@
               }
               List values = new LinkedList();
               Enumeration names = request.getParameterNames();
  -            
  +
               while (names.hasMoreElements()) {
                   String pname = (String) names.nextElement();
                   if ( pname.startsWith( prefix ) && pname.endsWith( suffix ) ) {
                       values.add( request.getParameter( pname ) );
                   }
               }
  -            
  +
               return values.toArray();
  -            
  +
           } else {
               // no "*" in parameter name => just return all values of
               // this one parameter.
  -            
  +
               return request.getParameterValues( wildcard );
  -            
  +
           }
  -        
  +
       }
  -    
  +
   }
  
  
  

----------------------------------------------------------------------
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