add messages to deprecated methods
This commit is contained in:
parent
e16914f7d6
commit
70283acc1f
@ -123,13 +123,13 @@ public final class SocketEngine: NSObject, SocketEnginePollable, SocketEngineWeb
|
|||||||
self.init(client: client, url: url, options: options?.toSocketOptionsSet() ?? [])
|
self.init(client: client, url: url, options: options?.toSocketOptionsSet() ?? [])
|
||||||
}
|
}
|
||||||
|
|
||||||
@available(*, deprecated=5.3)
|
@available(*, deprecated=5.3, message="Please use the NSURL based init")
|
||||||
public convenience init(client: SocketEngineClient, urlString: String, options: Set<SocketIOClientOption>) {
|
public convenience init(client: SocketEngineClient, urlString: String, options: Set<SocketIOClientOption>) {
|
||||||
guard let url = NSURL(string: urlString) else { fatalError("Incorrect url") }
|
guard let url = NSURL(string: urlString) else { fatalError("Incorrect url") }
|
||||||
self.init(client: client, url: url, options: options)
|
self.init(client: client, url: url, options: options)
|
||||||
}
|
}
|
||||||
|
|
||||||
@available(*, deprecated=5.3)
|
@available(*, deprecated=5.3, message="Please use the NSURL based init")
|
||||||
public convenience init(client: SocketEngineClient, urlString: String, options: NSDictionary?) {
|
public convenience init(client: SocketEngineClient, urlString: String, options: NSDictionary?) {
|
||||||
guard let url = NSURL(string: urlString) else { fatalError("Incorrect url") }
|
guard let url = NSURL(string: urlString) else { fatalError("Incorrect url") }
|
||||||
self.init(client: client, url: url, options: options?.toSocketOptionsSet() ?? [])
|
self.init(client: client, url: url, options: options?.toSocketOptionsSet() ?? [])
|
||||||
|
|||||||
@ -102,15 +102,13 @@ public final class SocketIOClient: NSObject, SocketEngineClient, SocketParsable
|
|||||||
self.init(socketURL: socketURL, options: options?.toSocketOptionsSet() ?? [])
|
self.init(socketURL: socketURL, options: options?.toSocketOptionsSet() ?? [])
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Please use the NSURL based init
|
@available(*, deprecated=5.3, message="Please use the NSURL based init")
|
||||||
@available(*, deprecated=5.3)
|
|
||||||
public convenience init(socketURLString: String, options: Set<SocketIOClientOption> = []) {
|
public convenience init(socketURLString: String, options: Set<SocketIOClientOption> = []) {
|
||||||
guard let url = NSURL(string: socketURLString) else { fatalError("Incorrect url") }
|
guard let url = NSURL(string: socketURLString) else { fatalError("Incorrect url") }
|
||||||
self.init(socketURL: url, options: options)
|
self.init(socketURL: url, options: options)
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Please use the NSURL based init
|
@available(*, deprecated=5.3, message="Please use the NSURL based init")
|
||||||
@available(*, deprecated=5.3)
|
|
||||||
public convenience init(socketURLString: String, options: NSDictionary?) {
|
public convenience init(socketURLString: String, options: NSDictionary?) {
|
||||||
guard let url = NSURL(string: socketURLString) else { fatalError("Incorrect url") }
|
guard let url = NSURL(string: socketURLString) else { fatalError("Incorrect url") }
|
||||||
self.init(socketURL: url, options: options?.toSocketOptionsSet() ?? [])
|
self.init(socketURL: url, options: options?.toSocketOptionsSet() ?? [])
|
||||||
@ -134,7 +132,7 @@ public final class SocketIOClient: NSObject, SocketEngineClient, SocketParsable
|
|||||||
reconnectTimer = nil
|
reconnectTimer = nil
|
||||||
}
|
}
|
||||||
|
|
||||||
@available(*, deprecated=5.3)
|
@available(*, deprecated=5.3, message="Please use disconnect()")
|
||||||
public func close() {
|
public func close() {
|
||||||
disconnect()
|
disconnect()
|
||||||
}
|
}
|
||||||
@ -426,10 +424,7 @@ public final class SocketIOClient: NSObject, SocketEngineClient, SocketParsable
|
|||||||
anyHandler = handler
|
anyHandler = handler
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@available(*, deprecated=5.3, message="Please use one of the connect methods)")
|
||||||
Same as connect
|
|
||||||
*/
|
|
||||||
@available(*, deprecated=5.3)
|
|
||||||
public func open() {
|
public func open() {
|
||||||
connect()
|
connect()
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user