Check-in [2e183f0cc8]
Not logged in
Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to tclconference@googlegroups.com
or submit via the online form by Sep 9.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fixes proposed by Dennis Pfeifer to address parsing errors. Ticket [ce9cf80b6efd6419]
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | bug-ce9cf80b6efd6419
Files: files | file ages | folders
SHA1:2e183f0cc8a0073e4511ce4a67eab982f53df554
User & Date: oehhar 2017-04-10 10:06:49
References
2017-04-10 10:08 Ticket [ce9cf80b6e] error parsing wsdl status still New with 1 other change artifact: b6c400dab2 user: oehhar
Context
2017-04-10 17:46
Removed exec flags Leaf check-in: ac19faf750 user: oehhar tags: bug-ce9cf80b6efd6419
2017-04-10 10:06
Fixes proposed by Dennis Pfeifer to address parsing errors. Ticket [ce9cf80b6efd6419] check-in: 2e183f0cc8 user: oehhar tags: bug-ce9cf80b6efd6419
2016-11-23 16:40
Fix for bug [6bdf06291d] -- undefined variable when asynch call fails. check-in: 51c849b483 user: gerald tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ClientSide.tcl.

1032
1033
1034
1035
1036
1037
1038


1039
1040
1041

1042
1043
1044
1045
1046
1047
1048
....
1105
1106
1107
1108
1109
1110
1111
































1112
1113
1114
1115
1116
1117
1118
    $tmpdoc xslt $::WS::Utils::xsltSchemaDom wsdlDoc
    $tmpdoc delete
    $wsdlDoc documentElement wsdlNode
    set nsCount 1
    set targetNs [$wsdlNode getAttribute targetNamespace]
    set ::WS::Utils::targetNs $targetNs
    dict set nsDict url $targetNs tns$nsCount


    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 {
................................................................................
    }

    $wsdlDoc delete
    unset -nocomplain ::WS::Utils::targetNs

    return $serviceInfo

































}

###########################################################################
#
# Public Procedure Header - as this procedure is modified, please be sure
#                           that you update this header block. Thanks.
#







>
>
|

|
>







 







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
....
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
    $tmpdoc xslt $::WS::Utils::xsltSchemaDom wsdlDoc
    $tmpdoc delete
    $wsdlDoc documentElement wsdlNode
    set nsCount 1
    set targetNs [$wsdlNode getAttribute targetNamespace]
    set ::WS::Utils::targetNs $targetNs
    dict set nsDict url $targetNs tns$nsCount
    set xmlnsList ""
    parseXMLNS wsdlNode xmlnsList
    foreach itemList $xmlnsList {
        set ns [lindex $itemList 0]
        ;###set url [$wsdlNode getAttribute xmlns:$ns]
        set url [getXMLNSAttribute wsdlNode "xmlns:$ns"]
        if {[dict exists $nsDict url $url]} {
            set tns [dict get $nsDict url $url]
        } else {
            ##
            ## Check for hardcoded namespaces
            ##
            switch -exact -- $url {
................................................................................
    }

    $wsdlDoc delete
    unset -nocomplain ::WS::Utils::targetNs

    return $serviceInfo

}
proc ::WS::Client::parseXMLNS {wsdlNodeVar xmlnsListVar} {

    upvar $xmlnsListVar xmlnsList
    upvar $wsdlNodeVar wsdlNode

    foreach itemList [$wsdlNode attributes xmlns:*] {
        if {[lsearch $xmlnsList $itemList] < 0} {
            lappend xmlnsList $itemList
        }
    }
    if {[$wsdlNode hasChildNodes] > 0} {
        foreach childNode [$wsdlNode childNodes] {
            parseXMLNS childNode xmlnsList
        }
    }
}

proc ::WS::Client::getXMLNSAttribute {wsdlNodeVar attribute} {
    upvar $wsdlNodeVar wsdlNode
    set url ""
    if {[catch {set url [$wsdlNode getAttribute $attribute]}] } {
        if {[$wsdlNode hasChildNodes] > 0} {
            foreach childNode [$wsdlNode childNodes] {
                set url [getXMLNSAttribute childNode $attribute]
                if {![string equal $url ""]} {
                    return $url
                }
            }
        }
    }
    return $url
}

###########################################################################
#
# Public Procedure Header - as this procedure is modified, please be sure
#                           that you update this header block. Thanks.
#

Changes to Utilities.tcl.

565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
    variable typeInfo
    variable simpleTypes

    set type [string trimright $type {()}]
    set results {}
    if {[string equal $type {}]} {
        ::log::log debug "@1"
        set results [dict get $typeInfo $mode $service]
    } else {
        set typeInfoList [TypeInfo $mode $service $type]
        if {[string equal -nocase -length 3 $type {xs:}]} {
            set type [string range $type 3 end]
        }
        ::log::log debug "Type = {$type} typeInfoList = {$typeInfoList}"
        if {[info exists simpleTypes($mode,$service,$type)]} {







|







565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
    variable typeInfo
    variable simpleTypes

    set type [string trimright $type {()}]
    set results {}
    if {[string equal $type {}]} {
        ::log::log debug "@1"
        catch {set results [dict get $typeInfo $mode $service]}
    } else {
        set typeInfoList [TypeInfo $mode $service $type]
        if {[string equal -nocase -length 3 $type {xs:}]} {
            set type [string range $type 3 end]
        }
        ::log::log debug "Type = {$type} typeInfoList = {$typeInfoList}"
        if {[info exists simpleTypes($mode,$service,$type)]} {