santuario-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From geu...@apache.org
Subject cvs commit: xml-security/src/org/apache/xml/security/c14n/implementations Canonicalizer20010315.java Canonicalizer20010315Excl.java CanonicalizerBase.java
Date Sat, 28 Sep 2002 08:54:53 GMT
geuerp      2002/09/28 01:54:53

  Modified:    src/org/apache/xml/security/c14n/helper C14nHelper.java
               src/org/apache/xml/security/c14n/implementations
                        Canonicalizer20010315.java
                        Canonicalizer20010315Excl.java
                        CanonicalizerBase.java
  Removed:     src/org/apache/xml/security/c14n/helper NSAttrCompare.java
                        NonNSAttrCompare.java
  Log:
  AttrCompare fully replaces NonNSAttrCompare and NSAttrCompare
  
  Revision  Changes    Path
  1.9       +19 -0     xml-security/src/org/apache/xml/security/c14n/helper/C14nHelper.java
  
  Index: C14nHelper.java
  ===================================================================
  RCS file: /home/cvs/xml-security/src/org/apache/xml/security/c14n/helper/C14nHelper.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- C14nHelper.java	28 Aug 2002 13:11:35 -0000	1.8
  +++ C14nHelper.java	28 Sep 2002 08:54:53 -0000	1.9
  @@ -92,6 +92,8 @@
       * @param attributes
       *
       */
  +
  +   /*
      public static final Object[] sortAttributes(Object[] attributes) {
   
         if (attributes == null) {
  @@ -132,6 +134,23 @@
         for (int i = 0; i < nonNamespaces.length; i++) {
            result[i + namespaces.length] = (Attr) nonNamespaces[i];
         }
  +
  +      return result;
  +   }
  +   */
  +
  +   public static final Object[] sortAttributes(Object[] attributes) {
  +
  +      if (attributes == null) {
  +         return new Attr[0];
  +      }
  +
  +      Object[] result = new Object[attributes.length];
  +      for (int i=0; i<attributes.length; i++) {
  +         result[i] = attributes[i];
  +      }
  +
  +      java.util.Arrays.sort(result, new AttrCompare());
   
         return result;
      }
  
  
  
  1.28      +2 -2      xml-security/src/org/apache/xml/security/c14n/implementations/Canonicalizer20010315.java
  
  Index: Canonicalizer20010315.java
  ===================================================================
  RCS file: /home/cvs/xml-security/src/org/apache/xml/security/c14n/implementations/Canonicalizer20010315.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -r1.27 -r1.28
  --- Canonicalizer20010315.java	8 Sep 2002 11:55:24 -0000	1.27
  +++ Canonicalizer20010315.java	28 Sep 2002 08:54:53 -0000	1.28
  @@ -66,7 +66,7 @@
   import javax.xml.parsers.*;
   import javax.xml.transform.TransformerException;
   import org.apache.xml.security.c14n.*;
  -import org.apache.xml.security.c14n.helper.*;
  +import org.apache.xml.security.c14n.helper.C14nHelper;
   import org.apache.xml.security.utils.*;
   import org.apache.xpath.CachedXPathAPI;
   import org.w3c.dom.*;
  
  
  
  1.9       +7 -6      xml-security/src/org/apache/xml/security/c14n/implementations/Canonicalizer20010315Excl.java
  
  Index: Canonicalizer20010315Excl.java
  ===================================================================
  RCS file: /home/cvs/xml-security/src/org/apache/xml/security/c14n/implementations/Canonicalizer20010315Excl.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- Canonicalizer20010315Excl.java	8 Sep 2002 11:55:24 -0000	1.8
  +++ Canonicalizer20010315Excl.java	28 Sep 2002 08:54:53 -0000	1.9
  @@ -72,7 +72,8 @@
   import org.w3c.dom.*;
   import org.xml.sax.*;
   import org.apache.xml.security.c14n.*;
  -import org.apache.xml.security.c14n.helper.*;
  +import org.apache.xml.security.c14n.helper.C14nHelper;
  +import org.apache.xml.security.c14n.helper.AttrCompare;
   import org.apache.xml.security.utils.*;
   import org.apache.xml.security.transforms.params.InclusiveNamespaces;
   
  @@ -373,10 +374,10 @@
            }
         }
   
  -      Collections.sort(ns,
  -                       new org.apache.xml.security.c14n.helper.NSAttrCompare());
  -      Collections.sort(
  -         at, new org.apache.xml.security.c14n.helper.NonNSAttrCompare());
  +      // Collections.sort(ns,new NSAttrCompare());
  +      Collections.sort(ns,new AttrCompare());
  +      // Collections.sort(at, new NonNSAttrCompare());
  +      Collections.sort(at, new AttrCompare());
         ns.addAll(at);
   
         return ns;
  
  
  
  1.2       +2 -2      xml-security/src/org/apache/xml/security/c14n/implementations/CanonicalizerBase.java
  
  Index: CanonicalizerBase.java
  ===================================================================
  RCS file: /home/cvs/xml-security/src/org/apache/xml/security/c14n/implementations/CanonicalizerBase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CanonicalizerBase.java	8 Sep 2002 11:55:24 -0000	1.1
  +++ CanonicalizerBase.java	28 Sep 2002 08:54:53 -0000	1.2
  @@ -66,7 +66,7 @@
   import javax.xml.parsers.*;
   import javax.xml.transform.TransformerException;
   import org.apache.xml.security.c14n.*;
  -import org.apache.xml.security.c14n.helper.*;
  +import org.apache.xml.security.c14n.helper.C14nHelper;
   import org.apache.xml.security.utils.*;
   import org.apache.xpath.CachedXPathAPI;
   import org.w3c.dom.*;
  
  
  

Mime
View raw message