iOS设备作为Web服务器 [英] iOS devices as web server

查看:1087
本文介绍了iOS设备作为Web服务器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我看到App Store上有几个应用程序允许其他计算机通过HTTP连接到iPhone / iPad设备来传输文件。看起来像一个Web服务正在iOS设备上运行。

I saw there are several apps on App Store that allow other computers to make a http connection to the iPhone/iPad devices to transfer files. It seemed like a web service is running on the iOS device. Just curious how is it done /what class was used?

感谢。

推荐答案

只需显示设备的IP地址,在iOS设备上运行的应用程序中打开一个用于侦听的套接字,并实现http协议。有几个第三方库可以为您完成大部分繁重工作:

Just display the devices IP address, open a socket for listening in an app running on the iOS device, and implement the http protocol. There are several 3rd party libraries that can do most of the heavy lifting for you:

CocoaHTTPServer 或iPhoneHTTPServer3,或SimpleWebSocketServer或MultithreadedHTTPServer3

CocoaHTTPServer or iPhoneHTTPServer3, or SimpleWebSocketServer, or MultithreadedHTTPServer3

这篇关于iOS设备作为Web服务器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆