CallbackFactory

@objc(FRCallbackFactory)
public class CallbackFactory : NSObject

CallbackFactory is a representation of class responsible for managing and maintaining supported OpenAM callback in FRAuth SDK.

Notes

* Any Callback type returned from OpenAM **must** be supported within CallbackFactory.shared.supportedCallbacks.
* Any custom Callback must be implemented custom Callback class, and be registered through CallbackFactory.shared.registerCallback(callbackType:callbackClass:).
* FRAuth SDK currently supports following Callback types:
    1. NameCallback
    2. PasswordCallback
    3. ChoiceCallback
    4. ValidatedCreateUsernameCallback
    5. ValidatedCreatePasswordCallback
    6. StringAttributeInputCallback
    7. TermsAndConditionsCallback
    8. KbaCreateCallback
    9. PollingWaitCallback
    10. ConfirmationCallback
    11. TextOutputCallback
    12. ReCaptchaCallback
    13. MetadataCallback
    14. DeviceProfileCallback
    15. BooleanAttributeInputCallback
    16. NumberAttributeInputCallback
    17. SuspendedTextOutputCallback
    18. WebAuthnRegistrationCallback
    19. WebAuthnAuthenticationCallback
    20. IdPCallback
    21. SelectIdPCallback
    22. FRAppIntegrityCallback
    23. TextInputCallback

Property

  • Shared instance of CallbackFactory

    Declaration

    Swift

    @objc
    public static let shared: CallbackFactory
  • An array of supported Callback types; additional Callback type can be registered through Node.registerCallback

    Declaration

    Swift

    @objc
    public var supportedCallbacks: [String : Callback.Type]

Supported Callbacks

  • Registers a Callback class to the supported Callback list

    Note

    Any custom Callback class should be registered with this method; if unknown / unsupported Callback type is returned from OpenAM, SDK throws an error

    Declaration

    Swift

    @objc
    public func registerCallback(callbackType: String, callbackClass: Callback.Type)

    Parameters

    callbackType

    String value of Callback type

    callbackClass

    Class type of the callback