Artifact Content

Not logged in

Artifact 93980d92526d71e588351f69cf1404778efad1bd:

Attachment "inline-namespaces.diff" to ticket [dcce437d7a] added by oehhar 2017-01-09 09:01:31.
1039c1039,1065
< 
---
>     foreach itemList [$wsdlNode attributes xmlns:*] {
>         set ns [lindex $itemList 0]
>         set url [$wsdlNode getAttribute xmlns:$ns]
>         if {[dict exists $nsDict url $url]} {
>             set tns [dict get $nsDict url $url]
>         } else {
>             ##
>             ## Check for hardcoded namespaces
>             ##
>             switch -exact -- $url {
>                 http://schemas.xmlsoap.org/wsdl/ {
>                     set tns w
>                 }
>                 http://schemas.xmlsoap.org/wsdl/soap/ {
>                     set tns d
>                 }
>                 http://www.w3.org/2001/XMLSchema {
>                     set tns xs
>                 }
>                 default {
>                     set tns tns[incr nsCount]
>                 }
>             }
>             dict set nsDict url $url $tns
>         }
>         dict set nsDict tns $ns $tns
>     }
1044,1078d1069
<     }
< 
<     set elems $wsdlNode
<     set elems [concat $elems [$wsdlDoc selectNodes {//xs:element}]]
< 
<     foreach elemNode $elems {
<       set xmlnsAttributes [$elemNode attributes xmlns:*] 
< 
<       foreach itemList $xmlnsAttributes {
<           set ns [lindex $itemList 0]
<           set url [$elemNode getAttribute xmlns:$ns]
<           if {[dict exists $nsDict url $url]} {
<               set tns [dict get $nsDict url $url]
<           } else {
<               ##
<               ## Check for hardcoded namespaces
<               ##
<               switch -exact -- $url {
<                   http://schemas.xmlsoap.org/wsdl/ {
<                       set tns w
<                   }
<                   http://schemas.xmlsoap.org/wsdl/soap/ {
<                       set tns d
<                   }
<                   http://www.w3.org/2001/XMLSchema {
<                       set tns xs
<                   }
<                   default {
<                       set tns tns[incr nsCount]
<                   }
<               }
<               dict set nsDict url $url $tns
<           }
<           dict set nsDict tns $ns $tns
<       }