SessionAuthenticator
public struct SessionAuthenticator: IAuthenticator
The SessionAuthenticator class is an authenticator that will authenticate by using the session ID of the session created by a Sync Gateway.
-
Session ID of the session created by a Sync Gateway.
Declaration
Swift
public let sessionID: String
-
Session cookie name that the session ID value will be set to when communicating the Sync Gateaway.
Declaration
Swift
public let cookieName: String
-
Initializes with the Sync Gateway session ID and uses the default cookie name.
Declaration
Swift
public init(sessionID: String)
Parameters
sessionID
Sync Gateway session ID.
-
Initializes with the session ID and the cookie name. If the given cookieName is nil, the default cookie name will be used.
Declaration
Swift
public init(sessionID: String, cookieName: String?)
Parameters
sessionID
The Sync Gateway session ID.
cookieName
The cookie name.