基于socket.io 0.9.x的客户端的Qt API的封装

header-img

“Yeah It's on. ”

基于socket.io 0.9.x的客户端的Qt API的封装

有哪些功能?

  • 方便使用socket.io进行即时通讯的交互
  • 方便C++与JS进行交互
  • 实现服务端与客户端的socket.io完美结合
  • 弥补了Qt在PC端开发下无法直接使用socket.io的遗憾
  • 修复了源代码的编码问题(utf8)

QtSocketIo

=======================

Building the socketio Module(编译socket.io模块)

  • Base on Qt5.3 or later (至少需要Qt5.3 此时Qt版本支持Websocket)

  • Download or git clone the source code.(克隆或者下载该源代码)

  • Put the source code in any directory you like(放置你喜爱的目录)

  • Go to top directory of the project in a terminal and run(使用终端或者cmd命令 cd到项目目录)

  • You should notice add the test/auto/cmake dir(自己新建一个test/auto/cmake目录 目前已经新建好啦)

  • You must set the make evn path(设置环境QtSDK的变量)

  • follow github sourcecode and modified it for me

  • The other build way: Use qtcreator IDE and build it(可以使用qtcreator进行编译)

  • cmd or terminal:


    make clean(mingw32-make clean)
    qmake
    make(mingw32-make)
    make install(mingw32-make install)

  • make install which can be installed to your QtSDK path(此时可以安装到QtSDK的安装目录的相应位置)

模块如何使用

#pro: QT += core gui  websockets  socketio

#C++: 查看封装的API

使用效果

tup1

图片

有问题反馈

在使用中有任何问题,欢迎反馈给我,可以用以下联系方式跟我交流

感激

感谢以下的项目,排名不分先后

关于作者

  var duoduozhijiao = {
    nickName  : "寒山-居士",
    site : "http://www.heilqt.com",
    blog : "http://blog.heilqt.com"
  }

转载于:https://my.oschina.net/yiyidaishui/blog/871135

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值