ENAExposureManager

final class ENAExposureManager : NSObject, ExposureManager

Wrapper for ENManager to avoid code duplication and to abstract error handling

Creating a Manager

Activation

  • Activates ENManager Needs to be called before ExposureManager.enable()

    Declaration

    Swift

    func activate(completion: @escaping CompletionHandler)

Enable

  • Asks user for permission to enable ExposureNotification and enables it, if the user grants permission Expects the callee to invoke ExposureManager.activate prior to this function call

    Declaration

    Swift

    func enable(completion: @escaping CompletionHandler)
  • Disables the ExposureNotification framework Expects the callee to invoke ExposureManager.activate prior to this function call

    Declaration

    Swift

    func disable(completion: @escaping CompletionHandler)
  • Returns an instance of the OptionSet Preconditions Only if Preconditions.all()

    Declaration

    Swift

    func preconditions() -> ExposureManagerState

Detect Exposures

Diagnosis Keys

Invalidate

  • Invalidate the EnManager with completion handler

    Declaration

    Swift

    func invalidate(handler: (() -> Void)?)
  • Reset the ExposureManager

    Declaration

    Swift

    func reset(handler: (() -> Void)?)

Memory

  • Undocumented

    Declaration

    Swift

    deinit

User Notifications

Pretty print (Only for debugging)