axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From i..@apache.org
Subject cvs commit: ws-axis/java/src/org/apache/axis/message SOAPHeader.java
Date Fri, 02 Jan 2004 16:28:38 GMT
ias         2004/01/02 08:28:38

  Modified:    java/src/org/apache/axis/message SOAPHeader.java
  Log:
  Fix for Bug 22981 - The SAAJ 1.2 Preliminary Upgrade
  
  Thanks to Dr. Ahn, Heejune. 
  
  Note:
  -This change passed all-tests.
  
  Revision  Changes    Path
  1.77      +25 -4     ws-axis/java/src/org/apache/axis/message/SOAPHeader.java
  
  Index: SOAPHeader.java
  ===================================================================
  RCS file: /home/cvs/ws-axis/java/src/org/apache/axis/message/SOAPHeader.java,v
  retrieving revision 1.76
  retrieving revision 1.77
  diff -u -r1.76 -r1.77
  --- SOAPHeader.java	13 Aug 2003 19:08:22 -0000	1.76
  +++ SOAPHeader.java	2 Jan 2004 16:28:38 -0000	1.77
  @@ -162,16 +162,37 @@
           return results.iterator();
       }
   
  -    public Iterator examineMustUnderstandHeaderElements(String s) {
  -        return null;  //TODO: Fix this for SAAJ 1.2 Implementation
  +    public Iterator examineMustUnderstandHeaderElements(String actor) {
  +        if (actor == null) return null;
  +
  +        Vector result = new Vector();
  +
  +        ArrayList headers = super.getChildren();
  +
  +        for(int i = 0; i < headers.size(); i++) {
  +            SOAPHeaderElement she = (SOAPHeaderElement)headers.get(i);
  +            if (she.getMustUnderstand()) {
  +                String candidate = she.getActor();
  +                if (actor.equals(candidate)) {
  +                    result.add(headers.get(i));
  +                }
  +            }
  +        }
  +        return result.iterator();
       }
   
       public Iterator examineAllHeaderElements() {
  -        return null;  //TODO: Fix this for SAAJ 1.2 Implementation
  +        return super.getChildElements();
       }
   
       public Iterator extractAllHeaderElements() {
  -        return null;  //TODO: Fix this for SAAJ 1.2 Implementation
  +        Vector result = new Vector();
  +        ArrayList headers = super.getChildren();
  +        for(int i = 0; i < headers.size(); i++) {
  +            result.add(headers.get(i));
  +        }
  +        headers.clear();
  +        return result.iterator();
       }
   
       Vector getHeaders() {
  
  
  

Mime
View raw message