commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: jakarta-commons/jelly/src/java/org/apache/commons/jelly XMLOutput.java
Date Tue, 07 Sep 2004 04:22:01 GMT
dion        2004/09/06 21:22:01

  Modified:    jelly/src/java/org/apache/commons/jelly XMLOutput.java
  Log:
  Place default for escaping text into a constant.
  
  Revision  Changes    Path
  1.16      +6 -5      jakarta-commons/jelly/src/java/org/apache/commons/jelly/XMLOutput.java
  
  Index: XMLOutput.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/jelly/src/java/org/apache/commons/jelly/XMLOutput.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- XMLOutput.java	2 Sep 2004 07:27:59 -0000	1.15
  +++ XMLOutput.java	7 Sep 2004 04:22:00 -0000	1.16
  @@ -60,6 +60,9 @@
       /** The Log to which logging calls will be made. */
       private static final Log log = LogFactory.getLog(XMLOutput.class);
   
  +    /** the default for escaping of text */
  +    private static final boolean DEFAULT_ESCAPE_TEXT = true;
  +    
       public XMLOutput() {
       }
   
  @@ -132,8 +135,7 @@
        * text and writes to the underlying Writer.
        */
       public static XMLOutput createXMLOutput(Writer writer) {
  -        XMLWriter xmlWriter = new XMLWriter(writer);
  -        return createXMLOutput(xmlWriter);
  +        return createXMLOutput(writer, DEFAULT_ESCAPE_TEXT);
       }
   
       /** 
  @@ -156,8 +158,7 @@
        * text and writes to the underlying OutputStream.
        */
       public static XMLOutput createXMLOutput(OutputStream out) throws UnsupportedEncodingException
{
  -        XMLWriter xmlWriter = new XMLWriter(out);
  -        return createXMLOutput(xmlWriter);
  +        return createXMLOutput(out, DEFAULT_ESCAPE_TEXT);
       }
       
       /** 
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message