sylvain     02/03/19 01:05:56

  Modified:    src/java/org/apache/cocoon/serialization FOPSerializer.java
  Log:
  New "set-content-length" configuration for FOPSerializer to allow streaming of large 
PDFs (default is true for backwards compatibility).
  We're in code freeze, but I really wanted this minor update in 2.0.2...
  
  Revision  Changes    Path
  1.7       +9 -2      
xml-cocoon2/src/java/org/apache/cocoon/serialization/FOPSerializer.java
  
  Index: FOPSerializer.java
  ===================================================================
  RCS file: 
/home/cvs/xml-cocoon2/src/java/org/apache/cocoon/serialization/FOPSerializer.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- FOPSerializer.java        22 Feb 2002 07:03:55 -0000      1.6
  +++ FOPSerializer.java        19 Mar 2002 09:05:56 -0000      1.7
  @@ -68,7 +68,7 @@
   
   /**
    * @author ?
  - * @version CVS $Id: FOPSerializer.java,v 1.6 2002/02/22 07:03:55 cziegeler Exp $
  + * @version CVS $Id: FOPSerializer.java,v 1.7 2002/03/19 09:05:56 sylvain Exp $
    */
   public class FOPSerializer
   extends AbstractSerializer
  @@ -103,6 +103,11 @@
        * The renderer name if configured
        */
       protected String rendererName;
  +    
  +    /**
  +     * Should we set the content length ?
  +     */
  +    protected boolean setContentLength = true;
   
       /**
         * Set the configurations for this serializer.
  @@ -121,6 +126,8 @@
                       // No config file specified
                   }
               }
  +            
  +            this.setContentLength = 
conf.getChild("set-content-length").getValueAsBoolean(true);
           }
   
           // Check for null, use external or inbuilt config.
  @@ -244,6 +251,6 @@
       * Test if the component wants to set the content length
       */
       public boolean shouldSetContentLength() {
  -        return true;
  +        return this.setContentLength;
       }
   }
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     [EMAIL PROTECTED]
To unsubscribe, e-mail:          [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to