FacebookSignInHandler
public class FacebookSignInHandler : NSObject, IdPHandler
FacebookSignInHandler is responsible to perform sign-in and authorize a user using Facebook account
-
Credentials type for Facebook credentials
Declaration
Swift
public var tokenType: String
-
Currently presented UIViewController in the application which will be used to present Facebook login view
Declaration
Swift
public var presentingViewController: UIViewController?
-
Declaration
Swift
public override init()
-
Signs-in a user through
FacebookLogin
SDKDeclaration
Swift
public func signIn(idpClient: IdPClient, completion: @escaping SocialLoginCompletionCallback)
Parameters
idpClient
IdPClient
informationcompletion
Completion callback to notify the result
-
Generates, and returns
UIView
forFBLoginButton
buttonDeclaration
Swift
public func getProviderButtonView() -> UIView?
Return Value
FBLoginButton
button inUIView
-
Generates, and returns
UIView
forFBLoginButton
button withColorStyle
optionDeclaration
Swift
public func getFacebookButtonView(colorStyle: FBTooltipView.ColorStyle = .neutralGray) -> UIView?
Parameters
colorStyle
FBTooltipView.ColorStyle
option forFBLoginButton
; default value with.neutralGray
Return Value
FBLoginButton
button inUIView
-
Call this method from the
UIApplicationDelegate.application(_:didFinishLaunchingWithOptions:)
method of your application delegate. It should be invoked for the proper use of the Facebook SDK. As part of SDK initialization, basic auto-logging of app events will occur; this can be controlled via theFacebookAutoLogAppEventsEnabled
key in the project’s Info.plist file.Declaration
Swift
public static func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey : Any]? = nil) -> Bool
Parameters
application
The application as passed to
UIApplicationDelegate.application(_:didFinishLaunchingWithOptions:)
.launchOptions
The launch options as passed to
UIApplicationDelegate.application(_:didFinishLaunchingWithOptions:)
.Return Value
true
if there are any added application observers that themselves return true from callingapplication(_:didFinishLaunchingWithOptions:)
. Otherwise will returnfalse
.