axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gdani...@apache.org
Subject cvs commit: xml-axis/java/src/org/apache/axis/message SOAPEnvelope.java
Date Tue, 14 Aug 2001 13:10:32 GMT
gdaniels    01/08/14 06:10:32

  Modified:    java/src/org/apache/axis/message SOAPEnvelope.java
  Log:
  Check for null namespaces collection, and fix a few long lines
  while in there.
  
  Revision  Changes    Path
  1.34      +14 -7     xml-axis/java/src/org/apache/axis/message/SOAPEnvelope.java
  
  Index: SOAPEnvelope.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/message/SOAPEnvelope.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -r1.33 -r1.34
  --- SOAPEnvelope.java	2001/08/14 13:06:35	1.33
  +++ SOAPEnvelope.java	2001/08/14 13:10:32	1.34
  @@ -203,7 +203,9 @@
       public SOAPHeader getHeaderByName(String namespace, String localPart)
           throws AxisFault
       {
  -        SOAPHeader header = (SOAPHeader)findElement(headers, namespace, localPart);
  +        SOAPHeader header = (SOAPHeader)findElement(headers,
  +                                                    namespace,
  +                                                    localPart);
           
           return header;
       }
  @@ -211,7 +213,9 @@
       public SOAPBodyElement getBodyByName(String namespace, String localPart)
           throws AxisFault
       {
  -        return (SOAPBodyElement)findElement(bodyElements, namespace, localPart);
  +        return (SOAPBodyElement)findElement(bodyElements,
  +                                            namespace,
  +                                            localPart);
       }
       
       protected MessageElement findElement(Vector vec, String namespace,
  @@ -258,10 +262,12 @@
           throws Exception
       {
           // Register namespace prefixes.
  -        for (Iterator i = namespaces.iterator(); i.hasNext(); ) {
  -            Mapping mapping = (Mapping)i.next();
  -            context.registerPrefixForURI(mapping.getPrefix(),
  -                                         mapping.getNamespaceURI());
  +        if (namespaces != null) {
  +            for (Iterator i = namespaces.iterator(); i.hasNext(); ) {
  +                Mapping mapping = (Mapping)i.next();
  +                context.registerPrefixForURI(mapping.getPrefix(),
  +                                             mapping.getNamespaceURI());
  +            }
           }
           
           Enumeration enum;
  @@ -270,7 +276,8 @@
               attrs = new AttributesImpl();
               attrs.addAttribute(Constants.URI_SOAP_ENV,
                                  Constants.ATTR_ENCODING_STYLE,
  -                               "SOAP-ENV:" + Constants.ATTR_ENCODING_STYLE, "CDATA", encodingStyleURI);
  +                               "SOAP-ENV:" + Constants.ATTR_ENCODING_STYLE,
  +                               "CDATA", encodingStyleURI);
           }
           
           context.startElement(new QName(Constants.URI_SOAP_ENV,
  
  
  

Mime
View raw message