You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xalan.apache.org by cu...@apache.org on 2001/06/20 14:21:07 UTC

cvs commit: xml-xalan/test/java/src/org/apache/qetest XMLFileLogger.java

curcuru     01/06/20 05:21:04

  Modified:    test/java/src/org/apache/qetest XMLFileLogger.java
  Log:
  Make several utility methods static for use by other files/tests
  that might want to escape chars for output into potential XML files
  
  Revision  Changes    Path
  1.7       +9 -11     xml-xalan/test/java/src/org/apache/qetest/XMLFileLogger.java
  
  Index: XMLFileLogger.java
  ===================================================================
  RCS file: /home/cvs/xml-xalan/test/java/src/org/apache/qetest/XMLFileLogger.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- XMLFileLogger.java	2001/04/11 20:34:41	1.6
  +++ XMLFileLogger.java	2001/06/20 12:20:53	1.7
  @@ -77,7 +77,7 @@
    * Logger that saves output to a simple XML-format file.
    * @todo improve escapeString so it's more rigorous about escaping
    * @author Shane_Curcuru@lotus.com
  - * @version $Id: XMLFileLogger.java,v 1.6 2001/04/11 20:34:41 curcuru Exp $
  + * @version $Id: XMLFileLogger.java,v 1.7 2001/06/20 12:20:53 curcuru Exp $
    */
   public class XMLFileLogger implements Logger
   {
  @@ -953,11 +953,10 @@
       /**
        * Lifted from org.apache.xml.serialize.transition.XMLSerializer
        *
  -     * NEEDSDOC @param ch
  -     *
  -     * NEEDSDOC ($objectName$) @return
  +     * @param ch character to get entity ref for
  +     * @return String of entity name
        */
  -    protected String getEntityRef(char ch)
  +    public static String getEntityRef(char ch)
       {
   
           // Encode special XML characters into the equivalent character references.
  @@ -987,16 +986,15 @@
        * not printable will be escaped using character references.
        * Lifted from org.apache.xml.serialize.transition.BaseMarkupSerializer
        */
  -    private int _lastPrintable = 0x7E;
  +    public static int _lastPrintable = 0x7E;
   
       /**
        * Lifted from org.apache.xml.serialize.transition.BaseMarkupSerializer
        *
  -     * NEEDSDOC @param ch
  -     *
  -     * NEEDSDOC ($objectName$) @return
  +     * @param ch character to escape
  +     * @return String that is escaped
        */
  -    protected String printEscaped(char ch)
  +    public static String printEscaped(char ch)
       {
   
           String charRef;
  @@ -1045,7 +1043,7 @@
        * @param source The string to escape
        * @return String after escaping - needed for our application
        */
  -    protected String escapeString(String source)  // protected void printEscaped( String source )
  +    public static String escapeString(String source)
       {
           // Check for null; just return null (callers shouldn't care)
           if (source == null)
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-cvs-help@xml.apache.org