gpt4 book ai didi

soap - 如何使用servicestack产品,以便将Flutter或Dart连接到soap WSDL服务?

转载 作者:行者123 更新时间:2023-12-03 04:02:06 24 4
gpt4 key购买 nike

我正在尝试让我的Flutter应用程序安全地连接到soap / wsdl Web服务。

我的问题是如何使用servicestack产品,以便可以连接Flutter移动应用程序或Dart控制台应用程序来使用肥皂WSDL服务?

谢谢

更新:

<?xml version="1.0" encoding="utf-8"?>
<wsdl:definitions xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://nick.mobile.com/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://nick.mobile.com/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
<wsdl:types>
<s:schema elementFormDefault="qualified" targetNamespace="http://nick.mobile.com/">
<s:element name="C_getFilteredCustInfo_WithAssignNo">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="AssignNo" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="clSecurityCheckBase" type="tns:cpSecurityCheckBase_WithAssignNo" />
<s:element minOccurs="0" maxOccurs="1" name="language" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
<s:complexType name="cpSecurityCheckBase_WithAssignNo">
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="AssignNo" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="OrgData" />
<s:element minOccurs="0" maxOccurs="1" name="HashData" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="IP" type="s:string" />
</s:sequence>
</s:complexType>
...
...
...

最佳答案

ServiceStack的Dart and Flutter support依赖于带有生成的类型化DTO的using the JsonWebClient,例如:

import 'package:servicestack/client.dart';

import 'techstacks.dtos.dart';

var client = new JsonServiceClient("https://www.techstacks.io");

main() async {
var response = await client.get(new GetTechnology(slug: "flutter"));
print("${response.technology.name}: ${response.technology.vendorUrl}");
}

它仅适用于ServiceStack的JSON端点,因此您将无法使用它直接调用SOAP Services。

代替 ServiceStack support SOAP Services作为ServiceStack Services的附加终结点,您可以从JSON和SOAP 1.1 / 1.2客户端获得相同的服务。

关于soap - 如何使用servicestack产品,以便将Flutter或Dart连接到soap WSDL服务?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54910286/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com