another.im-ios/AnotherXMPP/XMPPStorage.swift
2024-12-18 04:51:41 +01:00

22 lines
480 B
Swift

import Foundation
typealias Credentials = [String: String]
protocol XMPPStorage: AnyObject {
// credentials
func getCredentialsByUUID(_ uuid: UUID) async -> Credentials?
// roster
func deleteRoster(jid: JID) async
// where Data is byte representation of array of roster items
// i.e. [XMLElement] -> Data
func getRoster(jid: JID) async -> Data?
func setRoster(jid: JID, roster: Data) async
// messages
// omemo
// whatever else
}