protected open fun getHandlersToTry()

in facebook-common/src/main/java/com/facebook/login/LoginClient.kt [153:179]


  protected open fun getHandlersToTry(request: Request): Array<LoginMethodHandler>? {
    val handlers = ArrayList<LoginMethodHandler>()
    val behavior = request.loginBehavior
    if (request.isInstagramLogin) {
      if (!FacebookSdk.bypassAppSwitch && behavior.allowsInstagramAppAuth()) {
        handlers.add(InstagramAppLoginMethodHandler(this))
      }
    } else {
      // Only use get token auth and native FB4A auth for FB logins
      if (behavior.allowsGetTokenAuth()) {
        handlers.add(GetTokenLoginMethodHandler(this))
      }
      if (!FacebookSdk.bypassAppSwitch && behavior.allowsKatanaAuth()) {
        handlers.add(KatanaProxyLoginMethodHandler(this))
      }
    }
    if (behavior.allowsCustomTabAuth()) {
      handlers.add(CustomTabLoginMethodHandler(this))
    }
    if (behavior.allowsWebViewAuth()) {
      handlers.add(WebViewLoginMethodHandler(this))
    }
    if (!request.isInstagramLogin && behavior.allowsDeviceAuth()) {
      handlers.add(DeviceAuthMethodHandler(this))
    }
    return handlers.toTypedArray()
  }