another.im-ios/AnotherIM/xmpp/XMPPStorage.swift
2024-12-17 14:08:59 +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
}