-
Notifications
You must be signed in to change notification settings - Fork 425
CocoaMQTTSocket
leeway edited this page Nov 19, 2021
·
1 revision
public class CocoaMQTTSocket: NSObject
CocoaMQTTSocketProtocol
, GCDAsyncSocketDelegate
, NSObject
public override init()
public var backgroundOnSocket = true
public var enableSSL = false
public var sslSettings: [String: NSObject]?
Allow self-signed ca certificate.
public var allowUntrustCACertificate = false
Default is false
public func setDelegate(_ theDelegate: CocoaMQTTSocketDelegate?, delegateQueue: DispatchQueue?)
public func connect(toHost host: String, onPort port: UInt16) throws
public func connect(toHost host: String, onPort port: UInt16, withTimeout timeout: TimeInterval) throws
public func disconnect()
public func readData(toLength length: UInt, withTimeout timeout: TimeInterval, tag: Int)
public func write(_ data: Data, withTimeout timeout: TimeInterval, tag: Int)
public func socket(_ sock: GCDAsyncSocket, didConnectToHost host: String, port: UInt16)
public func socket(_ sock: GCDAsyncSocket, didReceive trust: SecTrust, completionHandler: @escaping (Bool) -> Swift.Void)
public func socketDidSecure(_ sock: GCDAsyncSocket)
public func socket(_ sock: GCDAsyncSocket, didWriteDataWithTag tag: Int)
public func socket(_ sock: GCDAsyncSocket, didRead data: Data, withTag tag: Int)
public func socketDidDisconnect(_ sock: GCDAsyncSocket, withError err: Error?)
Types
- CloseCode
- CocoaMQTT
- CocoaMQTT5
- CocoaMQTT5Message
- CocoaMQTTAUTHReasonCode
- CocoaMQTTCONNACKReasonCode
- CocoaMQTTConnAck
- CocoaMQTTConnState
- CocoaMQTTDISCONNECTReasonCode
- CocoaMQTTError
- CocoaMQTTError.FoundationConnection
- CocoaMQTTLogger
- CocoaMQTTLoggerLevel
- CocoaMQTTMessage
- CocoaMQTTPUBACKReasonCode
- CocoaMQTTPUBCOMPReasonCode
- CocoaMQTTPUBRECReasonCode
- CocoaMQTTPUBRELReasonCode
- CocoaMQTTPropertyName
- CocoaMQTTQoS
- CocoaMQTTSUBACKReasonCode
- CocoaMQTTSocket
- CocoaMQTTUNSUBACKReasonCode
- CocoaMQTTWebSocket
- CocoaMQTTWebSocket.DefaultConnectionBuilder
- CocoaMQTTWebSocket.FoundationConnection
- CocoaMQTTWebSocket.StarscreamConnection
- CocoaRetainHandlingOption
- ErrorType
- FoundationStream
- MqttAuthProperties
- MqttConnectProperties
- MqttDecodeConnAck
- MqttDecodePubAck
- MqttDecodePubComp
- MqttDecodePubRec
- MqttDecodePubRel
- MqttDecodePublish
- MqttDecodeSubAck
- MqttDecodeUnsubAck
- MqttPublishProperties
- MqttSubscription
- PayloadFormatIndicator
- SSLCert
- SSLClientCertificate
- SSLClientCertificateError
- SSLSecurity
- SSLSettings
- WSError
- WebSocket
- WebSocket.OpCode
- WebSocket.WSResponse
- formatInt
Protocols
- CocoaMQTT5Delegate
- CocoaMQTTDelegate
- CocoaMQTTSocketDelegate
- CocoaMQTTSocketProtocol
- CocoaMQTTWebSocketConnection
- CocoaMQTTWebSocketConnectionBuilder
- CocoaMQTTWebSocketConnectionDelegate
- SSLTrustValidator
- WSStream
- WSStreamDelegate
- WebSocketAdvancedDelegate
- WebSocketClient
- WebSocketDelegate
- WebSocketPongDelegate