xml-xalan-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From minc...@apache.org
Subject cvs commit: xml-xalan/java/src/org/apache/xml/res XMLErrorResources.java
Date Thu, 23 Oct 2003 18:20:11 GMT
minchau     2003/10/23 11:20:11

  Modified:    java/src/org/apache/xml/serializer Tag: xslt20-compiled
                        ToTextStream.java
               java/src/org/apache/xalan/res Tag: xslt20-compiled
                        XSLTErrorResources.java
               java/src/org/apache/xml/res Tag: xslt20-compiled
                        XMLErrorResources.java
  Log:
  I had accidentally applied the original patch for 795, not the re-worked patch.
  The re-worked patch has the error message in XMLMessages, not
  XSLTMessages.
  
  So I undid the patch I applied and applied the re-worked one with this commit.
  - Brian Minchau
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.11.2.3  +12 -10    xml-xalan/java/src/org/apache/xml/serializer/ToTextStream.java
  
  Index: ToTextStream.java
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/src/org/apache/xml/serializer/ToTextStream.java,v
  retrieving revision 1.11.2.2
  retrieving revision 1.11.2.3
  diff -u -r1.11.2.2 -r1.11.2.3
  --- ToTextStream.java	23 Oct 2003 15:59:01 -0000	1.11.2.2
  +++ ToTextStream.java	23 Oct 2003 18:20:10 -0000	1.11.2.3
  @@ -61,13 +61,11 @@
   
   import java.io.IOException;
   
  -import org.apache.xml.serializer.CharInfo;
  +import org.apache.xml.res.XMLErrorResources;
  +import org.apache.xml.res.XMLMessages;
   import org.xml.sax.Attributes;
   import org.xml.sax.SAXException;
   
  -import org.apache.xalan.res.XSLMessages;
  -import org.apache.xalan.res.XSLTErrorResources;
  -
   public class ToTextStream extends ToStream 
   { 
   
  @@ -359,9 +357,11 @@
                   }
                   else
                   {
  -                    // writer.write(c);
  -                    throw new SAXException(XSLMessages.createMessage(
  -                        XSLTErrorResources.ER_ILLEGAL_CHARACTER,null));
  +                    String encoding = getEncoding();
  +                    String integralValue = Integer.toString(c);
  +                    throw new SAXException(XMLMessages.createXMLMessage(
  +                        XMLErrorResources.ER_ILLEGAL_CHARACTER,
  +                        new Object[]{ integralValue, encoding}));
                   }
               }
           }
  @@ -388,9 +388,11 @@
               }
               else
               {
  -                // writer.write(c);
  -                throw new SAXException(XSLMessages.createMessage(
  -                    XSLTErrorResources.ER_ILLEGAL_CHARACTER,null));
  +                String encoding = getEncoding();
  +                String integralValue = Integer.toString(c);
  +                throw new SAXException(XMLMessages.createXMLMessage(
  +                    XMLErrorResources.ER_ILLEGAL_CHARACTER,
  +                    new Object[]{ integralValue, encoding}));                 
               }
           }
       }
  
  
  
  No                   revision
  No                   revision
  1.41.2.2  +0 -8      xml-xalan/java/src/org/apache/xalan/res/XSLTErrorResources.java
  
  Index: XSLTErrorResources.java
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/src/org/apache/xalan/res/XSLTErrorResources.java,v
  retrieving revision 1.41.2.1
  retrieving revision 1.41.2.2
  diff -u -r1.41.2.1 -r1.41.2.2
  --- XSLTErrorResources.java	23 Oct 2003 15:59:01 -0000	1.41.2.1
  +++ XSLTErrorResources.java	23 Oct 2003 18:20:10 -0000	1.41.2.2
  @@ -418,9 +418,6 @@
   	 "ER_NOT_ALLOWED_IN_POSITION";
     public static final String ER_NONWHITESPACE_NOT_ALLOWED_IN_POSITION = 
   	 "ER_NONWHITESPACE_NOT_ALLOWED_IN_POSITION";
  -  public static final String ER_ILLEGAL_CHARACTER = 
  -     "ER_ILLEGAL_CHARACTER";
  -     
     public static final String INVALID_TCHAR = "INVALID_TCHAR";
     public static final String INVALID_QNAME = "INVALID_QNAME";
     public static final String INVALID_ENUM = "INVALID_ENUM";
  @@ -487,7 +484,6 @@
   	 "WG_ILLEGAL_ATTRIBUTE_POSITION";
   
   
  -
   //  public static final int ER_NO_CURLYBRACE = 1;
     /*
      * Now fill in the message text.
  @@ -2149,11 +2145,7 @@
       { ER_FUNCTION_NOT_FOUND,
        "The function named {0} does not exist"},
   
  -//   ER_ILLEGAL_CHARACTER
  -//     public static final int ER_ILLEGAL_CHARACTER = 255;
   
  -     { ER_ILLEGAL_CHARACTER,
  -      "Attempt to output character not represented in specified encoding."},
   
   
   
  
  
  
  No                   revision
  No                   revision
  1.4.4.1   +4 -0      xml-xalan/java/src/org/apache/xml/res/XMLErrorResources.java
  
  Index: XMLErrorResources.java
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/src/org/apache/xml/res/XMLErrorResources.java,v
  retrieving revision 1.4
  retrieving revision 1.4.4.1
  diff -u -r1.4 -r1.4.4.1
  --- XMLErrorResources.java	1 Apr 2003 19:18:23 -0000	1.4
  +++ XMLErrorResources.java	23 Oct 2003 18:20:10 -0000	1.4.4.1
  @@ -204,6 +204,7 @@
     public static final String ER_COULD_NOT_LOAD_METHOD_PROPERTY = "ER_COULD_NOT_LOAD_METHOD_PROPERTY";
     public static final String ER_SERIALIZER_NOT_CONTENTHANDLER = "ER_SERIALIZER_NOT_CONTENTHANDLER";
     public static final String ER_ILLEGAL_ATTRIBUTE_POSITION = "ER_ILLEGAL_ATTRIBUTE_POSITION";
  +  public static final String ER_ILLEGAL_CHARACTER = "ER_ILLEGAL_CHARACTER";
   
     /*
      * Now fill in the message text.
  @@ -462,6 +463,9 @@
   
       {ER_COULD_NOT_LOAD_RESOURCE,
         "Could not load ''{0}'' (check CLASSPATH), now using just the defaults"},
  +
  +    { ER_ILLEGAL_CHARACTER,
  +       "Attempt to output character of integral value {0} that is not represented in specified
output encoding of {1}."},
       
       {ER_COULD_NOT_LOAD_METHOD_PROPERTY,
         "Could not load the propery file ''{0}'' for output method ''{1}'' (check CLASSPATH)"
}
  
  
  

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


Mime
View raw message