EventSource:服务器发送事件(SSE)的简单Swift客户端库

时间:2021-05-06 14:34:28
【文件属性】:
文件名称:EventSource:服务器发送事件(SSE)的简单Swift客户端库
文件大小:691KB
文件格式:ZIP
更新时间:2021-05-06 14:34:28
swift sse eventsource sse-client Swift 事件源 使用NSURLSession在Swift上编写的SSE客户端。 抽象的 这是文档之后在Swift上编写的EventSource实现。 如果有什么缺失或不完全正确,请打开一个问题,我将继续进行处理! 如果您喜欢图书馆,请给我们留下★。 这可以帮助我们继续进行维护! 从版本2.2.1更改为3.0 我花了一些时间检查所有在github上打开的fork,pull请求和问题。 我发现的主要更改和抱怨与连接和Last-Event-Id处理有关。 此版本的更改是: EventSource不再自动连接。 它一直等到调用connect(lastEventId: String? = nil)方法。 此方法接受lastEventId ,该事件将在连接后发送到服务器。 EventSource ,您可以EventSource调用disconnect() 。 EventSource不再存储Last
【文件预览】:
EventSource-master
----.travis.yml(317B)
----EventSource()
--------EventSource.swift(9KB)
--------EventStreamParser.swift(3KB)
--------Info.plist(752B)
--------Event.swift(3KB)
----sse-server()
--------package.json(200B)
--------package-lock.json(305B)
--------sse.js(2KB)
----.swiftlint.yml(57B)
----header.png(28KB)
----EventSource.xcodeproj()
--------project.xcworkspace()
--------project.pbxproj(25KB)
--------xcshareddata()
----LICENSE(11KB)
----Package.swift(972B)
----IKEventSource.podspec(688B)
----sample.gif(835KB)
----.gitignore(671B)
----EventSourceTests()
--------EventTests.swift(4KB)
--------EventStreamParserTests.swift(6KB)
--------Mock()
--------EventSourceTests.swift(6KB)
--------Info.plist(701B)
----README.md(7KB)
----EventSourceSample()
--------ViewController.swift(3KB)
--------Assets.xcassets()
--------Base.lproj()
--------AppDelegate.swift(255B)
--------Info.plist(1KB)
--------Main.storyboard(12KB)

网友评论