session-ios/SessionProtocolKit/Configuration.swift
2020-12-02 16:25:16 +11:00

15 lines
579 B
Swift

public struct SNProtocolKitConfiguration {
public let storage: SessionProtocolKitStorageProtocol
public let sharedSenderKeysDelegate: SharedSenderKeysDelegate
internal static var shared: SNProtocolKitConfiguration!
}
public enum SNProtocolKit { // Just to make the external API nice
public static func configure(storage: SessionProtocolKitStorageProtocol, sharedSenderKeysDelegate: SharedSenderKeysDelegate) {
SNProtocolKitConfiguration.shared = SNProtocolKitConfiguration(storage: storage, sharedSenderKeysDelegate: sharedSenderKeysDelegate)
}
}