docs/Protocols/SocketEngineClient.html
@objc
public protocol SocketEngineClient
Declares that a type will be a delegate to an engine.
Methods
`
engineDidError(reason:)
`
Called when the engine errors.
Swift
func engineDidError(reason: String)
| reason |
The reason the engine errored.
|
`
engineDidClose(reason:)
`
Called when the engine closes.
Swift
func engineDidClose(reason: String)
| reason |
The reason that the engine closed.
|
`
engineDidOpen(reason:)
`
Called when the engine opens.
Swift
func engineDidOpen(reason: String)
| reason |
The reason the engine opened.
|
`
engineDidReceivePing()
`
Called when the engine receives a ping message. Only called in socket.io >3.
Swift
func engineDidReceivePing()
`
engineDidReceivePong()
`
Called when the engine receives a pong message. Only called in socket.io 2.
Swift
func engineDidReceivePong()
`
engineDidSendPing()
`
Called when the engine sends a ping to the server. Only called in socket.io 2.
Swift
func engineDidSendPing()
`
engineDidSendPong()
`
Called when the engine sends a pong to the server. Only called in socket.io >3.
Swift
func engineDidSendPong()
`
parseEngineMessage(_:)
`
Called when the engine has a message that must be parsed.
Swift
func parseEngineMessage(_ msg: String)
| msg |
The message that needs parsing.
|
`
parseEngineBinaryData(_:)
`
Called when the engine receives binary data.
Swift
func parseEngineBinaryData(_ data: Data)
| data |
The data the engine received.
|
`
engineDidWebsocketUpgrade(headers:)
`
Called when when upgrading the http connection to a websocket connection.
Swift
func engineDidWebsocketUpgrade(headers: [String : String])
| headers |
The http headers.
|