LockKitConfiguration

public struct LockKitConfiguration

The configuration object for LockKit instance.

The instance of this struct is passed to the LockKit initializer in order to supply additional configuration as needed:

 let configuration = LockKitConfiguration(logLevel: .debug, environment: .live)
 let donkeyLockKit = LockKit(configuration: configuration)
  • Designated initializer for the configuration.

    Declaration

    Swift

    public init(logLevel: LogLevel, environment: ServerEnvironment)

    Parameters

    logLevel

    The log level to be applied for the LockKit.

    environment

    The server environment that LockKit should use.

  • Default configuration object provided for convenience.

    The default configuration is applied to LockKit automatically and needs no further action. It assumes .error log level and .live environment.

    Declaration

    Swift

    public static let `default`: LockKitConfiguration
  • Log level to be used by the framework.

    It defaults to only reporting errors, but can be adjusted to provide additional log output to help with debugging. Alternatively, output can be completely muted by setting this property to .off. All debug logging is provided via os_log.

    Declaration

    Swift

    public let logLevel: LogLevel
  • Server environment to be used by the framework.

    It defaults to .live. Can be adjusted to use test environment.

    Declaration

    Swift

    public let environment: ServerEnvironment