blob: da6fd0ee2d735f156b4e14b2991bd13744ab7044 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
//
// CachedRelays.swift
// CachedRelays
//
// Created by pronebird on 27/07/2021.
// Copyright © 2025 Mullvad VPN AB. All rights reserved.
//
import Foundation
/// A struct that represents the relay cache in memory
public struct CachedRelays: Codable, Equatable {
/// E-tag returned by server
public let etag: String?
/// The relay list stored within the cache entry
public let relays: REST.ServerRelaysResponse
/// The date when this cache was last updated
public let updatedAt: Date
public init(etag: String? = nil, relays: REST.ServerRelaysResponse, updatedAt: Date) {
self.etag = etag
self.relays = relays
self.updatedAt = updatedAt
}
}
|