标题:怎么写webservice程序
作者:介农酥
日期:2019-10-09 13:49
内容:
因为项目有点急,网上看了下,还是很多东西不懂,所以直接开问,望各位大力支持
客户将数据发给我,我来接受,所以我这边应该属于服务端。
我这边应该怎么写呢?我自己是这样写的,打个比方:
1)写好约定好的函数名,如在class.cpp文件中写:
void getCZYB(QString str);
2)在wsdl.xml文件中添加该函数的信息(乱写的,大家理解就行)
<?xml version="1.0" encoding="UTF-8" ?>
<definitions name="FooSample"
targetNamespace="http://tempuri.org/wsdl/"
xmlns:wsdlns="http://tempuri.org/wsdl/"
xmlns:typens="http://tempuri.org/xsd"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:stk="http://schemas.microsoft.com/soap-toolkit/wsdl-extension"
xmlns="http://schemas.xmlsoap.org/wsdl/">
<types>
<schema targetNamespace="http://tempuri.org/xsd"
xmlns="http://www.w3.org/2001/XMLSchema"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
elementFormDefault="qualifie ..
#1 [uidab 10-09 16:39]
https://blog.csdn.net/zhangyuanxuevaq/article/details/79687441
https://baijiahao.baidu.com/s?id=1626040867645963860&wfr=spider&for=pc
多百度一下,一般只需用命令生成一下,Qt即可调用,和调用普通C++接口没什么区别。
越急越做不好。
#2 回 uidab 的帖子 [介农酥 10-09 20:34]
uidab:https://blog.csdn.net/zhangyuanxuevaq/article/details/79687441
https://baijiahao.baidu.com/s?id=1626040867645963860&wfr=spider&for=pc
多百度一下,一般只需用命令生成一下,Qt即可调用,和调用普通C++接口没什么区别。
....... (2019-10-09 16:39)
看懂了,,非常非常感谢!