axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: ws-axis/java/src/org/apache/axis/description JavaServiceDesc.java
Date Fri, 06 May 2005 21:54:36 GMT
dims        2005/05/06 14:54:36

  Modified:    java/src/org/apache/axis/description JavaServiceDesc.java
  Log:
  Fix for AXIS-1959 - Wrapper style is defined at the operation level.
  
  URL: http://issues.apache.org/jira/browse/AXIS-1959
  
  Revision  Changes    Path
  1.27      +21 -8     ws-axis/java/src/org/apache/axis/description/JavaServiceDesc.java
  
  Index: JavaServiceDesc.java
  ===================================================================
  RCS file: /home/cvs/ws-axis/java/src/org/apache/axis/description/JavaServiceDesc.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -r1.26 -r1.27
  --- JavaServiceDesc.java	24 Apr 2005 15:49:01 -0000	1.26
  +++ JavaServiceDesc.java	6 May 2005 21:54:36 -0000	1.27
  @@ -484,17 +484,30 @@
           initQNameMap();
   
           ArrayList overloads = (ArrayList)qname2OperationsMap.get(qname);
  -
           if (overloads == null) {
               // Nothing specifically matching this QName.
  -            if ((isWrapped() ||
  -                 ((style==Style.MESSAGE) && 
  -                  (getDefaultNamespace() == null))) &&
  -                (name2OperationsMap != null)) {
  -                // Try ignoring the namespace....?
  -                overloads = (ArrayList)name2OperationsMap.get(qname.getLocalPart());
  +            if (name2OperationsMap != null) {
  +                if ((isWrapped() ||
  +                     ((style == Style.MESSAGE) &&
  +                      (getDefaultNamespace() == null)))) {
  +                    // Try ignoring the namespace....?
  +                    overloads = (ArrayList) name2OperationsMap.get(qname.getLocalPart());
  +                } else {
  +                    // TODO the above code is weird: a JavaServiceDesc can  be document
or rpc and
  +                    // still define a WSDL operation using a wrapper style  mapping.
  +                    // The following code handles this case.
  +                    Object ops = name2OperationsMap.get(qname.getLocalPart());
  +                    if (ops != null) {
  +                        overloads = new ArrayList((Collection) ops);
  +                        for (Iterator iter = overloads.iterator(); iter.hasNext();) {
  +                            OperationDesc operationDesc = (OperationDesc) iter.next();
  +                            if (Style.WRAPPED != operationDesc.getStyle()) {
  +                                iter.remove();
  +                            }
  +                        }
  +                    }
  +                }
               }
  -
               // Handle the case where a single Message-style operation wants
               // to accept anything.
               if ((style == Style.MESSAGE) && (messageServiceDefaultOp != null))
  
  
  

Mime
View raw message