summaryrefslogtreecommitdiffhomepage
path: root/ios/MullvadVPN/AccessMethodRepository/ProxyConfigurationTesterProtocol.swift
blob: b01d817d61b67548f1fb273e5b695b8dabccabfa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
//
//  ProxyConfigurationTesterProtocol.swift
//  MullvadVPN
//
//  Created by pronebird on 28/11/2023.
//  Copyright © 2023 Mullvad VPN AB. All rights reserved.
//

import Foundation
import MullvadSettings

/// Type implementing access method proxy configuration testing.
protocol ProxyConfigurationTesterProtocol {
    /// Start testing proxy configuration.
    /// - Parameters:
    ///   - configuration: a proxy configuration.
    ///   - completion: a completion handler that receives `nil` upon success, otherwise the underlying error.
    func start(configuration: PersistentProxyConfiguration, completion: @escaping (Error?) -> Void)

    /// Cancel testing proxy configuration.
    func cancel()
}