<kbd id="afajh"><form id="afajh"></form></kbd>
<strong id="afajh"><dl id="afajh"></dl></strong>
    <del id="afajh"><form id="afajh"></form></del>
        1. <th id="afajh"><progress id="afajh"></progress></th>
          <b id="afajh"><abbr id="afajh"></abbr></b>
          <th id="afajh"><progress id="afajh"></progress></th>

          Wcf.js在 Node.js 上調(diào)用 WCF Web 服務(wù)

          聯(lián)合創(chuàng)作 · 2023-09-23 19:05

          Wcf.js 可以讓你直接在 Node.js 上調(diào)用 WCF Web 服務(wù)。

          示例代碼:

          var BasicHttpBinding = require('wcf.js').BasicHttpBinding
            , Proxy = require('wcf.js').Proxy
            , binding = new BasicHttpBinding(
                  { SecurityMode: "TransportWithMessageCredential"
                  , MessageClientCredentialType: "UserName"
                  })
            , proxy = new Proxy(binding, "http://localhost:7171/Service/clearUsername")
            , message =  "<Envelope xmlns='http://schemas.xmlsoap.org/soap/envelope/'>" +
                           "<Header />" +
                             "<Body>" +
                               "<GetData xmlns='http://tempuri.org/'>" +
                                 "<value>123</value>" +
                               "</GetData>" +
                              "</Body>" +
                         "</Envelope>"
          proxy.ClientCredentials.Username.Username = "yaron"
          proxy.ClientCredentials.Username.Password = "1234"
          proxy.send(message, "http://tempuri.org/IService/GetData", function(response, ctx) {
            console.log(response)
          });    
          瀏覽 13
          點(diǎn)贊
          評(píng)論
          收藏
          分享

          手機(jī)掃一掃分享

          編輯 分享
          舉報(bào)
          評(píng)論
          圖片
          表情
          推薦
          點(diǎn)贊
          評(píng)論
          收藏
          分享

          手機(jī)掃一掃分享

          編輯 分享
          舉報(bào)
          <kbd id="afajh"><form id="afajh"></form></kbd>
          <strong id="afajh"><dl id="afajh"></dl></strong>
            <del id="afajh"><form id="afajh"></form></del>
                1. <th id="afajh"><progress id="afajh"></progress></th>
                  <b id="afajh"><abbr id="afajh"></abbr></b>
                  <th id="afajh"><progress id="afajh"></progress></th>
                  久久R5 | 黄色视频日本免费 | 人妇一区三区高清乱码视频 | 日韩在线中出 | 内射极品尤物 |