mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 06:55:59 +00:00
Handle the new trace log pack.
This commit is contained in:
@@ -9,16 +9,14 @@ import Foundation
|
|||||||
import MatrixRustSDK
|
import MatrixRustSDK
|
||||||
|
|
||||||
enum TraceLogPack: Codable, CaseIterable {
|
enum TraceLogPack: Codable, CaseIterable {
|
||||||
case eventCache, sendQueue, timeline
|
case eventCache, sendQueue, timeline, notificationClient
|
||||||
|
|
||||||
var title: String {
|
var title: String {
|
||||||
switch self {
|
switch self {
|
||||||
case .eventCache:
|
case .eventCache: "Event cache"
|
||||||
return "Event cache"
|
case .sendQueue: "Send queue"
|
||||||
case .sendQueue:
|
case .timeline: "Timeline"
|
||||||
return "Send queue"
|
case .notificationClient: "Notification client"
|
||||||
case .timeline:
|
|
||||||
return "Timeline"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -27,23 +25,19 @@ extension TraceLogPack {
|
|||||||
// periphery:ignore - Unused, but added to detect new cases when updating the SDK.
|
// periphery:ignore - Unused, but added to detect new cases when updating the SDK.
|
||||||
init(rustLogPack: MatrixRustSDK.TraceLogPacks) {
|
init(rustLogPack: MatrixRustSDK.TraceLogPacks) {
|
||||||
switch rustLogPack {
|
switch rustLogPack {
|
||||||
case .eventCache:
|
case .eventCache: self = .eventCache
|
||||||
self = .eventCache
|
case .sendQueue: self = .sendQueue
|
||||||
case .sendQueue:
|
case .timeline: self = .timeline
|
||||||
self = .sendQueue
|
case .notificationClient: self = .notificationClient
|
||||||
case .timeline:
|
|
||||||
self = .timeline
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var rustLogPack: MatrixRustSDK.TraceLogPacks {
|
var rustLogPack: MatrixRustSDK.TraceLogPacks {
|
||||||
switch self {
|
switch self {
|
||||||
case .eventCache:
|
case .eventCache: .eventCache
|
||||||
return .eventCache
|
case .sendQueue: .sendQueue
|
||||||
case .sendQueue:
|
case .timeline: .timeline
|
||||||
return .sendQueue
|
case .notificationClient: .notificationClient
|
||||||
case .timeline:
|
|
||||||
return .timeline
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user