axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject [jira] Created: (AXIS-1286) Minor SOAPHeader/SOAPBody issues
Date Tue, 06 Apr 2004 08:02:43 GMT
Message:

  A new issue has been created in JIRA.

---------------------------------------------------------------------
View the issue:
  http://issues.apache.org/jira/browse/AXIS-1286

Here is an overview of the issue:
---------------------------------------------------------------------
        Key: AXIS-1286
    Summary: Minor SOAPHeader/SOAPBody issues
       Type: Bug

     Status: Unassigned
   Priority: Minor

    Project: Axis
 Components: 
             Basic Architecture

   Assignee: 
   Reporter: Jarek Gawor

    Created: Tue, 6 Apr 2004 1:01 AM
    Updated: Tue, 6 Apr 2004 1:01 AM

Description:
1) 
In SOAPHeader:

    public SOAPElement addChildElement(SOAPElement element) 
      throws SOAPException
    {
      if (!(element instanceof javax.xml.soap.SOAPHeaderElement)) {
        throw new SOAPException(Messages.getMessage("badSOAPHeader00"));
      } 
      return super.addChildElement(element);
    }

"child.setEnvelope(getEnvelope());" is not set as in other addChildElement() methods. That
causes the following error sometimes:

        {http://xml.apache.org/axis/}stackTrace:java.lang.NullPointerException
        at org.apache.axis.message.SOAPHeaderElement.outputImpl(SOAPHeaderElemen
t.java:224)
        at org.apache.axis.message.MessageElement.output(MessageElement.java:111

2) 

findElement() function is replicated in SOAPBody.java and SOAPHeader.java. So is removeChild(MessageElement)
in SOAPBody, SOAPHeader and in MessageElement.java

3) 

The check:

 if (!(element instanceof javax.xml.soap.SOAPHeaderElement)) {
        throw new SOAPException(Messages.getMessage("badSOAPHeader00"));
      } 

in SOAPHeader.addChildElement(SOAPElement) should probably move to addChild(MessageElement).
Otherwise ClassCastException might occur if addChild(MessageElement) is used. And the check
should probably be for the Axis version of SOAPHeaderElement. 



---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


Mime
View raw message