You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
public weak vardelegate:WebSocketTransportDelegate?
28
28
29
+
letconnectOnInit:Bool
29
30
letreconnect:Atomic<Bool>
30
31
varwebsocket:ApolloWebSocketClient
31
32
leterror:Atomic<Error?>=Atomic(nil)
@@ -103,6 +104,7 @@ public class WebSocketTransport {
103
104
/// - Parameter reconnect: Whether to auto reconnect when websocket looses connection. Defaults to true.
104
105
/// - Parameter reconnectionInterval: How long to wait before attempting to reconnect. Defaults to half a second.
105
106
/// - Parameter allowSendingDuplicates: Allow sending duplicate messages. Important when reconnected. Defaults to true.
107
+
/// - Parameter connectOnInit: Whether the websocket connects immediately on creation. If false, remember to call `resumeWebSocketConnection()` to connect. Defaults to true.
106
108
/// - Parameter connectingPayload: [optional] The payload to send on connection. Defaults to an empty `GraphQLMap`.
107
109
/// - Parameter requestBodyCreator: The `RequestBodyCreator` to use when serializing requests. Defaults to an `ApolloRequestBodyCreator`.
108
110
publicinit(request:URLRequest,
@@ -112,6 +114,7 @@ public class WebSocketTransport {
0 commit comments